[llvm] 7f1c077 - tests/CodeGen: Use %python lit substitution when invoking python

Tom Stellard via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 6 18:47:01 PDT 2021


Author: Tom Stellard
Date: 2021-07-06T18:46:36-07:00
New Revision: 7f1c077c3014760030cbaebdfccb8f99a4ec41c5

URL: https://github.com/llvm/llvm-project/commit/7f1c077c3014760030cbaebdfccb8f99a4ec41c5
DIFF: https://github.com/llvm/llvm-project/commit/7f1c077c3014760030cbaebdfccb8f99a4ec41c5.diff

LOG: tests/CodeGen: Use %python lit substitution when invoking python

This will use the python that LLVM was configured to use rather than
python from PATH.

Reviewed By: serge-sans-paille

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

Added: 
    

Modified: 
    llvm/test/CodeGen/NVPTX/ld-st-addrrspace.py
    llvm/test/CodeGen/NVPTX/wmma.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-01.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-02.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-03.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-04.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-05.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-06.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-07.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-08.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-09.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-10.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-11.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-12.py
    llvm/test/CodeGen/SystemZ/Large/branch-range-13.py
    llvm/test/CodeGen/SystemZ/Large/spill-01.py
    llvm/test/CodeGen/SystemZ/Large/spill-02.py

Removed: 
    


################################################################################
diff  --git a/llvm/test/CodeGen/NVPTX/ld-st-addrrspace.py b/llvm/test/CodeGen/NVPTX/ld-st-addrrspace.py
index 7c28620cec46d..cbeb027f2ac76 100644
--- a/llvm/test/CodeGen/NVPTX/ld-st-addrrspace.py
+++ b/llvm/test/CodeGen/NVPTX/ld-st-addrrspace.py
@@ -1,7 +1,7 @@
 # This test generates all variants of load/store instructions and verifies that
 # LLVM generates correct PTX for them.
 
-# RUN: python %s > %t.ll
+# RUN: %python %s > %t.ll
 # RUN: llc < %t.ll -march=nvptx64 -mcpu=sm_30 | FileCheck -check-prefixes=CHECK,CHECK_P64 %t.ll
 # RUN: llc < %t.ll -march=nvptx -mcpu=sm_30 | FileCheck -check-prefixes=CHECK,CHECK_P32 %t.ll
 

diff  --git a/llvm/test/CodeGen/NVPTX/wmma.py b/llvm/test/CodeGen/NVPTX/wmma.py
index 8a808bd377eb9..2daffd0e2cf6c 100644
--- a/llvm/test/CodeGen/NVPTX/wmma.py
+++ b/llvm/test/CodeGen/NVPTX/wmma.py
@@ -2,7 +2,7 @@
 # generates correct instructions for them.
 
 # Check all variants of instructions supported by PTX60 on SM70
-# RUN: python %s --ptx=60 --gpu-arch=70 > %t-ptx60-sm_70.ll
+# RUN: %python %s --ptx=60 --gpu-arch=70 > %t-ptx60-sm_70.ll
 # RUN: FileCheck %t-ptx60-sm_70.ll < %t-ptx60-sm_70.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16
 # RUN: FileCheck %t-ptx60-sm_70.ll < %t-ptx60-sm_70.ll \
@@ -11,7 +11,7 @@
 # RUN:           | FileCheck %t-ptx60-sm_70.ll
 
 # Check all variants of instructions supported by PTX61 on SM70
-# RUN: python %s --ptx=61 --gpu-arch=70 > %t-ptx61-sm_70.ll
+# RUN: %python %s --ptx=61 --gpu-arch=70 > %t-ptx61-sm_70.ll
 # RUN: FileCheck %t-ptx61-sm_70.ll < %t-ptx61-sm_70.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16,EXTGEOM
 # RUN: FileCheck %t-ptx61-sm_70.ll < %t-ptx61-sm_70.ll \
@@ -20,7 +20,7 @@
 # RUN:           | FileCheck %t-ptx61-sm_70.ll
 
 # Check all variants of instructions supported by PTX63 on SM72
