diff options
| author | Benjamin Kramer <benny.kra@googlemail.com> | 2018-04-26 15:26:29 +0000 |
|---|---|---|
| committer | Benjamin Kramer <benny.kra@googlemail.com> | 2018-04-26 15:26:29 +0000 |
| commit | 7dd437710e821ef76717611f6f23f849d2cf9ca8 (patch) | |
| tree | ce05f8ab9bfd43c7cc6fe93f0cf38a4e0a4019b0 /llvm/lib/Target | |
| parent | a5da08638699d1755a634f19099c133305efa342 (diff) | |
| download | bcm5719-llvm-7dd437710e821ef76717611f6f23f849d2cf9ca8.tar.gz bcm5719-llvm-7dd437710e821ef76717611f6f23f849d2cf9ca8.zip | |
[NVPTX] Make the legalizer expand shufflevector of <2 x half>
There's no direct instruction for this, but it's trivially implemented
with two movs. Without this the code generator just dies when
encountering a shufflevector.
Differential Revision: https://reviews.llvm.org/D46116
llvm-svn: 330948
Diffstat (limited to 'llvm/lib/Target')
| -rw-r--r-- | llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp b/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp index 5405e9dd001..527f0997e64 100644 --- a/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp +++ b/llvm/lib/Target/NVPTX/NVPTXISelLowering.cpp @@ -375,6 +375,7 @@ NVPTXTargetLowering::NVPTXTargetLowering(const NVPTXTargetMachine &TM, setOperationAction(ISD::FP_TO_SINT, MVT::f16, Legal); setOperationAction(ISD::BUILD_VECTOR, MVT::v2f16, Custom); setOperationAction(ISD::EXTRACT_VECTOR_ELT, MVT::v2f16, Custom); + setOperationAction(ISD::VECTOR_SHUFFLE, MVT::v2f16, Expand); setFP16OperationAction(ISD::SETCC, MVT::f16, Legal, Promote); setFP16OperationAction(ISD::SETCC, MVT::v2f16, Legal, Expand); |

