]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
driver-native.c (host_detect_local_cpu): Handle new kernel strings for Loongson-2E...
authorHuacai Chen <chenhc@lemote.com>
Fri, 10 Jan 2014 08:54:42 +0000 (08:54 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Fri, 10 Jan 2014 08:54:42 +0000 (08:54 +0000)
gcc/
2014-01-10  Huacai Chen  <chenhc@lemote.com>

* config/mips/driver-native.c (host_detect_local_cpu): Handle new
kernel strings for Loongson-2E/2F/3A.

From-SVN: r206514

gcc/ChangeLog
gcc/config/mips/driver-native.c

index ceb019d8656829b35db77387838e524c9b1bda9d..1a97e536439dc730ff2a27e5fa2bdd2cd326a434 100644 (file)
@@ -1,3 +1,8 @@
+2014-01-10  Huacai Chen  <chenhc@lemote.com>
+
+       * config/mips/driver-native.c (host_detect_local_cpu): Handle new
+       kernel strings for Loongson-2E/2F/3A.
+
 2014-01-08  Uros Bizjak  <ubizjak@gmail.com>
 
        Backport from mainline
index f565c572e5479927d01d6a270485b8b615d94712..336fe6d7fe6ec365ab0431ec3f1f5a407a3af7ef 100644 (file)
@@ -116,11 +116,17 @@ host_detect_local_cpu (int argc, const char **argv)
     if (strncmp (buf, "cpu model", sizeof ("cpu model") - 1) == 0)
       {
        if (strstr (buf, "Godson2 V0.2") != NULL
-           || strstr (buf, "Loongson-2 V0.2") != NULL)
+           || strstr (buf, "Loongson-2 V0.2") != NULL
+           || strstr (buf, "Loongson-2E") != NULL)
          cpu = "loongson2e";
        else if (strstr (buf, "Godson2 V0.3") != NULL
-                || strstr (buf, "Loongson-2 V0.3") != NULL)
+                || strstr (buf, "Loongson-2 V0.3") != NULL
+                || strstr (buf, "Loongson-2F") != NULL)
          cpu = "loongson2f";
+       else if (strstr (buf, "Godson3 V0.5") != NULL
+                || strstr (buf, "Loongson-3 V0.5") != NULL
+                || strstr (buf, "Loongson-3A") != NULL)
+         cpu = "loongson3a";
        else if (strstr (buf, "SiByte SB1") != NULL)
          cpu = "sb1";
        else if (strstr (buf, "R5000") != NULL)