For PR1319: Upgrade to new test harness
authorReid Spencer <rspencer@reidspencer.com>
Sun, 15 Apr 2007 18:11:57 +0000 (18:11 +0000)
committerReid Spencer <rspencer@reidspencer.com>
Sun, 15 Apr 2007 18:11:57 +0000 (18:11 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36073 91177308-0d34-0410-b5e6-96231b3b80d8

38 files changed:
test/Linker/2002-07-17-LinkTest2.ll
test/Linker/2003-01-30-LinkerRename.ll
test/Linker/2003-01-30-LinkerTypeRename.ll
test/Linker/2003-04-21-Linkage.ll
test/Linker/2003-04-23-LinkOnceLost.ll
test/Linker/2003-04-26-NullPtrLinkProblem.ll
test/Linker/2003-05-15-TypeProblem.ll
test/Linker/2003-05-31-LinkerRename.ll
test/Linker/2003-06-02-TypeResolveProblem.ll
test/Linker/2003-06-02-TypeResolveProblem2.ll
test/Linker/2003-08-20-OpaqueTypeResolve.ll
test/Linker/2003-08-23-GlobalVarLinking.ll
test/Linker/2003-08-23-RecursiveOpaqueTypeResolve.ll
test/Linker/2003-08-24-InheritPtrSize.ll
test/Linker/2003-08-28-TypeResolvesGlobal.ll
test/Linker/2003-08-28-TypeResolvesGlobal2.ll
test/Linker/2003-08-28-TypeResolvesGlobal3.ll
test/Linker/2003-10-21-ConflictingTypesTolerance.ll
test/Linker/2003-10-27-LinkOncePromote.ll
test/Linker/2003-11-18-TypeResolution.ll
test/Linker/2004-02-17-WeakStrongLinkage.ll
test/Linker/2004-05-07-TypeResolution1.ll
test/Linker/2004-12-03-DisagreeingType.ll
test/Linker/2005-02-12-ConstantGlobals-2.ll
test/Linker/2005-02-12-ConstantGlobals.ll
test/Linker/2005-12-06-AppendingZeroLengthArrays.ll
test/Linker/2006-01-19-ConstantPacked.ll
test/Linker/2006-06-15-GlobalVarAlignment.ll
test/Linker/AppendingLinkage.ll
test/Linker/AppendingLinkage2.ll
test/Linker/ConstantGlobals1.ll
test/Linker/ConstantGlobals2.ll
test/Linker/ConstantGlobals3.ll
test/Linker/LinkOnce.ll
test/Linker/dg.exp
test/Linker/redefinition.ll
test/Linker/testlink1.ll
test/Linker/weakextern.ll

index 67bf686448e87ecf858096e3a8f3dfef38982cb1..312b9b90d213bc12b94b760f5cc654c3d2c66d9c 100644 (file)
@@ -2,7 +2,7 @@
 
 ; RUN: llvm-as > %t1.bc < /dev/null
 ; RUN: llvm-upgrade < %s | llvm-as > %t2.bc
-; RUN: llvm-link %t[12].bc
+; RUN: llvm-link %t1.bc %t2.bc
 
 %work = global int (int, int)* %zip
 
index 3e4c50c03d213f05b097615cbadb9dc72e57a130..c5f3bde4d6392abb27ac98c66314cdb1d15212e6 100644 (file)
@@ -1,11 +1,9 @@
 ; This fails because the linker renames the external symbol not the internal 
 ; one...
 
-; RUN: echo "implementation internal int %foo() { ret int 7 }" | llvm-upgrade |\
-; RUN:    llvm-as > %t.1.bc
-; RUN: llvm-upgrade < %s | llvm-as -o %t.2.bc -f
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep '@foo()' | grep -v internal
+; RUN: echo {define internal i32 @foo() \{ ret i32 7 \} } | llvm-as > %t.1.bc
+; RUN: llvm-as < %s -o %t.2.bc -f
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep @foo() | grep -v internal
 
-implementation
-int %foo() { ret int 0 }
+define i32 @foo() { ret i32 0 }
 
index f96805427f513bf882f1a3bd8b25586a558200cc..288daf1cba1c3b15adf68a17d62c6e9ba4bc7965 100644 (file)
@@ -1,9 +1,9 @@
 ; This fails because the linker renames the non-opaque type not the opaque 
 ; one...
 
-; RUN: echo "%Ty = type opaque %GV = external global %Ty*" | llvm-as > %t.1.bc
+; RUN: echo {%Ty = type opaque @GV = external global %Ty*} | llvm-as > %t.1.bc
 ; RUN: llvm-as < %s > %t.2.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep '%Ty ' | not grep opaque
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep {%Ty } | not grep opaque
 
-%Ty = type int
+%Ty = type i32
 
index 742faa8c99e838347114056b0da0f30d82f89b33..7e00943c28b80ef8ecd9a31d91d0029232983dcb 100644 (file)
@@ -1,15 +1,14 @@
-; RUN: echo "%X = linkonce global int 5  implementation linkonce int %foo() { ret int 7 }" | llvm-upgrade | llvm-as > %t.1.bc
-; RUN: llvm-upgrade < %s | llvm-as -o %t.2.bc -f
-; RUN: llvm-link %t.[12].bc 
-%X = external global int 
+; RUN: echo {@X = linkonce global i32 5 \
+; RUN:   define linkonce i32 @foo() \{ ret i32 7 \} } | llvm-as > %t.1.bc
+; RUN: llvm-as < %s -o %t.2.bc -f
+; RUN: llvm-link %t.1.bc  %t.2.bc
+@X = external global i32 
 
-implementation
+declare i32 @foo() 
 
-declare int %foo() 
-
-void %bar() {
-       load int* %X
-       call int %foo()
+define void @bar() {
+       load i32* @X
+       call i32 @foo()
        ret void
 }
 
index 3996cc40b77a9c544954509fcbf7be534dcd9be8..cf63fb35cedea36e063a740883ac585d2244f73d 100644 (file)
@@ -1,9 +1,10 @@
 ; This fails because the linker renames the non-opaque type not the opaque 
 ; one...
 
-; RUN: echo "implementation linkonce void %foo() { ret void } " | llvm-upgrade|\
-; RUN:    llvm-as -o %t.2.bc -f
-; RUN: llvm-upgrade < %s | llvm-as -o %t.1.bc -f
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep foo | grep linkonce
+; RUN: echo { define linkonce void @foo() \{ ret void \} } | \
+; RUN:   llvm-as -o %t.2.bc -f
+; RUN: llvm-as < %s -o %t.1.bc -f
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep foo | grep linkonce
+
+declare void @foo()
 
-declare void %foo()
index 3caf7632cb7ee5f241605d6ccf886a5c943154a3..029bce264a592adb038342a19ee870db3483205e 100644 (file)
@@ -1,9 +1,9 @@
 ; This one fails because the LLVM runtime is allowing two null pointers of
 ; the same type to be created!
 
-; RUN: echo "%T = type int" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%T = type int} | llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as -f > %t.1.bc
-; RUN: llvm-link %t.[12].bc
+; RUN: llvm-link %t.1.bc %t.2.bc
 
 %T = type opaque
 
index ee1caf78314c542d7b7e8ec8e17240b810771fed..2c7576fe072cb2709558d3753b1556cb12a8a322 100644 (file)
@@ -1,9 +1,9 @@
 ; This one fails because the LLVM runtime is allowing two null pointers of
 ; the same type to be created!
 
-; RUN: echo "%S = type { %T*} %T = type opaque" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%S = type \{ %T*\} %T = type opaque} | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc
+; RUN: llvm-link %t.1.bc %t.2.bc
 
 %S = type { %T* }
 %T = type int
