Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 1 | ; RUN: llvm-as < %s | llvm-dis > %t1.ll |
Tanya Lattner | 3f7706b | 2004-11-07 06:08:43 +0000 | [diff] [blame] | 2 | ; RUN: llvm-as %t1.ll -o - | llvm-dis > %t2.ll |
3 | ; RUN: diff %t1.ll %t2.ll | ||||
4 | |||||
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 5 | %myty = type i32 |
6 | %myfn = type float (i32,double,i32,i16) | ||||
Chris Lattner | a53616d | 2011-06-19 00:03:46 +0000 | [diff] [blame] | 7 | %0 = type i32(%myfn*) |
8 | %1 = type i32(i32) | ||||
9 | %2 = type i32(i32(i32)*) | ||||
Chris Lattner | 8fba3a0 | 2002-05-02 21:52:35 +0000 | [diff] [blame] | 10 | |
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 11 | %thisfuncty = type i32 (i32) * |
Chris Lattner | 0095054 | 2001-06-06 20:29:01 +0000 | [diff] [blame] | 12 | |
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 13 | declare void @F(%thisfuncty, %thisfuncty, %thisfuncty) |
Chris Lattner | 7209bff | 2002-10-06 22:43:49 +0000 | [diff] [blame] | 14 | |
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 15 | define i32 @zarro(i32 %Func) { |
Chris Lattner | 0095054 | 2001-06-06 20:29:01 +0000 | [diff] [blame] | 16 | Startup: |
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 17 | add i32 0, 10 ; <i32>:0 [#uses=0] |
18 | ret i32 0 | ||||
19 | } | ||||
Chris Lattner | 0095054 | 2001-06-06 20:29:01 +0000 | [diff] [blame] | 20 | |
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 21 | define i32 @test(i32) { |
22 | call void @F( %thisfuncty @zarro, %thisfuncty @test, %thisfuncty @foozball ) | ||||
23 | ret i32 0 | ||||
24 | } | ||||
Chris Lattner | 0095054 | 2001-06-06 20:29:01 +0000 | [diff] [blame] | 25 | |
Tanya Lattner | 9bc243b | 2008-03-01 07:38:40 +0000 | [diff] [blame] | 26 | define i32 @foozball(i32) { |
27 | ret i32 0 | ||||
28 | } | ||||
Chris Lattner | 0095054 | 2001-06-06 20:29:01 +0000 | [diff] [blame] | 29 |