[PATCH] D39465: Add feature to determine if host architecture is 64-bit in llvm-lit
Jake Ehrlich via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Oct 31 13:25:45 PDT 2017
jakehehrlich updated this revision to Diff 121041.
jakehehrlich added a comment.
1. Deleted config.host_arch as a feature
2. Changed host-arch-is64bit to llvm-64-bits
3. Changed code to by more idiomatic as pointed out by Zach
Repository:
rL LLVM
https://reviews.llvm.org/D39465
Files:
test/lit.cfg.py
test/lit.site.cfg.py.in
Index: test/lit.site.cfg.py.in
===================================================================
--- test/lit.site.cfg.py.in
+++ test/lit.site.cfg.py.in
@@ -42,6 +42,7 @@
config.build_shared_libs = @BUILD_SHARED_LIBS@
config.link_llvm_dylib = @LLVM_LINK_LLVM_DYLIB@
config.llvm_libxml2_enabled = "@LLVM_LIBXML2_ENABLED@"
+config.llvm_host_triple = '@LLVM_HOST_TRIPLE@'
# Support substitution of the tools_dir with user parameters. This is
# used when we can't determine the tool dir at configuration time.
Index: test/lit.cfg.py
===================================================================
--- test/lit.cfg.py
+++ test/lit.cfg.py
@@ -168,6 +168,9 @@
config.available_features.add(arch.lower() + '-registered-target')
# Features
+known_arches = ["x86_64", "mips64", "ppc64", "aarch64"]
+if any(config.llvm_host_triple.startswith(x) for x in known_arches):
+ config.available_features.add("llvm-64-bits")
# Others/can-execute.txt
if sys.platform not in ['win32']:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39465.121041.patch
Type: text/x-patch
Size: 991 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171031/a7224c98/attachment.bin>
More information about the llvm-commits
mailing list