index 375c16017b3dad479aa0a3f182fcdab73895017a..3e8b2c81bd60a1944d981d31d2a8bf4197ff8385 100644 (file)
@@ -1,17 +1,17 @@
-; The funcresolve pass will (intentionally) llvm-link an _internal_ function body with an
-; external declaration.  Because of this, if we LINK an internal function body into
-; a program that already has an external declaration for the function name, we must
-; rename the internal function to something that does not conflict.
+; The funcresolve pass will (intentionally) llvm-link an _internal_ function 
+; body with an external declaration.  Because of this, if we LINK an internal 
+; function body into a program that already has an external declaration for 
+; the function name, we must rename the internal function to something that 
+; does not conflict.
 
-; RUN: echo "implementation internal int %foo() { ret int 7 }" | llvm-as > %t.1.bc
+; RUN: echo { define internal i32 @foo() \{ ret i32 7 \} } | llvm-as > %t.1.bc
 ; RUN: llvm-as < %s > %t.2.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep 'internal' | not grep '%foo('
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep internal | not grep %foo(
 
-implementation
-declare int %foo() 
+declare i32 @foo() 
 
-int %test() { 
-  %X = call int %foo()
-  ret int %X
+define i32 @test() { 
+  %X = call i32 @foo()
+  ret i32 %X
 }
 
index 05d7adf13fec03ffc8233fd63ed33e44df63c3c8..9b1c6f42307081e488cb56bd4d3226c676e8b6ee 100644 (file)
@@ -1,6 +1,6 @@
-; RUN: echo "%T = type opaque" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%T = type opaque} | llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc
+; RUN: llvm-link %t.1.bc %t.2.bc
 
 %T = type opaque
 %a = constant { %T* }  { %T* null }
index c0228c4af869c6c03841bc67ae7df8840a9eb6be..0dcca98ac3f45db2330a74ef7fcc213ce9e5d01e 100644 (file)
@@ -1,6 +1,6 @@
-; RUN: echo "%T = type int" | llvm-upgrade | llvm-as > %t.1.bc
+; RUN: echo {%T = type int} | llvm-upgrade | llvm-as > %t.1.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.2.bc
-; RUN: llvm-link %t.[12].bc
+; RUN: llvm-link %t.1.bc %t.2.bc
 
 %T = type opaque
 
index 6b378d586be0158e8110e6ff9ca7378fbb783382..b659b1ab770886952d5ae60bfdfcdb73ababd1f1 100644 (file)
@@ -1,7 +1,6 @@
-
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
-; RUN: echo "%S = type { int, int* }" | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[12].bc
+; RUN: echo {%S = type \{ int, int* \} } | llvm-upgrade | llvm-as > %t.out2.bc
+; RUN: llvm-link %t.out1.bc %t.out2.bc
 
 %T = type opaque
 %S = type { int, %T* }
index e249641be32fe9a801ba32765750e36e6c4e6968..45d77745a2005e79fff28b7a682e2d8d69223a36 100644 (file)
@@ -1,6 +1,7 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
-; RUN: echo "%S = external global { int, opaque* } declare void %F(opaque*)" | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[12].bc | llvm-dis | not grep opaque
+; RUN: echo {%S = external global \{ int, opaque* \} declare void %F(opaque*)}\
+; RUN:   | llvm-upgrade | llvm-as > %t.out2.bc
+; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | not grep opaque
 
 ; After linking this testcase, there should be no opaque types left.  The two
 ; S's should cause the opaque type to be resolved to 'int'.
index 1a95b874037ebab8c92af980381bf0149c60bd40..50aae13cce0b7159421b62e7f87a15b85c94f1ea 100644 (file)
@@ -3,6 +3,6 @@
 
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
 ; RUN: echo "%S = type { %S*, int* }" | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[12].bc
+; RUN: llvm-link %t.out1.bc %t.out2.bc
 
 %S = type { %S*, opaque* }
index dc446155ff74f5d65a26490e9ab2a74ab31e2dab..f93c054dec7bf266f379ba1eb8a8368cb3d7c94c 100644 (file)
@@ -1,9 +1,9 @@
-; Linking these a module with a specified pointer size to one without a 
+; Linking a module with a specified pointer size to one without a 
 ; specified pointer size should not cause a warning!
 
 ; RUN: llvm-as < %s > %t.out1.bc
-; RUN: echo "" | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[12].bc 2>&1 | not grep WARNING
+; RUN: echo {} | llvm-as > %t.out2.bc
+; RUN: llvm-link %t.out1.bc %t.out2.bc |& not grep warning
 
-target pointersize = 64
+target datalayout = "e-p:64:64"
 
index 5e90682dc194750cfbd99e4e5ec3c24a57720993..41aef3230b27d1a7558d8514ada41e4134f893c7 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
 ; RUN: echo "%S = type int" | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[21].bc
+; RUN: llvm-link %t.out2.bc %t.out1.bc
 
 %S = type opaque
 
index 619c8444adf88bc3dc820d79e11b24f8685fb19d..212ef2bd1f2655b2df1240b2350124684bf32943 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
 ; RUN: echo "%S = type int" | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[21].bc
+; RUN: llvm-link %t.out2.bc %t.out1.bc
 
 %S = type opaque
 
index 40023fd6603c8740234b08abcc3777583ca8e0f6..5a52f9c1af5713130386917d850df20a3c040e2c 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
 ; RUN: echo "%S = type int" | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[21].bc
+; RUN: llvm-link %t.out2.bc %t.out1.bc
 
 %S = type opaque
 
index db098d6f7c7116fab1c3099ce667fbadc5fa4f82..07d4b2d90006702abd7b0e97f9f052351bdc5aa9 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
-; RUN: echo "%S = type [8 x int] external global %S " | llvm-upgrade | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out[12].bc | llvm-dis | grep %S | grep '{'
+; RUN: echo { %S = type \[8 x i32\] external global %S } | llvm-as > %t.out2.bc
+; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | grep %S | grep \{
 
 %S = type { int }
 
index 617e5c6ebda1b0b3895881f61213eeaa205aece3..a4e5aa6cdd987b99d4916ef1d523078e18d37c75 100644 (file)
@@ -3,6 +3,6 @@
 
 ; RUN: echo "%X = global int 7" | llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc
+; RUN: llvm-link %t.1.bc %t.2.bc
 
 %X = linkonce global int 7
index 07af9697c77bea6c51e35da1536f6e05c31e4b76..ff22e31437226766b0e39bbd9be479facf156164 100644 (file)
@@ -6,7 +6,7 @@
 
 ; RUN: llvm-upgrade %s | llvm-as > %t.out2.bc
 ; RUN: echo "%T1 = type opaque  @GVar = external global %T1*" | llvm-as > %t.out1.bc
-; RUN: llvm-link %t.out[12].bc
+; RUN: llvm-link %t.out1.bc %t.out2.bc
 
        %T1 = type opaque
        %T2 = type int
index b2579d411f598668eb0cb8c9ec4aa5fd47bc8586..4c6e8f869e17fa628cafc8c2ac7f8dc8c5a17e15 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out2.bc
 ; RUN: echo "%me = global int* null" | llvm-upgrade | llvm-as > %t.out1.bc
-; RUN: llvm-link %t.out[12].bc -o /dev/null -f
+; RUN: llvm-link %t.out1.bc %t.out2.bc -o /dev/null -f
 
 %me = weak global int * null
 
index 94c5af0f958592c712a8a6e2ddb743895461a645..1c90079eae96ab9dd43f4f5dbdec8b95e4e932b4 100644 (file)
@@ -1,5 +1,5 @@
 ; RUN: llvm-upgrade < %s | llvm-as -f -o %t1.bc
-; RUN: llvm-upgrade < `dirname %s`/2004-05-07-TypeResolution2.ll | \
+; RUN: llvm-upgrade < %p/2004-05-07-TypeResolution2.ll | \
 ; RUN:    llvm-as -o %t2.bc -f
 ; RUN: llvm-link -f -o %t3.bc %t1.bc %t2.bc
 
index 9849e0c1fe527eb88789ed876dd93304fbbda318..63d851b1673b95f5580a16f44437e9f29fbd26dd 100644 (file)
@@ -1,8 +1,9 @@
-; RUN: echo "%G = weak global {{{{double}}}} zeroinitializer" | llvm-as > %t.out2.bc
+; RUN: echo {@G = weak global \{\{\{\{double\}\}\}\} zeroinitializer } | \
+; RUN:   llvm-as > %t.out2.bc
 ; RUN: llvm-as < %s > %t.out1.bc
-; RUN: llvm-link %t.out[12].bc | llvm-dis | not grep '\}'
+; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | not grep {\}}
 
 ; When linked, the global above should be eliminated, being merged with the 
 ; global below.
 
-%G = global double 1.0
+@G = global double 1.0
index bf93ca871f13c47a0d7a0baf5c2746201785fdbc..bedeb51069504d19f6f37b87a6c1c5e8c945d378 100644 (file)
@@ -1,8 +1,8 @@
 ; Test that a prototype can be marked const, and the definition is allowed
 ; to be nonconst.
 
-; RUN: echo "%X = external constant int" | llvm-upgrade | llvm-as > %t.2.bc
-; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep 'global i32 7'
+; RUN: echo {@X = external constant i32} | llvm-as > %t.2.bc
+; RUN: llvm-as < %s > %t.1.bc
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep {global i32 7}
 
-%X = global int 7
+@X = global i32 7
index 5bb43a7821a2ae7ecc18c3ceb3941e65d66382df..fbc0bc141de6a99f0adfff43e5d61dcb93b613f6 100644 (file)
@@ -1,8 +1,8 @@
 ; Test that a prototype can be marked const, and the definition is allowed
 ; to be nonconst.
 
-; RUN: echo "%X = global int 7" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {@X = global i32 7} | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep 'global i32 7'
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep {global i32 7}
 
-%X = external constant int
+@X = external constant i32
index 4c94f54101715f7d18e41c171b13d3a2b9eb8346..3e57becbbe4433132061984096f578d6ccb143a9 100644 (file)
@@ -1,7 +1,7 @@
-; RUN: echo "@G = appending global [0 x i32] zeroinitializer" | \
+; RUN: echo { @G = appending global \[0 x i32\] zeroinitializer } | \
 ; RUN:   llvm-as > %t.out2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.out1.bc
-; RUN: llvm-link %t.out[12].bc | llvm-dis | grep '@G ='
+; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | grep {@G =}
 
 ; When linked, the globals should be merged, and the result should still 
 ; be named '@G'.
index df56105e9d68e704fa0af793be4d6bda47c04274..7aa0bc3db7668ad132cc0650b9078e650ab828a8 100644 (file)
@@ -1,4 +1,5 @@
-; RUN: llvm-upgrade < %s | llvm-as -f -o %s.bc ; llvm-link -f -o %s.linked %s.bc
+; RUN: llvm-upgrade < %s | llvm-as -f -o %s.bc 
+; RUN: llvm-link -f -o %s.linked %s.bc
 
 target endian = big
 target pointersize = 32
index 22e9755caea8ac46ed963145a03ae271aa2c0c3e..6e6d56a039ec8b13ebcd76c60ea4aaa4924ccbc8 100644 (file)
@@ -1,7 +1,7 @@
 ; The linker should choose the largest alignment when linking.
 
-; RUN: echo "%X = global int 7, align 8" | llvm-upgrade | llvm-as > %t.2.bc
-; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep 'align 8'
+; RUN: echo {@X = global i32 7, align 8} | llvm-as > %t.2.bc
+; RUN: llvm-as < %s > %t.1.bc
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep {align 8}
 
-%X = weak global int 7, align 4
+@X = weak global i32 7, align 4
index 84c09d81a3c8f2dbb9cfdadf28377fec9afe0ff6..d59a37414813d2fabf902940190c4a889d93607f 100644 (file)
@@ -1,9 +1,9 @@
 ; Test that appending linkage works correctly.
 
-; RUN: echo "%X = appending global [1x int] [int 8]" | llvm-upgrade | \
-; RUN:    llvm-as > %t.2.bc
+; RUN: echo {%X = appending global \[1 x int\] \[int 8\] } | \
+; RUN:   llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep 7 | grep 4 | grep 8
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep 7 | grep 4 | grep 8
 
 %X = appending global [2 x int] [int 7, int 4]
 
index a906f698bce7ee929e8bdcdef2da7095b9978311..fc992e0b92a45f2e957a0f8affbd2378be38849f 100644 (file)
@@ -1,7 +1,8 @@
 ; Test that appending linkage works correctly when arrays are the same size.
 
-; RUN: echo "%X = appending global [1x int] [int 8]" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%X = appending global \[1 x int\] \[int 8\] } | \
+; RUN:   llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep 7 | grep 8
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep 7 | grep 8
 
 %X = appending global [1 x int] [int 7]
