[llvm] r318870 - [X86] Move the BITALG setOperationAction code into the hasBWI section to match what is done for VPOPCNTDQ in the AVX512F block. NFC
Craig Topper via llvm-commits
llvm-commits at lists.llvm.org
Wed Nov 22 12:05:54 PST 2017
Author: ctopper
Date: Wed Nov 22 12:05:54 2017
New Revision: 318870
URL: http://llvm.org/viewvc/llvm-project?rev=318870&view=rev
Log:
[X86] Move the BITALG setOperationAction code into the hasBWI section to match what is done for VPOPCNTDQ in the AVX512F block. NFC
Modified:
llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
Modified: llvm/trunk/lib/Target/X86/X86ISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86ISelLowering.cpp?rev=318870&r1=318869&r2=318870&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86ISelLowering.cpp (original)
+++ llvm/trunk/lib/Target/X86/X86ISelLowering.cpp Wed Nov 22 12:05:54 2017
@@ -1522,6 +1522,12 @@ X86TargetLowering::X86TargetLowering(con
for (auto ExtType : {ISD::ZEXTLOAD, ISD::SEXTLOAD}) {
setLoadExtAction(ExtType, MVT::v32i16, MVT::v32i8, Legal);
}
+
+ if (Subtarget.hasBITALG()) {
+ for (auto VT : { MVT::v64i8, MVT::v32i16, MVT::v32i8,
+ MVT::v16i16, MVT::v16i8, MVT::v8i16 })
+ setOperationAction(ISD::CTPOP, VT, Legal);
+ }
}
if (!Subtarget.useSoftFloat() && Subtarget.hasVLX()) {
@@ -1556,11 +1562,6 @@ X86TargetLowering::X86TargetLowering(con
}
}
- if (Subtarget.hasBITALG())
- for (auto VT : { MVT::v64i8, MVT::v32i16, MVT::v32i8,
- MVT::v16i16, MVT::v16i8, MVT::v8i16 })
- setOperationAction(ISD::CTPOP, VT, Legal);
-
// We want to custom lower some of our intrinsics.
setOperationAction(ISD::INTRINSIC_WO_CHAIN, MVT::Other, Custom);
setOperationAction(ISD::INTRINSIC_W_CHAIN, MVT::Other, Custom);
More information about the llvm-commits
mailing list