[PATCH] [PATCH] Add armv8 support to the Clang driver.
Joey Gouly
joey.gouly at arm.com
Wed Jun 26 03:31:43 PDT 2013
This adds support for passing '-target armv8' to the Clang driver.
http://llvm-reviews.chandlerc.com/D1042
Files:
lib/Basic/Targets.cpp
lib/Driver/ToolChain.cpp
lib/Driver/ToolChains.cpp
lib/Driver/Tools.cpp
test/Driver/arch.c
Index: lib/Basic/Targets.cpp
===================================================================
--- lib/Basic/Targets.cpp
+++ lib/Basic/Targets.cpp
@@ -3750,6 +3750,7 @@
.Case("swift", "7S")
.Cases("cortex-m3", "cortex-m4", "7M")
.Case("cortex-m0", "6M")
+ .Case("cortex-a53", "8A")
.Default(0);
}
static const char *getCPUProfile(StringRef Name) {
Index: lib/Driver/ToolChain.cpp
===================================================================
--- lib/Driver/ToolChain.cpp
+++ lib/Driver/ToolChain.cpp
@@ -195,6 +195,7 @@
.Cases("armv7r", "armv7-r", "cortex-r4")
.Cases("armv7m", "armv7-m", "cortex-m3")
.Cases("armv7em", "armv7e-m", "cortex-m4")
+ .Cases("armv8", "armv8a", "armv8-a", "cortex-a53")
.Case("ep9312", "ep9312")
.Case("iwmmxt", "iwmmxt")
.Case("xscale", "xscale")
@@ -230,6 +231,7 @@
.Case("cortex-m4", "v7em")
.Case("cortex-a9-mp", "v7f")
.Case("swift", "v7s")
+ .Case("cortex-a53", "v8")
.Default("");
}
Index: lib/Driver/ToolChains.cpp
===================================================================
--- lib/Driver/ToolChains.cpp
+++ lib/Driver/ToolChains.cpp
@@ -113,6 +113,7 @@
.Cases("armv7k", "armv7-k", "armv7k")
.Cases("armv7m", "armv7-m", "armv7m")
.Cases("armv7s", "armv7-s", "armv7s")
+ .Cases("armv8", "armv8a", "armv8-a", "armv8")
.Default(0);
}
Index: lib/Driver/Tools.cpp
===================================================================
--- lib/Driver/Tools.cpp
+++ lib/Driver/Tools.cpp
@@ -532,6 +532,7 @@
.Cases("armv7s", "armv7-s", "swift")
.Cases("armv7r", "armv7-r", "cortex-r4")
.Cases("armv7m", "armv7-m", "cortex-m3")
+ .Cases("armv8", "armv8a", "armv8-a", "cortex-a53")
.Case("ep9312", "ep9312")
.Case("iwmmxt", "iwmmxt")
.Case("xscale", "xscale")
Index: test/Driver/arch.c
===================================================================
--- test/Driver/arch.c
+++ test/Driver/arch.c
@@ -1,3 +1,5 @@
-// RUN: %clang -target armv7a-unknown-linux-gnueabi -S -emit-llvm %s -o - | FileCheck %s
+// RUN: %clang -target armv7a-unknown-linux-gnueabi -S -emit-llvm %s -o - | FileCheck %s --check-prefix=V7
+// RUN: %clang -target armv8a-unknown-linux-gnueabi -S -emit-llvm %s -o - | FileCheck %s --check-prefix=V8
-// CHECK: target triple = "armv7-unknown-linux-gnueabi"
+// CHECK-V7: target triple = "armv7-unknown-linux-gnueabi"
+// CHECK-V8: target triple = "armv8-unknown-linux-gnueabi"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D1042.1.patch
Type: text/x-patch
Size: 2498 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130626/63da808c/attachment.bin>
More information about the cfe-commits
mailing list