index 1a05f7a9eb4697031e94271fef2faf35939a7992..a5a9ce9ca407cba2d475d48fc769cb1f3f076847 100644 (file)
@@ -1,7 +1,8 @@
 ; Test that appending linkage works correctly when arrays are the same size.
 
-; RUN: echo "%X = constant [1x int] [int 8]" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%X = constant \[1 x int\] \[int 8\] } | \
+; RUN:   llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep constant
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep constant
 
 %X = uninitialized global [1 x int]
index ae97a0ba6262651d35580b5639f7ad0d1441c4ea..612603d7ef1567fff53225648067a8f5d538be7c 100644 (file)
@@ -1,7 +1,8 @@
 ; Test that appending linkage works correctly when arrays are the same size.
 
-; RUN: echo "%X = external global [1x int]" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%X = external global \[1 x int\] } | \
+; RUN:   llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade %s -o - | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep constant
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep constant
 
 %X = constant [1 x int] [ int 12 ]
index 9a84c3a350eaad2f003859e7d415c4fd9afef986..4435f2de08a87e832539e222157c95f75ddc65f0 100644 (file)
@@ -1,7 +1,8 @@
 ; Test that appending linkage works correctly when arrays are the same size.
 
-; RUN: echo "%X = external constant [1x int]" | llvm-upgrade | llvm-as > %t.2.bc
+; RUN: echo {%X = external constant \[1 x int\] } | \
+; RUN:   llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis | grep constant
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep constant
 
 %X = uninitialized global [1 x int] 
