aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2011-12-25 14:02:18 +0000
committerPeter Maydell <peter.maydell@linaro.org>2012-01-05 16:08:06 +0000
commit7405c69a99a40cd50800ef7be8df7b0c8d411c63 (patch)
treed654701dd7c76556f8ad06583a996543b6542200
parentbc225d38a93f318100bfdc91a9198e08b62208a4 (diff)
tcg/arm: Use r6 as TCG_AREG0 to avoid clash with Thumb framepointer2012.01.rebasing
On ARM, in Thumb mode r7 is used for the framepointer; this meant that we would fail to compile in debug mode because we were using r7 for TCG_AREG0. Shift to r6 instead to avoid this clash. (Bug reported as LP:870990.) Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r--dyngen-exec.h2
-rw-r--r--tcg/arm/tcg-target.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/dyngen-exec.h b/dyngen-exec.h
index 3544372a6..09be9ea7b 100644
--- a/dyngen-exec.h
+++ b/dyngen-exec.h
@@ -31,7 +31,7 @@
#elif defined(_ARCH_PPC)
#define AREG0 "r27"
#elif defined(__arm__)
-#define AREG0 "r7"
+#define AREG0 "r6"
#elif defined(__hppa__)
#define AREG0 "r17"
#elif defined(__mips__)
diff --git a/tcg/arm/tcg-target.h b/tcg/arm/tcg-target.h
index 48586c3e6..0035b471f 100644
--- a/tcg/arm/tcg-target.h
+++ b/tcg/arm/tcg-target.h
@@ -78,7 +78,7 @@ typedef enum {
enum {
/* Note: must be synced with dyngen-exec.h */
- TCG_AREG0 = TCG_REG_R7,
+ TCG_AREG0 = TCG_REG_R6,
};
static inline void flush_icache_range(unsigned long start, unsigned long stop)