[llvm] r358177 - [llvm] [lit] Add target-x86* features

Michal Gorny via llvm-commits llvm-commits at lists.llvm.org
Thu Apr 11 07:58:39 PDT 2019


Author: mgorny
Date: Thu Apr 11 07:58:39 2019
New Revision: 358177

URL: http://llvm.org/viewvc/llvm-project?rev=358177&view=rev
Log:
[llvm] [lit] Add target-x86* features

Add a 'target-x86' and 'target-x86_64' feature sthat indicates that
the default target is 32-bit or 64-bit x86, appropriately.  Combined
with 'native' feature, we're going to use this to control x86-specific
LLDB native process tests.

Differential Revision: https://reviews.llvm.org/D60474

Modified:
    llvm/trunk/utils/lit/lit/llvm/config.py

Modified: llvm/trunk/utils/lit/lit/llvm/config.py
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/utils/lit/lit/llvm/config.py?rev=358177&r1=358176&r2=358177&view=diff
==============================================================================
--- llvm/trunk/utils/lit/lit/llvm/config.py (original)
+++ llvm/trunk/utils/lit/lit/llvm/config.py Thu Apr 11 07:58:39 2019
@@ -96,6 +96,10 @@ class LLVMConfig(object):
                 features.add('x86_64-linux')
             if re.match(r'.*-windows-msvc$', target_triple):
                 features.add('target-windows')
+            if re.match(r'^i.86.*', target_triple):
+                features.add('target-x86')
+            elif re.match(r'^x86_64.*', target_triple):
+                features.add('target-x86_64')
 
         use_gmalloc = lit_config.params.get('use_gmalloc', None)
         if lit.util.pythonize_bool(use_gmalloc):




More information about the llvm-commits mailing list