]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Support new Intel processor model numbers
authorH.J. Lu <hongjiu.lu@intel.com>
Mon, 2 Feb 2015 04:20:49 +0000 (04:20 +0000)
committerH.J. Lu <hjl@gcc.gnu.org>
Mon, 2 Feb 2015 04:20:49 +0000 (20:20 -0800)
Backported from mainline

gcc/

* config/i386/driver-i386.c (host_detect_local_cpu): Check new
Silvermont, Haswell, Broadwell and Knights Landing model numbers.
* config/i386/i386.c (processor_model): Add
M_INTEL_COREI7_BROADWELL.
(arch_names_table): Add "broadwell".

gcc/testsuite/

* gcc.target/i386/builtin_target.c (check_intel_cpu_model): Add
Silvermont, Ivy Bridge, Haswell and Broadwell tests.  Update Sandy
Bridge test.

libgcc/

* config/i386/cpuinfo.c (processor_subtypes): Add
INTEL_COREI7_BROADWELL.
(get_intel_cpu): Support new Silvermont, Haswell and Broadwell
model numbers.

From-SVN: r220343

gcc/ChangeLog
gcc/config/i386/driver-i386.c
gcc/config/i386/i386.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/i386/builtin_target.c
libgcc/ChangeLog
libgcc/config/i386/cpuinfo.c

index 76660050f65886da7018c2feebc1a2a53e70f90e..6243963f4966f0cd736dd134cb38288360d39fe7 100644 (file)
@@ -1,3 +1,14 @@
+2015-02-01  H.J. Lu  <hongjiu.lu@intel.com>
+
+       Backported from mainline
+       2015-01-24  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * config/i386/driver-i386.c (host_detect_local_cpu): Check new
+       Silvermont, Haswell, Broadwell and Knights Landing model numbers.
+       * config/i386/i386.c (processor_model): Add
+       M_INTEL_COREI7_BROADWELL.
+       (arch_names_table): Add "broadwell".
+
 2015-02-01  Jakub Jelinek  <jakub@redhat.com>
 
        Backported from mainline
index 722c5469255e35337156a0dd65c2ed73e8b9fdda..992f91f8a57943d38a040a3f4ef9aa4095c19e24 100644 (file)
@@ -670,7 +670,10 @@ const char *host_detect_local_cpu (int argc, const char **argv)
          cpu = "bonnell";
          break;
        case 0x37:
+       case 0x4a:
        case 0x4d:
+       case 0x5a:
+       case 0x5d:
          /* Silvermont.  */
          cpu = "silvermont";
          break;
@@ -705,11 +708,22 @@ const char *host_detect_local_cpu (int argc, const char **argv)
          cpu = "ivybridge";
          break;
        case 0x3c:
+       case 0x3f:
        case 0x45:
        case 0x46:
          /* Haswell.  */
          cpu = "haswell";
          break;
+       case 0x3d:
+       case 0x4f:
+       case 0x56:
+         /* Broadwell.  */
+         cpu = "broadwell";
+         break;
+       case 0x57:
+         /* Knights Landing.  */
+         cpu = "knl";
+         break;
        default:
          if (arch)
            {
index ff2a4491990bd3d496c1beb906c824b0a96a758a..2c7c965fbd2450ab5d5bd9d5b6d55b11de41db9c 100644 (file)
@@ -32367,7 +32367,8 @@ fold_builtin_cpu (tree fndecl, tree *args)
     M_AMDFAM15H_BDVER3,
     M_AMDFAM15H_BDVER4,
     M_INTEL_COREI7_IVYBRIDGE,
-    M_INTEL_COREI7_HASWELL
+    M_INTEL_COREI7_HASWELL,
+    M_INTEL_COREI7_BROADWELL
   };
 
   static struct _arch_names_table
@@ -32388,6 +32389,7 @@ fold_builtin_cpu (tree fndecl, tree *args)
       {"sandybridge", M_INTEL_COREI7_SANDYBRIDGE},
       {"ivybridge", M_INTEL_COREI7_IVYBRIDGE},
       {"haswell", M_INTEL_COREI7_HASWELL},
+      {"broadwell", M_INTEL_COREI7_BROADWELL},
       {"bonnell", M_INTEL_BONNELL},
       {"silvermont", M_INTEL_SILVERMONT},
       {"amdfam10h", M_AMDFAM10H},