-# RUN: python %s --ptx=63 --gpu-arch=72 > %t-ptx63-sm_72.ll
+# RUN: %python %s --ptx=63 --gpu-arch=72 > %t-ptx63-sm_72.ll
 # RUN: FileCheck %t-ptx63-sm_72.ll < %t-ptx63-sm_72.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16,EXTGEOM,INT
 # RUN: FileCheck %t-ptx63-sm_72.ll < %t-ptx63-sm_72.ll \
@@ -29,7 +29,7 @@
 # RUN:           | FileCheck %t-ptx63-sm_72.ll
 
 # Check all variants of instructions supported by PTX63 on SM75
-# RUN: python %s --ptx=63 --gpu-arch=75 > %t-ptx63-sm_75.ll
+# RUN: %python %s --ptx=63 --gpu-arch=75 > %t-ptx63-sm_75.ll
 # RUN: FileCheck %t-ptx63-sm_75.ll < %t-ptx63-sm_75.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16,EXTGEOM,INT,SUBINT
 # RUN: FileCheck %t-ptx63-sm_75.ll < %t-ptx63-sm_75.ll \
@@ -38,7 +38,7 @@
 # RUN:           | FileCheck %t-ptx63-sm_75.ll
 
 # Check all variants of instructions supported by PTX64 on SM70+
-# RUN: python %s --ptx=64 --gpu-arch=70 > %t-ptx64-sm_70.ll
+# RUN: %python %s --ptx=64 --gpu-arch=70 > %t-ptx64-sm_70.ll
 # RUN: FileCheck %t-ptx64-sm_70.ll < %t-ptx64-sm_70.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16,EXTGEOM,MMA
 # RUN: FileCheck %t-ptx64-sm_70.ll < %t-ptx64-sm_70.ll \
@@ -47,7 +47,7 @@
 # RUN:           | FileCheck %t-ptx64-sm_70.ll
 
 # Check all variants of instructions supported by PTX65 on SM75+
-# RUN: python %s --ptx=65 --gpu-arch=75 > %t-ptx65-sm_75.ll
+# RUN: %python %s --ptx=65 --gpu-arch=75 > %t-ptx65-sm_75.ll
 # RUN: FileCheck %t-ptx65-sm_75.ll < %t-ptx65-sm_75.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16,EXTGEOM,INT,SUBINT,MMA,PTX65MMA
 # RUN: FileCheck %t-ptx65-sm_75.ll < %t-ptx65-sm_75.ll \
@@ -56,7 +56,7 @@
 # RUN:           | FileCheck %t-ptx65-sm_75.ll
 
 # Check all variants of instructions supported by PTX70 on SM80+
-# RUN: python %s --ptx=70 --gpu-arch=80 > %t-ptx70-sm_80.ll
+# RUN: %python %s --ptx=70 --gpu-arch=80 > %t-ptx70-sm_80.ll
 # RUN: FileCheck %t-ptx70-sm_80.ll < %t-ptx70-sm_80.ll \
 # RUN:           --check-prefixes=INTRINSICS,M16N16,EXTGEOM,INT,SUBINT,MMA,ALTFLOAT,DOUBLE,PTX65MMA,PTX70MMA
 # RUN: FileCheck %t-ptx70-sm_80.ll < %t-ptx70-sm_80.ll \

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-01.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-01.py
index 49ce623129a79..162cabdc3bb4b 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-01.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-01.py
@@ -1,6 +1,6 @@
 # Test normal conditional branches in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py
index 155f742dca67b..a636309963b27 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-02.py
@@ -1,6 +1,6 @@
 # Test normal conditional branches in cases where block alignments cause
 # some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu -align-all-blocks=8 | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu -align-all-blocks=8 | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-03.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-03.py
index f58bedf5e0d9a..025cbdfeff737 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-03.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-03.py
@@ -1,6 +1,6 @@
 # Test 32-bit COMPARE AND BRANCH in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-04.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-04.py
index 6aca0a229221d..9292dc9110bdf 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-04.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-04.py
@@ -1,6 +1,6 @@
 # Test 64-bit COMPARE AND BRANCH in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-05.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-05.py
