[llvm] d4be972 - [test] Fix no-undef-type-md.ll.

Jordan Rupprecht via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 24 12:03:40 PST 2022


Author: Jordan Rupprecht
Date: 2022-01-24T12:01:25-08:00
New Revision: d4be9720e7e68f1316cda971e9b29dc880222200

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

LOG: [test] Fix no-undef-type-md.ll.

There are two test issues:
- The test assumes the current directory is writeable, but it may not be. Use `%t.o`-like paths instead of implicit `a.out`.
- The `RUN llvm-nm` line is missing a colon, so the test was not being exercised.

Added: 
    

Modified: 
    llvm/test/LTO/Resolution/X86/no-undef-type-md.ll

Removed: 
    


################################################################################
diff  --git a/llvm/test/LTO/Resolution/X86/no-undef-type-md.ll b/llvm/test/LTO/Resolution/X86/no-undef-type-md.ll
index afee5e656df17..8748375c84315 100644
--- a/llvm/test/LTO/Resolution/X86/no-undef-type-md.ll
+++ b/llvm/test/LTO/Resolution/X86/no-undef-type-md.ll
@@ -1,19 +1,19 @@
 ; RUN: opt <%s -o %t0.o -thinlto-bc -thinlto-split-lto-unit
 ; RUN: llvm-as -o %t1.o %S/Inputs/no-undef-type-md.ll
-; RUN: llvm-lto2 run -o a.out \
+; RUN: llvm-lto2 run -o %t-obj.o \
 ; RUN: %t0.o \
 ; RUN: -r=%t0.o,a, \
 ; RUN: -r=%t0.o,b,pl \
 ; RUN: %t1.o \
 ; RUN: -r=%t1.o,a,pl \
 ; RUN: | FileCheck --allow-empty --check-prefix=ERROR %s
-; RUN llvm-nm a.out.0 a.out.1 -S | FileCheck %s
+; RUN: llvm-nm %t-obj.o.0 %t-obj.o.1 -S | FileCheck %s
 
 ; ERROR-NOT: expected a Function or null
 ; ERROR-NOT: i32 (%0*, i32*)* undef
 
-; CHECK: a.out.0:
-; CHECK: a.out.1:
+; CHECK: -obj.o.0:
+; CHECK: -obj.o.1:
 
 ; ModuleID = 'test.cpp.o'
 source_filename = "test.cpp"


        


More information about the llvm-commits mailing list