aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorOleg Endo <olegendo@gcc.gnu.org>2012-11-05 01:06:18 +0000
committerOleg Endo <olegendo@gcc.gnu.org>2012-11-05 01:06:18 +0000
commitead4af4fb64a9255fa5d056b63f1c522099e170e (patch)
tree1a999235cd59c75a07adbe3c5bc9b905caa3158c /gcc
parente091ffb72fca7edf47738c3fcf5708fed7d0ad4e (diff)
downloadgcc-ead4af4fb64a9255fa5d056b63f1c522099e170e.zip
gcc-ead4af4fb64a9255fa5d056b63f1c522099e170e.tar.gz
gcc-ead4af4fb64a9255fa5d056b63f1c522099e170e.tar.bz2
sh.h (TARGET_CACHE32, [...]): Delete macro.
* config/sh/sh.h (TARGET_CACHE32, TARGET_HARVARD): Delete macro. (TARGET_SUPERSCALAR): Add TARGET_SH2A. (CACHE_LOG): Use TARGET_HARD_SH4 and TARGET_SH5 instead of TARGET_CACHE32. (TRAMPOLINE_ALIGNMENT): Use TARGET_HARD_SH4 and TARGET_SH5 instead of TARGET_HARVARD. * config/sh/sh.c (sh_trampoline_init): Likewise. From-SVN: r193151
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog10
-rw-r--r--gcc/config/sh/sh.c2
-rw-r--r--gcc/config/sh/sh.h15
3 files changed, 16 insertions, 11 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 09f1ddf..94c9acc 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,13 @@
+2012-11-05 Oleg Endo <olegendo@gcc.gnu.org>
+
+ * config/sh/sh.h (TARGET_CACHE32, TARGET_HARVARD): Delete macro.
+ (TARGET_SUPERSCALAR): Add TARGET_SH2A.
+ (CACHE_LOG): Use TARGET_HARD_SH4 and TARGET_SH5 instead of
+ TARGET_CACHE32.
+ (TRAMPOLINE_ALIGNMENT): Use TARGET_HARD_SH4 and TARGET_SH5 instead of
+ TARGET_HARVARD.
+ * config/sh/sh.c (sh_trampoline_init): Likewise.
+
2012-11-05 David Edelsohn <dje.gcc@gmail.com>
* system.h (loc_t): Poison.
diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c
index b221a2d..1826a854 100644
--- a/gcc/config/sh/sh.c
+++ b/gcc/config/sh/sh.c
@@ -11545,7 +11545,7 @@ sh_trampoline_init (rtx tramp_mem, tree fndecl, rtx cxt)
SImode));
emit_move_insn (adjust_address (tramp_mem, SImode, 8), cxt);
emit_move_insn (adjust_address (tramp_mem, SImode, 12), fnaddr);
- if (TARGET_HARVARD)
+ if (TARGET_HARD_SH4 || TARGET_SH5)
{
if (!TARGET_INLINE_IC_INVALIDATE
|| (!(TARGET_SH4A_ARCH || TARGET_SH4_300) && TARGET_USERMODE))
diff --git a/gcc/config/sh/sh.h b/gcc/config/sh/sh.h
index 5287526..fdd06a0 100644
--- a/gcc/config/sh/sh.h
+++ b/gcc/config/sh/sh.h
@@ -58,14 +58,8 @@ extern int code_for_indirect_jump_scratch;
/* Nonzero if we should generate code using type 3E insns. */
#define TARGET_SH3E (TARGET_SH3 && TARGET_SH_E)
-/* Nonzero if the cache line size is 32. */
-#define TARGET_CACHE32 (TARGET_HARD_SH4 || TARGET_SH5)
-
/* Nonzero if we schedule for a superscalar implementation. */
-#define TARGET_SUPERSCALAR TARGET_HARD_SH4
-
-/* Nonzero if the target has separate instruction and data caches. */
-#define TARGET_HARVARD (TARGET_HARD_SH4 || TARGET_SH5)
+#define TARGET_SUPERSCALAR (TARGET_HARD_SH4 || TARGET_SH2A)
/* Nonzero if a double-precision FPU is available. */
#define TARGET_FPU_DOUBLE \
@@ -461,7 +455,7 @@ extern enum sh_divide_strategy_e sh_div_strategy;
/* The log (base 2) of the cache line size, in bytes. Processors prior to
SH2 have no actual cache, but they fetch code in chunks of 4 bytes.
The SH2/3 have 16 byte cache lines, and the SH4 has a 32 byte cache line */
-#define CACHE_LOG (TARGET_CACHE32 ? 5 : TARGET_SH2 ? 4 : 2)
+#define CACHE_LOG ((TARGET_HARD_SH4 || TARGET_SH5) ? 5 : TARGET_SH2 ? 4 : 2)
/* ABI given & required minimum allocation boundary (in *bits*) for the
code of a function. */
@@ -1575,9 +1569,10 @@ struct sh_args {
/* Length in units of the trampoline for entering a nested function. */
#define TRAMPOLINE_SIZE (TARGET_SHMEDIA64 ? 40 : TARGET_SH5 ? 24 : 16)
-/* Alignment required for a trampoline in bits . */
+/* Alignment required for a trampoline in bits. */
#define TRAMPOLINE_ALIGNMENT \
- ((CACHE_LOG < 3 || (optimize_size && ! TARGET_HARVARD)) ? 32 \
+ ((CACHE_LOG < 3 \
+ || (optimize_size && ! (TARGET_HARD_SH4 || TARGET_SH5))) ? 32 \
: TARGET_SHMEDIA ? 256 : 64)
/* A C expression whose value is RTL representing the value of the return