diff options
author | Chris Lattner <sabre@nondot.org> | 2008-03-11 19:50:13 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2008-03-11 19:50:13 +0000 |
commit | e12ecf272d90c366e15531c15b6681ab5399ba33 (patch) | |
tree | 41d938da8b2d0eb3f624bf5463e1cc456c97e258 /test/CodeGen | |
parent | 1d38677e34f67961bbff40a5fed96f96ebfea836 (diff) | |
download | external_llvm-e12ecf272d90c366e15531c15b6681ab5399ba33.zip external_llvm-e12ecf272d90c366e15531c15b6681ab5399ba33.tar.gz external_llvm-e12ecf272d90c366e15531c15b6681ab5399ba33.tar.bz2 |
Implement basic support for the 'f' register class constraint. This basically
works, but probably won't if you mix it with 't' or 'u' yet.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48243 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen')
-rw-r--r-- | test/CodeGen/X86/inline-asm-fpstack.ll | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/test/CodeGen/X86/inline-asm-fpstack.ll b/test/CodeGen/X86/inline-asm-fpstack.ll index 1e308d9..91f2f2f 100644 --- a/test/CodeGen/X86/inline-asm-fpstack.ll +++ b/test/CodeGen/X86/inline-asm-fpstack.ll @@ -26,4 +26,18 @@ define void @test5(double %X) { ret void } +define void @test6(double %A, double %B, double %C, + double %D, double %E) nounwind { +entry: + ; Uses the same value twice, should have one fstp after the asm. + tail call void asm sideeffect "foo $0 $1", "f,f,~{dirflag},~{fpsr},~{flags}"( double %A, double %A ) nounwind + ; Uses two different values, should be in st(0)/st(1) and both be popped. + tail call void asm sideeffect "bar $0 $1", "f,f,~{dirflag},~{fpsr},~{flags}"( double %B, double %C ) nounwind + ; Uses two different values, one of which isn't killed in this asm, it + ; should not be popped after the asm. + tail call void asm sideeffect "baz $0 $1", "f,f,~{dirflag},~{fpsr},~{flags}"( double %D, double %E ) nounwind + ; This is the last use of %D, so it should be popped after. + tail call void asm sideeffect "baz $0", "f,~{dirflag},~{fpsr},~{flags}"( double %D ) nounwind + ret void +} |