Skip to content

Commit 1ae9dd3

Browse files
authored
[X86] combineConcatVectorOps - add EXTEND_VECTOR_INREG() 512-bit handling (#127530)
Support extension to 512-bit vectors on AVX512/BWI targets.
1 parent d49c318 commit 1ae9dd3

File tree

2 files changed

+890
-992
lines changed

2 files changed

+890
-992
lines changed

llvm/lib/Target/X86/X86ISelLowering.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57883,8 +57883,10 @@ static SDValue combineConcatVectorOps(const SDLoc &DL, MVT VT,
5788357883
case ISD::SIGN_EXTEND_VECTOR_INREG:
5788457884
case ISD::ZERO_EXTEND_VECTOR_INREG: {
5788557885
// TODO: Handle ANY_EXTEND combos with SIGN/ZERO_EXTEND.
57886-
if (!IsSplat && NumOps == 2 && VT.is256BitVector() &&
57887-
Subtarget.hasInt256() &&
57886+
if (!IsSplat && NumOps == 2 &&
57887+
((VT.is256BitVector() && Subtarget.hasInt256()) ||
57888+
(VT.is512BitVector() && Subtarget.useAVX512Regs() &&
57889+
(EltSizeInBits >= 32 || Subtarget.useBWIRegs()))) &&
5788857890
Op0.getOperand(0).getValueType().is128BitVector() &&
5788957891
Op0.getOperand(0).getValueType() ==
5789057892
Ops[0].getOperand(0).getValueType()) {

0 commit comments

Comments
 (0)