Use llvm-link -S instead of using llvm-dis.
authorDan Gohman <gohman@apple.com>
Tue, 15 Sep 2009 15:38:31 +0000 (15:38 +0000)
committerDan Gohman <gohman@apple.com>
Tue, 15 Sep 2009 15:38:31 +0000 (15:38 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81860 91177308-0d34-0410-b5e6-96231b3b80d8

21 files changed:
test/Linker/2003-01-30-LinkerRename.ll
test/Linker/2003-01-30-LinkerTypeRename.ll
test/Linker/2003-04-23-LinkOnceLost.ll
test/Linker/2003-05-31-LinkerRename.ll
test/Linker/2003-08-23-GlobalVarLinking.ll
test/Linker/2003-10-21-ConflictingTypesTolerance.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-06-15-GlobalVarAlignment.ll
test/Linker/2008-06-13-LinkOnceRedefinition.ll
test/Linker/2008-06-26-AddressSpace.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/link-global-to-func.ll
test/Linker/linknamedmdnode.ll

index 6c8b49697b33abd284307d647e4b5c02f88cf640..af0e6434fb1cf3cb59198dbae254d4b4fe2dd62d 100644 (file)
@@ -3,7 +3,7 @@
 
 ; RUN: echo {define internal i32 @foo() \{ ret i32 7 \} } | llvm-as > %t.1.bc
 ; RUN: llvm-as %s -o %t.2.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep @foo() | grep -v internal
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep @foo() | grep -v internal
 
 define i32 @foo() { ret i32 0 }
 
index 288daf1cba1c3b15adf68a17d62c6e9ba4bc7965..67a0626ec037bef251003935f4529d09fb80ed8f 100644 (file)
@@ -3,7 +3,7 @@
 
 ; 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.1.bc %t.2.bc | llvm-dis | grep {%Ty } | not grep opaque
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep {%Ty } | not grep opaque
 
 %Ty = type i32
 
index 7f15e51e22079e61bdfcf739b873ff96b534cfc3..beaf6ec52176ed9d516002c80812b5c79dd13f09 100644 (file)
@@ -4,7 +4,7 @@
 ; RUN: echo { define linkonce void @foo() \{ ret void \} } | \
 ; RUN:   llvm-as -o %t.2.bc
 ; RUN: llvm-as %s -o %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep foo | grep linkonce
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep foo | grep linkonce
 
 declare void @foo()
 
index c3661ae9aa3b222d934c2ba2fd6c1275163c00cc..498fc14b35380d83cce40335c81076848dab8e14 100644 (file)
@@ -6,7 +6,7 @@
 
 ; 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.1.bc %t.2.bc | llvm-dis | grep internal | not grep @foo(
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep internal | not grep @foo(
 
 declare i32 @foo() 
 
index fd36d0422a69cc00a0e92a38adbb081b931c5b28..c3f61f893456cb76f2544d654151eacf6b6b77ff 100644 (file)
@@ -1,7 +1,7 @@
 ; RUN: llvm-as < %s > %t.out1.bc
 ; RUN: echo {@S = external global \{ i32, opaque* \} declare void @F(opaque*)}\
 ; RUN:   | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | not grep opaque
+; RUN: llvm-link %t.out1.bc %t.out2.bc -S | 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 c1f3fc45f757ce1ec65d75dea293d819509abee1..7cdf7ad0dada3766e848f4e218b9701c4f74311b 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-as < %s > %t.out1.bc
 ; RUN: echo { %M = type \[8 x i32\] external global %M } | llvm-as > %t.out2.bc
-; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | grep %M | grep \\{
+; RUN: llvm-link %t.out1.bc %t.out2.bc -S | grep %M | grep \\{
 %M = type { i32 }
 
 
index 7378fdd357951b5747d0f4c01c2dc9d7530bf8c2..570bda87e2c0c31ea3b65363148b1cd2035da6d3 100644 (file)
@@ -1,7 +1,7 @@
 ; RUN: echo {@G = weak global \{\{\{\{double\}\}\}\} zeroinitializer } | \
 ; RUN:   llvm-as > %t.out2.bc
 ; RUN: llvm-as < %s > %t.out1.bc
-; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | not grep {\\}}
+; RUN: llvm-link %t.out1.bc %t.out2.bc -S | not grep {\\}}
 
 ; When linked, the global above should be eliminated, being merged with the 
 ; global below.
index bedeb51069504d19f6f37b87a6c1c5e8c945d378..2ceae3146f273c982a663d0ab7e1944dc9e0c09c 100644 (file)
@@ -3,6 +3,6 @@
 
 ; 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}
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep {global i32 7}
 
 @X = global i32 7
index 407737287369cb4850497b058b6c1fe835bbd21f..60f176b053415567e00c0881f2d7cd1dc99ae9dc 100644 (file)
@@ -3,6 +3,6 @@
 
 ; RUN: echo {@X = global i32 7} | 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}
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep {global i32 7}
 
 @X = external constant i32             ; <i32*> [#uses=0]
index 2637da17f3f957ceb206f6838965bb4de74d5852..7d1020ddf28ef62d04ad5388650a727876c83f92 100644 (file)
@@ -1,7 +1,7 @@
 ; RUN: echo { @G = appending global \[0 x i32\] zeroinitializer } | \
 ; RUN:   llvm-as > %t.out2.bc
 ; RUN: llvm-as < %s > %t.out1.bc
-; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | grep {@G =}
+; RUN: llvm-link %t.out1.bc %t.out2.bc -S | grep {@G =}
 
 ; When linked, the globals should be merged, and the result should still 
 ; be named '@G'.
index 6e6d56a039ec8b13ebcd76c60ea4aaa4924ccbc8..df3284bedea82576525ce5c7118ad163cbfbb64c 100644 (file)
@@ -2,6 +2,6 @@
 
 ; 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}
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep {align 8}
 
 @X = weak global i32 7, align 4
index 8c23250e83a69a721113467126fd2401e446c642..49da96af949abf45e52c48568d8d4634ff44df3e 100644 (file)
@@ -3,6 +3,6 @@
 ; RUN: llvm-as %s -o %t.foo1.bc
 ; RUN: llvm-as %s -o %t.foo2.bc
 ; RUN: echo {define linkonce void @foo(i32 %x) { ret void }} | llvm-as -o %t.foo3.bc
-; RUN: llvm-link %t.foo1.bc %t.foo2.bc | llvm-dis
-; RUN: llvm-link %t.foo1.bc %t.foo3.bc | llvm-dis
+; RUN: llvm-link %t.foo1.bc %t.foo2.bc -S
+; RUN: llvm-link %t.foo1.bc %t.foo3.bc -S
 define linkonce void @foo() { ret void }
index 0847bb5839c9dcd3a4937d33196caed0476052c6..e3ed385b68a189bf25a8774b081a4983d22c62dd 100644 (file)
@@ -2,8 +2,8 @@
 ; in different modules.
 ; RUN: llvm-as %s -o %t.foo1.bc
 ; RUN: echo | llvm-as -o %t.foo2.bc
-; RUN: llvm-link %t.foo2.bc %t.foo1.bc | llvm-dis | grep {addrspace(2)}
-; RUN: llvm-link %t.foo1.bc %t.foo2.bc | llvm-dis | grep {addrspace(2)}
+; RUN: llvm-link %t.foo2.bc %t.foo1.bc -S | grep {addrspace(2)}
+; RUN: llvm-link %t.foo1.bc %t.foo2.bc -S | grep {addrspace(2)}
 ; rdar://6038021
 
 @G = addrspace(2) global i32 256 
index da08ca098893533441643b9851af228b24598990..134a42ef215b80fe25f704596ae722aee658c63b 100644 (file)
@@ -3,7 +3,7 @@
 ; RUN: echo {@X = appending global \[1 x i32\] \[i32 8\] } | \
 ; RUN:   llvm-as > %t.2.bc
 ; RUN: llvm-as < %s > %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep 7 | grep 4 | grep 8
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep 7 | grep 4 | grep 8
 
 @X = appending global [2 x i32] [ i32 7, i32 4 ]               ; <[2 x i32]*> [#uses=2]
 @Y = global i32* getelementptr ([2 x i32]* @X, i64 0, i64 0)           ; <i32**> [#uses=0]
index fddc4941be979c01efce0e8e352c83810a58d776..2c1302f39b1f7709af811f446e6be12e3a4cd706 100644 (file)
@@ -3,6 +3,6 @@
 ; RUN: echo {@X = appending global \[1 x i32\] \[i32 8\] } | \
 ; RUN:   llvm-as > %t.2.bc
 ; RUN: llvm-as < %s > %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep 7 | grep 8
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep 7 | grep 8
 
 @X = appending global [1 x i32] [ i32 7 ]              ; <[1 x i32]*> [#uses=0]
index 5d42f4bf5483244c2c03c6670f239ab6d4d138e1..8fdbe508db7f9e7b785f4f5341a164c5145001f2 100644 (file)
@@ -3,7 +3,7 @@
 ; RUN: echo {@X = constant \[1 x i32\] \[i32 8\] } | \
 ; RUN:   llvm-as > %t.2.bc
 ; RUN: llvm-as < %s > %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep constant
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep constant
 
 @X = external global [1 x i32]         ; <[1 x i32]*> [#uses=0]
 
index 9cd6bdb8c49acd6f6fce9bbe601b189f13386bd3..ad4428b95223eeca02472d8e74f48ddfe3efee50 100644 (file)
@@ -3,7 +3,7 @@
 ; RUN: echo {@X = external global \[1 x i32\] } | \
 ; RUN:   llvm-as > %t.2.bc
 ; RUN: llvm-as < %s > %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep constant
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep constant
 
 @X = constant [1 x i32] [ i32 12 ]             ; <[1 x i32]*> [#uses=0]
 
index f9aa07d1bc507284295dca8bc63a3e7817f1e1fd..e25529ae1bfcecc4c55c0881a261944a1b5b703a 100644 (file)
@@ -3,6 +3,6 @@
 ; RUN: echo {@X = external constant \[1 x i32\] } | \
 ; RUN:   llvm-as > %t.2.bc
 ; RUN: llvm-as < %s > %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis | grep constant
+; RUN: llvm-link %t.1.bc %t.2.bc -S | grep constant
 
 @X = external global [1 x i32]         ; <[1 x i32]*> [#uses=0]
index 5befd77a4aaa4bfdddab82820a2c3bc03e51adda..56633fb8da7b2e92ef44794365db521364e1d30f 100644 (file)
@@ -3,6 +3,6 @@
 
 ; RUN: echo "@X = linkonce global i32 8" | llvm-as > %t.2.bc
 ; RUN: llvm-as < %s > %t.1.bc
-; RUN: llvm-link %t.1.bc %t.2.bc | llvm-dis
+; RUN: llvm-link %t.1.bc %t.2.bc -S
 
 @X = linkonce global i32 7             ; <i32*> [#uses=0]
index a805035eae8955622ce98b2a58cd4fa5cfc572aa..2fc501dedc90b105321b756207824e5c70f96ce8 100644 (file)
@@ -1,7 +1,7 @@
 ; RUN: llvm-as %s -o %t1.bc
 ; RUN: echo {declare void @__eprintf(i8*, i8*, i32, i8*) noreturn     define void @foo() {      tail call void @__eprintf( i8* undef, i8* undef, i32 4, i8* null ) noreturn nounwind       unreachable }} | llvm-as -o %t2.bc
-; RUN: llvm-link %t2.bc %t1.bc -o - | llvm-dis | grep __eprintf
-; RUN: llvm-link %t1.bc %t2.bc -o - | llvm-dis | grep __eprintf
+; RUN: llvm-link %t2.bc %t1.bc -S | grep __eprintf
+; RUN: llvm-link %t1.bc %t2.bc -S | grep __eprintf
 
 ; rdar://6072702
 
index 455b3b807f83b8df03f7e0ceed260af385de59c0..e6b779f1fc5d69c4dce489921dd894360295e7e1 100644 (file)
@@ -1,6 +1,6 @@
 ; RUN: llvm-as < %s > %t.bc
 ; RUN: llvm-as < %p/linknamedmdnode2.ll > %t2.bc
-; RUN: llvm-link %t.bc %t2.bc | llvm-dis | grep "!llvm.stuff = !{!0, !1}"
+; RUN: llvm-link %t.bc %t2.bc -S | grep "!llvm.stuff = !{!0, !1}"
 
 !0 = metadata !{i32 42}
 !llvm.stuff = !{!0}