index b5dab480b1fae819cfc04ebecf1d22eda94aee22..6a61b2efac215558d92a4ac3e553e5be41b03be2 100644 (file)
@@ -1,3 +1,12 @@
+2015-02-01  H.J. Lu  <hongjiu.lu@intel.com>
+
+       Backported from mainline
+       2015-01-24  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * gcc.target/i386/builtin_target.c (check_intel_cpu_model): Add
+       Silvermont, Ivy Bridge, Haswell and Broadwell tests.  Update Sandy
+       Bridge test.
+
 2015-02-01  Jakub Jelinek  <jakub@redhat.com>
 
        Backported from mainline
index c40983e6b3cddd65842f22d7fe8ba7a5c49ffbb5..af733380ceef546f0fbc3e2133482b74b565fc40 100644 (file)
@@ -30,6 +30,14 @@ check_intel_cpu_model (unsigned int family, unsigned int model,
              /* Atom.  */
              assert (__builtin_cpu_is ("atom"));
              break;
+           case 0x37:
+           case 0x4a:
+           case 0x4d:
+           case 0x5a:
+           case 0x5d:
+             /* Silvermont.  */
+             assert (__builtin_cpu_is ("silvermont"));
+             break;
            case 0x1a:
            case 0x1e:
            case 0x1f:
@@ -46,10 +54,32 @@ check_intel_cpu_model (unsigned int family, unsigned int model,
              assert (__builtin_cpu_is ("westmere"));
              break;
            case 0x2a:
+           case 0x2d:
              /* Sandy Bridge.  */
              assert (__builtin_cpu_is ("corei7"));
              assert (__builtin_cpu_is ("sandybridge"));
              break;
+           case 0x3a:
+           case 0x3e:
+             /* Ivy Bridge.  */
+             assert (__builtin_cpu_is ("corei7"));
+             assert (__builtin_cpu_is ("ivybridge"));
+             break;
+           case 0x3c:
+           case 0x3f:
+           case 0x45:
+           case 0x46:
+             /* Haswell.  */
+             assert (__builtin_cpu_is ("corei7"));
+             assert (__builtin_cpu_is ("haswell"));
+             break;
+           case 0x3d:
+           case 0x4f:
+           case 0x56:
+             /* Broadwell.  */
+             assert (__builtin_cpu_is ("corei7"));
+             assert (__builtin_cpu_is ("broadwell"));
+             break;
            case 0x17:
            case 0x1d:
              /* Penryn.  */
index 31af58e49e948b197649edcfcabc366153c88a4f..1a02eb4322eee06635ab0120e3f6547d65f56d55 100644 (file)
@@ -1,3 +1,13 @@
+2015-02-01  H.J. Lu  <hongjiu.lu@intel.com>
+
+       Backported from mainline
+       2015-01-24  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * config/i386/cpuinfo.c (processor_subtypes): Add
+       INTEL_COREI7_BROADWELL.
+       (get_intel_cpu): Support new Silvermont, Haswell and Broadwell
+       model numbers.
+
 2015-01-31  John David Anglin  <danglin@gcc.gnu.org>
 
        * config/pa/linux-atomic.c (__kernel_cmpxchg2): Change declaration of
index 6ff7502bb9aa8562df900d77a8d1f0f23e25a8b6..7972cedaa11eb0165ac6ce952c5ba5bf7997f175 100644 (file)
@@ -75,6 +75,7 @@ enum processor_subtypes
   AMDFAM15H_BDVER4,
   INTEL_COREI7_IVYBRIDGE,
   INTEL_COREI7_HASWELL,
+  INTEL_COREI7_BROADWELL,
   CPU_SUBTYPE_MAX
 };
 
@@ -184,7 +185,10 @@ get_intel_cpu (unsigned int family, unsigned int model, unsigned int brand_id)
              __cpu_model.__cpu_type = INTEL_BONNELL;
              break;
            case 0x37:
+           case 0x4a:
            case 0x4d:
+           case 0x5a:
+           case 0x5d:
              /* Silvermont.  */
              __cpu_model.__cpu_type = INTEL_SILVERMONT;
              break;
@@ -216,12 +220,20 @@ get_intel_cpu (unsigned int family, unsigned int model, unsigned int brand_id)
              __cpu_model.__cpu_subtype = INTEL_COREI7_IVYBRIDGE;
              break;
            case 0x3c:
+           case 0x3f:
            case 0x45:
            case 0x46:
              /* Haswell.  */
              __cpu_model.__cpu_type = INTEL_COREI7;
              __cpu_model.__cpu_subtype = INTEL_COREI7_HASWELL;
              break;
+           case 0x3d:
+           case 0x4f:
+           case 0x56:
+             /* Broadwell.  */
+             __cpu_model.__cpu_type = INTEL_COREI7;
+             __cpu_model.__cpu_subtype = INTEL_COREI7_BROADWELL;
+             break;
            case 0x17:
            case 0x1d:
              /* Penryn.  */