blob: d41b2454863bd6049edd96fba2c07cd38f95fb19 [file] [log] [blame]
Rafael Espindola152932b2009-03-17 23:43:59 +00001; RUN: llvm-as < %s | llc -march=x86-64 > %t
2; RUN: grep {movswl %ax, %edi} %t
3; RUN: grep {movw x(%rip), %ax} %t
4
5@x = common global i16 0
6
7define signext i16 @f() nounwind {
8entry:
9 %0 = tail call signext i16 @h() nounwind
10 %1 = sext i16 %0 to i32
11 tail call void @g(i32 %1) nounwind
12 %2 = load i16* @x, align 2
13 ret i16 %2
14}
15
16declare signext i16 @h()
17
18declare void @g(i32)