Rafael Espindola | 152932b | 2009-03-17 23:43:59 +0000 | [diff] [blame] | 1 | ; RUN: llvm-as < %s | llc -march=x86 > %t |
2 | ; RUN: grep {movb.7(%...)} %t | ||||
3 | ; RUN: not grep leal %t | ||||
Chris Lattner | 2efbbb3 | 2008-11-26 00:26:16 +0000 | [diff] [blame] | 4 | |
5 | define i8 @test(i32 *%P) nounwind { | ||||
6 | %Q = getelementptr i32* %P, i32 1 | ||||
7 | %R = bitcast i32* %Q to i8* | ||||
8 | %S = load i8* %R | ||||
9 | %T = icmp eq i8 %S, 0 | ||||
10 | br i1 %T, label %TB, label %F | ||||
11 | TB: | ||||
12 | ret i8 4 | ||||
13 | F: | ||||
14 | %U = getelementptr i8* %R, i32 3 | ||||
15 | %V = load i8* %U | ||||
16 | ret i8 %V | ||||
17 | } |