diff options
author | Craig Topper <craig.topper@gmail.com> | 2016-04-28 03:34:31 +0000 |
---|---|---|
committer | Craig Topper <craig.topper@gmail.com> | 2016-04-28 03:34:31 +0000 |
commit | 33772c53754bd27af1ce41379def536fc1de7fb0 (patch) | |
tree | 90695f7cd1b8952186dd169e15cea30e312247a8 /llvm/lib/Target/Hexagon | |
parent | 7626f778a567767690b279420037b7f11f2e4748 (diff) | |
download | bcm5719-llvm-33772c53754bd27af1ce41379def536fc1de7fb0.tar.gz bcm5719-llvm-33772c53754bd27af1ce41379def536fc1de7fb0.zip |
[CodeGen] Default CTTZ_ZERO_UNDEF/CTLZ_ZERO_UNDEF to Expand in TargetLoweringBase. This is what the majority of the targets want and removes a bunch of code. Set it to Legal explicitly in the few cases where that's the desired behavior.
llvm-svn: 267853
Diffstat (limited to 'llvm/lib/Target/Hexagon')
-rw-r--r-- | llvm/lib/Target/Hexagon/HexagonISelLowering.cpp | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp b/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp index fa1e275bf6f..f49a984463b 100644 --- a/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp +++ b/llvm/lib/Target/Hexagon/HexagonISelLowering.cpp @@ -1868,14 +1868,6 @@ HexagonTargetLowering::HexagonTargetLowering(const TargetMachine &TM, setOperationAction(ISD::CTLZ, MVT::i16, Promote); setOperationAction(ISD::CTTZ, MVT::i8, Promote); setOperationAction(ISD::CTTZ, MVT::i16, Promote); - setOperationAction(ISD::CTLZ_ZERO_UNDEF, MVT::i8, Expand); - setOperationAction(ISD::CTLZ_ZERO_UNDEF, MVT::i16, Expand); - setOperationAction(ISD::CTLZ_ZERO_UNDEF, MVT::i32, Expand); - setOperationAction(ISD::CTLZ_ZERO_UNDEF, MVT::i64, Expand); - setOperationAction(ISD::CTTZ_ZERO_UNDEF, MVT::i8, Expand); - setOperationAction(ISD::CTTZ_ZERO_UNDEF, MVT::i16, Expand); - setOperationAction(ISD::CTTZ_ZERO_UNDEF, MVT::i32, Expand); - setOperationAction(ISD::CTTZ_ZERO_UNDEF, MVT::i64, Expand); // In V5, popcount can count # of 1s in i64 but returns i32. // On V4 it will be expanded (set later). @@ -1955,8 +1947,7 @@ HexagonTargetLowering::HexagonTargetLowering(const TargetMachine &TM, ISD::SMUL_LOHI, ISD::UMUL_LOHI, // Logical/bit: ISD::AND, ISD::OR, ISD::XOR, ISD::ROTL, ISD::ROTR, - ISD::CTPOP, ISD::CTLZ, ISD::CTTZ, ISD::CTLZ_ZERO_UNDEF, - ISD::CTTZ_ZERO_UNDEF, + ISD::CTPOP, ISD::CTLZ, ISD::CTTZ, // Floating point arithmetic/math functions: ISD::FADD, ISD::FSUB, ISD::FMUL, ISD::FMA, ISD::FDIV, ISD::FREM, ISD::FNEG, ISD::FABS, ISD::FSQRT, ISD::FSIN, |