llvm.org GIT mirror llvm / a3f8982
Rename %S metavar to %M (clang uses %S for the basename of the test file). git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@81087 91177308-0d34-0410-b5e6-96231b3b80d8 Daniel Dunbar 10 years ago
7 changed file(s) with 23 addition(s) and 23 deletion(s). Raw diff Collapse all Expand all
0 ; This one fails because the LLVM runtime is allowing two null pointers of
11 ; the same type to be created!
22
3 ; RUN: echo {%S = type \{ %T*\} %T = type opaque} | llvm-as > %t.2.bc
3 ; RUN: echo {%M = type \{ %N*\} %N = type opaque} | llvm-as > %t.2.bc
44 ; RUN: llvm-as < %s > %t.1.bc
55 ; RUN: llvm-link %t.1.bc %t.2.bc
66
7 %S = type { i32* }
8 %T = type i32
7 %M = type { i32* }
8 %N = type i32
99
0 ; RUN: llvm-as < %s > %t.out1.bc
1 ; RUN: echo {%S = type \{ i32, i32* \} } | llvm-as > %t.out2.bc
1 ; RUN: echo {%M = type \{ i32, i32* \} } | llvm-as > %t.out2.bc
22 ; RUN: llvm-link %t.out1.bc %t.out2.bc
33
4 %S = type { i32, %T* }
5 %T = type opaque
4 %M = type { i32, %N* }
5 %N = type opaque
66
7 ;%X = global { int, %T* } { int 5, %T* null }
7 ;%X = global { int, %N* } { int 5, %N* null }
11 ; net.
22
33 ; RUN: llvm-as < %s > %t.out1.bc
4 ; RUN: echo "%S = type { %S*, i32* }" | llvm-as > %t.out2.bc
4 ; RUN: echo "%M = type { %M*, i32* }" | llvm-as > %t.out2.bc
55 ; RUN: llvm-link %t.out1.bc %t.out2.bc
66
7 %S = type { %S*, opaque* }
7 %M = type { %M*, opaque* }
88
0 ; RUN: llvm-as < %s > %t.out1.bc
1 ; RUN: echo "%S = type i32" | llvm-as > %t.out2.bc
1 ; RUN: echo "%M = type i32" | llvm-as > %t.out2.bc
22 ; RUN: llvm-link %t.out2.bc %t.out1.bc
33
4 %S = type opaque
4 %M = type opaque
55
66 define void @foo(i32* %V) {
77 ret void
88 }
99
10 declare void @foo.upgrd.1(%S*)
10 declare void @foo.upgrd.1(%M*)
1111
0 ; RUN: llvm-as < %s > %t.out1.bc
1 ; RUN: echo "%S = type i32" | llvm-as > %t.out2.bc
1 ; RUN: echo "%M = type i32" | llvm-as > %t.out2.bc
22 ; RUN: llvm-link %t.out2.bc %t.out1.bc
33
4 %S = type opaque
4 %M = type opaque
55
66 define void @foo(i32* %V) {
77 ret void
88 }
99
10 declare void @foo.upgrd.1(%S*)
10 declare void @foo.upgrd.1(%M*)
1111
1212 define void @other() {
13 call void @foo.upgrd.1( %S* null )
13 call void @foo.upgrd.1( %M* null )
1414 call void @foo( i32* null )
1515 ret void
1616 }
0 ; RUN: llvm-as < %s > %t.out1.bc
1 ; RUN: echo "%S = type i32" | llvm-as > %t.out2.bc
1 ; RUN: echo "%M = type i32" | llvm-as > %t.out2.bc
22 ; RUN: llvm-link %t.out2.bc %t.out1.bc
33
4 %S = type opaque
4 %M = type opaque
55
66 ; GLobal using the resolved function prototype
7 global void (%S*)* @foo ; *)**>:0 [#uses=0]
7 global void (%M*)* @foo ; *)**>:0 [#uses=0]
88
99 define void @foo.upgrd.1(i32* %V) {
1010 ret void
1111 }
1212
13 declare void @foo(%S*)
13 declare void @foo(%M*)
1414
0 ; RUN: llvm-as < %s > %t.out1.bc
1 ; RUN: echo { %S = type \[8 x i32\] external global %S } | llvm-as > %t.out2.bc
2 ; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | grep %S | grep \\{
3 %S = type { i32 }
1 ; RUN: echo { %M = type \[8 x i32\] external global %M } | llvm-as > %t.out2.bc
2 ; RUN: llvm-link %t.out1.bc %t.out2.bc | llvm-dis | grep %M | grep \\{
3 %M = type { i32 }
44
55