]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
arc-common.c (arc_handle_option): Add NPS400 support, setup defaults.
authorAndrew Burgess <andrew.burgess@embecosm.com>
Thu, 28 Apr 2016 16:59:18 +0000 (17:59 +0100)
committerJoern Rennecke <amylaar@gcc.gnu.org>
Thu, 28 Apr 2016 16:59:18 +0000 (17:59 +0100)
2016-04-28  Andrew Burgess  <andrew.burgess@embecosm.com>

        * common/config/arc/arc-common.c (arc_handle_option): Add NPS400
        support, setup defaults.
        * config/arc/arc-opts.h (enum processor_type): Add NPS400.
        * config/arc/arc.c (arc_init): Add NPS400 support.
        * config/arc/arc.h (CPP_SPEC): Add NPS400 defines.
        (TARGET_ARC700): NPS400 is also an ARC700.
        * config/arc/arc.opt: Add NPS400 options to -mcpu=.

From-SVN: r235584

gcc/ChangeLog
gcc/common/config/arc/arc-common.c
gcc/config/arc/arc-opts.h
gcc/config/arc/arc.c
gcc/config/arc/arc.h
gcc/config/arc/arc.opt

index c3a9c5ed457463ffdd7545ac036a2b7506a2628a..e9a6664b862cfdab3e28ee29228f18e146dcbdf1 100644 (file)
@@ -1,3 +1,13 @@
+2016-04-28  Andrew Burgess  <andrew.burgess@embecosm.com>
+
+       * common/config/arc/arc-common.c (arc_handle_option): Add NPS400
+       support, setup defaults.
+       * config/arc/arc-opts.h (enum processor_type): Add NPS400.
+       * config/arc/arc.c (arc_init): Add NPS400 support.
+       * config/arc/arc.h (CPP_SPEC): Add NPS400 defines.
+       (TARGET_ARC700): NPS400 is also an ARC700.
+       * config/arc/arc.opt: Add NPS400 options to -mcpu=.
+
 2016-04-28  Segher Boessenkool  <segher@kernel.crashing.org>
 
        PR target/70668
index 64fb053142c93400c44c631228e4e5ee4cb594b9..f5b9c6d3cc98296067467bfabfd966833164573e 100644 (file)
@@ -83,6 +83,10 @@ arc_handle_option (struct gcc_options *opts, struct gcc_options *opts_set,
 
       switch (value)
        {
+       case PROCESSOR_NPS400:
+         if (! (opts_set->x_TARGET_CASE_VECTOR_PC_RELATIVE) )
+           opts->x_TARGET_CASE_VECTOR_PC_RELATIVE = 1;
+         /* Fall through */
        case PROCESSOR_ARC600:
        case PROCESSOR_ARC700:
          if (! (opts_set->x_target_flags & MASK_BARREL_SHIFTER) )
index 1e11ebc41ffb226de71c5d01aaf39da55c3a071a..cbd78985dd8bbbc5fb53c24200633e724af1ed1c 100644 (file)
@@ -24,6 +24,7 @@ enum processor_type
   PROCESSOR_ARC600,
   PROCESSOR_ARC601,
   PROCESSOR_ARC700,
+  PROCESSOR_NPS400,
   PROCESSOR_ARCEM,
   PROCESSOR_ARCHS
 };
index e7067374e465ea4c4a25b9426820ca4357c2a089..e3744b8c971e0f510b5478bb302b599419feb43d 100644 (file)
@@ -690,6 +690,11 @@ arc_init (void)
       tune_dflt = TUNE_ARC700_4_2_STD;
       break;
 
+    case PROCESSOR_NPS400:
+      arc_cpu_string = "NPS400";
+      tune_dflt = TUNE_ARC700_4_2_STD;
+      break;
+
     case PROCESSOR_ARCEM:
       arc_cpu_string = "EM";
       break;
index 37c1afa6712e062cc86ec0f14f0f06d7e6f9d965..b14352c3e2622fe0950941539501a413cd666628 100644 (file)
@@ -138,6 +138,8 @@ along with GCC; see the file COPYING3.  If not see
 %{mdsp-packa:-D__Xdsp_packa} %{mcrc:-D__Xcrc} %{mdvbf:-D__Xdvbf} \
 %{mtelephony:-D__Xtelephony} %{mxy:-D__Xxy} %{mmul64: -D__Xmult32} \
 %{mlock:-D__Xlock} %{mswape:-D__Xswape} %{mrtsc:-D__Xrtsc} \
+%{mcpu=NPS400:-D__NPS400__} \
+%{mcpu=nps400:-D__NPS400__} \
 "
 
 #define CC1_SPEC "\
@@ -305,7 +307,8 @@ along with GCC; see the file COPYING3.  If not see
 
 #define TARGET_ARC600 (arc_cpu == PROCESSOR_ARC600)
 #define TARGET_ARC601 (arc_cpu == PROCESSOR_ARC601)
-#define TARGET_ARC700 (arc_cpu == PROCESSOR_ARC700)
+#define TARGET_ARC700 (arc_cpu == PROCESSOR_ARC700     \
+                      || arc_cpu == PROCESSOR_NPS400)
 #define TARGET_EM     (arc_cpu == PROCESSOR_ARCEM)
 #define TARGET_HS     (arc_cpu == PROCESSOR_ARCHS)
 #define TARGET_V2                                                      \
index 76f66a2988b2fd2cdc34d1e7885cd3d177d1dce1..45bb6a6167d3f8bd61cfeb666c23266e24de428d 100644 (file)
@@ -188,6 +188,12 @@ Enum(processor_type) String(ARC700) Value(PROCESSOR_ARC700)
 EnumValue
 Enum(processor_type) String(arc700) Value(PROCESSOR_ARC700)
 
+EnumValue
+Enum(processor_type) String(nps400) Value(PROCESSOR_NPS400)
+
+EnumValue
+Enum(processor_type) String(NPS400) Value(PROCESSOR_NPS400)
+
 EnumValue
 Enum(processor_type) String(ARCEM) Value(PROCESSOR_ARCEM)