index 326fe8b077c52..4c01f90ec2bc6 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-05.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-05.py
@@ -1,6 +1,6 @@
 # Test 32-bit COMPARE IMMEDIATE AND BRANCH in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-06.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-06.py
index 44cc5c6fdf892..45538870f66a3 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-06.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-06.py
@@ -1,6 +1,6 @@
 # Test 64-bit COMPARE IMMEDIATE AND BRANCH in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-07.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-07.py
index 71e958868a7d2..4fd72d68d7d37 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-07.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-07.py
@@ -1,6 +1,6 @@
 # Test 32-bit BRANCH RELATIVE ON COUNT in cases where some branches are out
 # of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-08.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-08.py
index 2ef6859fc5c8b..7e6e2bf9d039f 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-08.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-08.py
@@ -1,6 +1,6 @@
 # Test 64-bit BRANCH RELATIVE ON COUNT in cases where some branches are out
 # of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-09.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-09.py
index 09d5d691548d8..cfdf31d43b636 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-09.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-09.py
@@ -1,6 +1,6 @@
 # Test 32-bit COMPARE LOGICAL AND BRANCH in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-10.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-10.py
index 258989b748f49..4b7ba24388b7f 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-10.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-10.py
@@ -1,6 +1,6 @@
 # Test 64-bit COMPARE LOGICAL AND BRANCH in cases where the sheer number of
 # instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-11.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-11.py
index 22776aaabf0eb..1d330a3c412ce 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-11.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-11.py
@@ -1,6 +1,6 @@
 # Test 32-bit COMPARE LOGICAL IMMEDIATE AND BRANCH in cases where the sheer
 # number of instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-12.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-12.py
index 0911953a47a3a..56155077e1f4c 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-12.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-12.py
@@ -1,6 +1,6 @@
 # Test 64-bit COMPARE LOGICAL IMMEDIATE AND BRANCH in cases where the sheer
 # number of instructions causes some branches to be out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # Construct:
 #

diff  --git a/llvm/test/CodeGen/SystemZ/Large/branch-range-13.py b/llvm/test/CodeGen/SystemZ/Large/branch-range-13.py
index 13543a7d1ac52..a827b16b7abea 100644
--- a/llvm/test/CodeGen/SystemZ/Large/branch-range-13.py
+++ b/llvm/test/CodeGen/SystemZ/Large/branch-range-13.py
@@ -1,7 +1,7 @@
 # Test that inline assembly get the right size value so that a branch across
 # a block containing them gets relaxed.
 
-# RUN: python %s | llc -mtriple=s390x-linux-gnu -mcpu=z196 -enable-post-misched=false \
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu -mcpu=z196 -enable-post-misched=false \
 # RUN:    | FileCheck %s
 
 # Construct:

diff  --git a/llvm/test/CodeGen/SystemZ/Large/spill-01.py b/llvm/test/CodeGen/SystemZ/Large/spill-01.py
index 2831804df9e57..c1b094e36e5f7 100644
--- a/llvm/test/CodeGen/SystemZ/Large/spill-01.py
+++ b/llvm/test/CodeGen/SystemZ/Large/spill-01.py
@@ -1,5 +1,5 @@
 # Test cases where MVC is used for spill slots that end up being out of range.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # There are 8 usable call-saved GPRs, two of which are needed for the base
 # registers.  The first 160 bytes of the frame are needed for the ABI

diff  --git a/llvm/test/CodeGen/SystemZ/Large/spill-02.py b/llvm/test/CodeGen/SystemZ/Large/spill-02.py
index 0fefe639c5d82..aa2900b3d0489 100644
--- a/llvm/test/CodeGen/SystemZ/Large/spill-02.py
+++ b/llvm/test/CodeGen/SystemZ/Large/spill-02.py
@@ -1,6 +1,6 @@
 # Test cases where we spill from one frame index to another, both of which
 # are out of range of MVC, and both of which need emergency spill slots.
-# RUN: python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
+# RUN: %python %s | llc -mtriple=s390x-linux-gnu | FileCheck %s
 
 # CHECK: f1:
 # CHECK: %fallthru


        


More information about the llvm-commits mailing list