Let the inline asm 'q' constraint match float, and on 64-bit double too.
[oota-llvm.git] / test / CodeGen / X86 / inline-asm-q-regs.ll
1 ; RUN: llc < %s -march=x86-64
2 ; rdar://7066579
3
4         %0 = type { i64, i64, i64, i64, i64 }           ; type %0
5
6 define void @test1() nounwind {
7 entry:
8         %asmtmp = call %0 asm sideeffect "mov    %cr0, $0       \0Amov    %cr2, $1       \0Amov    %cr3, $2       \0Amov    %cr4, $3       \0Amov    %cr8, $0       \0A", "=q,=q,=q,=q,=q,~{dirflag},~{fpsr},~{flags}"() nounwind               ; <%0> [#uses=0]
9         ret void
10 }
11
12 ; PR9602
13 define void @test2(float %tmp) nounwind {
14   call void asm sideeffect "$0", "q"(float %tmp) nounwind
15   call void asm sideeffect "$0", "Q"(float %tmp) nounwind
16   ret void
17 }
18
19 define void @test3(double %tmp) nounwind {
20   call void asm sideeffect "$0", "q"(double %tmp) nounwind
21   ret void
22 }