diff options
| author | Akira Hatanaka <ahatanaka@mips.com> | 2012-08-28 02:12:42 +0000 |
|---|---|---|
| committer | Akira Hatanaka <ahatanaka@mips.com> | 2012-08-28 02:12:42 +0000 |
| commit | 1d522388bfa642d710618edd3f4e9fe6471cf674 (patch) | |
| tree | 1ea6da6d021bb1ccf9724f6f09e7d1a4cf7e2784 /test/CodeGen | |
| parent | f3c3828e57d922bbe912ffabbd9252b9f5100c14 (diff) | |
| download | llvm-1d522388bfa642d710618edd3f4e9fe6471cf674.tar.gz llvm-1d522388bfa642d710618edd3f4e9fe6471cf674.tar.bz2 llvm-1d522388bfa642d710618edd3f4e9fe6471cf674.tar.xz | |
Fix bug 13532.
In SelectionDAGLegalize::ExpandLegalINT_TO_FP, expand INT_TO_FP nodes without
using any f64 operations if f64 is not a legal type.
Patch by Stefan Kristiansson.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162728 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/CodeGen')
| -rw-r--r-- | test/CodeGen/Mips/uitofp.ll | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/CodeGen/Mips/uitofp.ll b/test/CodeGen/Mips/uitofp.ll new file mode 100644 index 0000000000..aff70c24f0 --- /dev/null +++ b/test/CodeGen/Mips/uitofp.ll @@ -0,0 +1,12 @@ +; RUN: llc -march=mips -mattr=+single-float < %s + +define void @f0() nounwind { +entry: + %b = alloca i32, align 4 + %a = alloca float, align 4 + store volatile i32 1, i32* %b, align 4 + %0 = load volatile i32* %b, align 4 + %conv = uitofp i32 %0 to float + store float %conv, float* %a, align 4 + ret void +} |
