aboutsummaryrefslogtreecommitdiff
path: root/lib/Target/Sparc/SparcISelDAGToDAG.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2008-02-28 05:48:04 +0000
committerChris Lattner <sabre@nondot.org>2008-02-28 05:48:04 +0000
commita4b521598aff90b925ea397ddd36d479c99dd9f7 (patch)
tree6cb8d3f0ea86ce1cc3e035ef5f55b156f2c7b394 /lib/Target/Sparc/SparcISelDAGToDAG.cpp
parent61273d55e9ce068fef5dfcddb65e5ad9c1f4772e (diff)
Fix CodeGen/Generic/storetrunc-fp.ll on sparc, PR2105
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47707 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/Sparc/SparcISelDAGToDAG.cpp')
-rw-r--r--lib/Target/Sparc/SparcISelDAGToDAG.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Target/Sparc/SparcISelDAGToDAG.cpp b/lib/Target/Sparc/SparcISelDAGToDAG.cpp
index 40fa95c294..6e59631a81 100644
--- a/lib/Target/Sparc/SparcISelDAGToDAG.cpp
+++ b/lib/Target/Sparc/SparcISelDAGToDAG.cpp
@@ -140,9 +140,10 @@ SparcTargetLowering::SparcTargetLowering(TargetMachine &TM)
// Turn FP extload into load/fextend
setLoadXAction(ISD::EXTLOAD, MVT::f32, Expand);
-
// Sparc doesn't have i1 sign extending load
setLoadXAction(ISD::SEXTLOAD, MVT::i1, Promote);
+ // Turn FP truncstore into trunc + store.
+ setTruncStoreAction(MVT::f64, MVT::f32, Expand);
// Custom legalize GlobalAddress nodes into LO/HI parts.
setOperationAction(ISD::GlobalAddress, MVT::i32, Custom);