[PATCH] Default to armv7 cpu for NaCl when march=arm
Derek Schuff
dschuff at google.com
Thu Mar 26 13:58:22 PDT 2015
- add unittest
http://reviews.llvm.org/D8589
Files:
lib/Support/Triple.cpp
unittests/ADT/TripleTest.cpp
Index: lib/Support/Triple.cpp
===================================================================
--- lib/Support/Triple.cpp
+++ lib/Support/Triple.cpp
@@ -1137,6 +1137,8 @@
default:
return "strongarm";
}
+ case llvm::Triple::NaCl:
+ return "cortex-a8";
default:
switch (getEnvironment()) {
case llvm::Triple::EABIHF:
Index: unittests/ADT/TripleTest.cpp
===================================================================
--- unittests/ADT/TripleTest.cpp
+++ unittests/ADT/TripleTest.cpp
@@ -669,6 +669,10 @@
EXPECT_STREQ("cortex-a8", Triple.getARMCPUForArch());
EXPECT_STREQ("swift", Triple.getARMCPUForArch("armv7s"));
}
+ {
+ llvm::Triple Triple("arm--nacl");
+ EXPECT_STREQ("cortex-a8", Triple.getARMCPUForArch("arm"));
+ }
}
}
EMAIL PREFERENCES
http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D8589.22752.patch
Type: text/x-patch
Size: 791 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150326/510cab4f/attachment.bin>
More information about the llvm-commits
mailing list