diff options
author | Akira Hatanaka <ahatanaka@mips.com> | 2013-08-02 19:23:33 +0000 |
---|---|---|
committer | Akira Hatanaka <ahatanaka@mips.com> | 2013-08-02 19:23:33 +0000 |
commit | 7be35cb1bf520052b051800cee7376a2b9540081 (patch) | |
tree | 2493214a214805b3edfaa56df9c1bd71ec28e24c /llvm/lib | |
parent | 5d0564d2e6206129464043e45301c6ef4e42359c (diff) | |
download | bcm5719-llvm-7be35cb1bf520052b051800cee7376a2b9540081.tar.gz bcm5719-llvm-7be35cb1bf520052b051800cee7376a2b9540081.zip |
[mips] Expand vector truncating stores and extending loads.
llvm-svn: 187667
Diffstat (limited to 'llvm/lib')
-rw-r--r-- | llvm/lib/Target/Mips/MipsSEISelLowering.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/llvm/lib/Target/Mips/MipsSEISelLowering.cpp b/llvm/lib/Target/Mips/MipsSEISelLowering.cpp index 8b5a8746eb2..58c8e7ca9ed 100644 --- a/llvm/lib/Target/Mips/MipsSEISelLowering.cpp +++ b/llvm/lib/Target/Mips/MipsSEISelLowering.cpp @@ -53,6 +53,20 @@ MipsSETargetLowering::MipsSETargetLowering(MipsTargetMachine &TM) setOperationAction(ISD::BITCAST, VecTys[i], Legal); } + // Expand all truncating stores and extending loads. + unsigned FirstVT = (unsigned)MVT::FIRST_VECTOR_VALUETYPE; + unsigned LastVT = (unsigned)MVT::LAST_VECTOR_VALUETYPE; + + for (unsigned VT0 = FirstVT; VT0 <= LastVT; ++VT0) { + for (unsigned VT1 = FirstVT; VT1 <= LastVT; ++VT1) + setTruncStoreAction((MVT::SimpleValueType)VT0, + (MVT::SimpleValueType)VT1, Expand); + + setLoadExtAction(ISD::SEXTLOAD, (MVT::SimpleValueType)VT0, Expand); + setLoadExtAction(ISD::ZEXTLOAD, (MVT::SimpleValueType)VT0, Expand); + setLoadExtAction(ISD::EXTLOAD, (MVT::SimpleValueType)VT0, Expand); + } + setTargetDAGCombine(ISD::SHL); setTargetDAGCombine(ISD::SRA); setTargetDAGCombine(ISD::SRL); |