index 95f65ae12a4a9cc9a31dadd9d2674df34a31837e..b1a021606064297e93a335add3c3c977114645b2 100644 (file)
@@ -3,6 +3,6 @@
 
 ; RUN: echo "%X = linkonce global int 8" | llvm-upgrade | llvm-as > %t.2.bc
 ; RUN: llvm-upgrade < %s | llvm-as > %t.1.bc
-; RUN: llvm-link %t.[12].bc | llvm-dis
+; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis
 
 %X = linkonce global int 7
index ff34508c3c64c167429097e1c896dd65daaff278..879685ca879df60056ae48bf4411e0df73b77dc5 100644 (file)
@@ -1,3 +1,3 @@
-load_lib llvm-dg.exp
+load_lib llvm.exp
 
-llvm-runtest [lsort [glob -nocomplain $srcdir/$subdir/*.{ll,llx,c,cpp,tr}]]
+RunLLVMTests [lsort [glob -nocomplain $srcdir/$subdir/*.{ll,llx,c,cpp,tr}]]
index ae2dc624756a33f6a97b38f690045e9f4e7a56af..bba60c572aed651cc0837548adce2e36b6e733a3 100644 (file)
@@ -2,9 +2,9 @@
 ; in different modules.
 ; RUN: llvm-as %s -o %t.foo1.bc -f
 ; RUN: llvm-as %s -o %t.foo2.bc -f
-; RUN: echo "define void @foo(i32 %x) { ret void }" | llvm-as -o %t.foo3.bc -f
-; RUN: llvm-link %t.foo1.bc %t.foo2.bc -o %t.bc 2>&1 | \
-; RUN:   grep "Function is already defined"
-; RUN: llvm-link %t.foo1.bc %t.foo3.bc -o %t.bc 2>&1 | \
-; RUN:   grep "Function 'foo' defined as both"
+; RUN: echo {define void @foo(i32 %x) { ret void }} | llvm-as -o %t.foo3.bc -f
+; RUN: ignore llvm-link %t.foo1.bc %t.foo2.bc -o %t.bc |& \
+; RUN:   grep {Function is already defined}
+; RUN: ignore llvm-link %t.foo1.bc %t.foo3.bc -o %t.bc |& \
+; RUN:   grep {Function 'foo' defined as both}
 define void @foo() { ret void }
index ccdd5f3b0be1198123fef8974b2456f4dfe1a95d..df89d84c17faa37b59342dcb969d045687e3d1f3 100644 (file)
@@ -1,5 +1,5 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.bc
-; RUN: llvm-upgrade < `dirname %s`/testlink2.ll | llvm-as > %t2.bc
+; RUN: llvm-upgrade < %p/testlink2.ll | llvm-as > %t2.bc
 ; RUN: llvm-link %t.bc %t2.bc
 
 %MyVar     = external global int
index 3bda535d0ca5ca97f9ae048b215471bb8fb2d2eb..60ca59655b2005be33446208c41861ce380fef68 100644 (file)
@@ -1,9 +1,9 @@
 ; RUN: llvm-upgrade < %s | llvm-as > %t.bc
-; RUN: llvm-upgrade < `dirname %s`/testlink1.ll | llvm-as > %t2.bc
+; RUN: llvm-upgrade < %p/testlink1.ll | llvm-as > %t2.bc
 ; RUN: llvm-link %t.bc %t.bc %t2.bc -o %t1.bc -f
-; RUN: llvm-dis < %t1.bc | grep "kallsyms_names = extern_weak" &&
-; RUN: llvm-dis < %t1.bc | grep "MyVar = external global i32" &&
-; RUN: llvm-dis < %t1.bc | grep "Inte = global i32"
+; RUN: llvm-dis < %t1.bc | grep {kallsyms_names = extern_weak}
+; RUN: llvm-dis < %t1.bc | grep {MyVar = external global i32}
+; RUN: llvm-dis < %t1.bc | grep {Inte = global i32}
 
 %kallsyms_names = extern_weak global [0 x ubyte]
 %MyVar     = extern_weak global int