r184970 - Add support for passing '-target armv8' through the Driver.
Joey Gouly
joey.gouly at arm.com
Wed Jun 26 10:19:48 PDT 2013
Author: joey
Date: Wed Jun 26 12:19:48 2013
New Revision: 184970
URL: http://llvm.org/viewvc/llvm-project?rev=184970&view=rev
Log:
Add support for passing '-target armv8' through the Driver.
Modified:
cfe/trunk/lib/Basic/Targets.cpp
cfe/trunk/lib/Driver/ToolChain.cpp
cfe/trunk/lib/Driver/ToolChains.cpp
cfe/trunk/lib/Driver/Tools.cpp
cfe/trunk/test/Driver/arch.c
Modified: cfe/trunk/lib/Basic/Targets.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Basic/Targets.cpp?rev=184970&r1=184969&r2=184970&view=diff
==============================================================================
--- cfe/trunk/lib/Basic/Targets.cpp (original)
+++ cfe/trunk/lib/Basic/Targets.cpp Wed Jun 26 12:19:48 2013
@@ -3750,6 +3750,7 @@ public:
.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) {
Modified: cfe/trunk/lib/Driver/ToolChain.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChain.cpp?rev=184970&r1=184969&r2=184970&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChain.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChain.cpp Wed Jun 26 12:19:48 2013
@@ -195,6 +195,7 @@ static const char *getARMTargetCPU(const
.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 @@ static const char *getLLVMArchSuffixForA
.Case("cortex-m4", "v7em")
.Case("cortex-a9-mp", "v7f")
.Case("swift", "v7s")
+ .Case("cortex-a53", "v8")
.Default("");
}
Modified: cfe/trunk/lib/Driver/ToolChains.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains.cpp?rev=184970&r1=184969&r2=184970&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChains.cpp Wed Jun 26 12:19:48 2013
@@ -112,6 +112,7 @@ static const char *GetArmArchForMArch(St
.Cases("armv7k", "armv7-k", "armv7k")
.Cases("armv7m", "armv7-m", "armv7m")
.Cases("armv7s", "armv7-s", "armv7s")
+ .Cases("armv8", "armv8a", "armv8-a", "armv8")
.Default(0);
}
Modified: cfe/trunk/lib/Driver/Tools.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Tools.cpp?rev=184970&r1=184969&r2=184970&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/Tools.cpp (original)
+++ cfe/trunk/lib/Driver/Tools.cpp Wed Jun 26 12:19:48 2013
@@ -528,6 +528,7 @@ static std::string getARMTargetCPU(const
.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")
Modified: cfe/trunk/test/Driver/arch.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/arch.c?rev=184970&r1=184969&r2=184970&view=diff
==============================================================================
--- cfe/trunk/test/Driver/arch.c (original)
+++ cfe/trunk/test/Driver/arch.c Wed Jun 26 12:19:48 2013
@@ -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"
+// V7: target triple = "armv7-unknown-linux-gnueabi"
+// V8: target triple = "armv8-unknown-linux-gnueabi"
More information about the cfe-commits
mailing list