[llvm] 304cfc7 - [X86] combineConcatVectorOps - remove superfluous Subtarget.hasAVX() check

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 20 04:59:58 PST 2022


Author: Simon Pilgrim
Date: 2022-01-20T12:56:09Z
New Revision: 304cfc706ad48a0338990c4d19c9117920ca8adf

URL: https://github.com/llvm/llvm-project/commit/304cfc706ad48a0338990c4d19c9117920ca8adf
DIFF: https://github.com/llvm/llvm-project/commit/304cfc706ad48a0338990c4d19c9117920ca8adf.diff

LOG: [X86] combineConcatVectorOps - remove superfluous Subtarget.hasAVX() check

This function only ever gets called by AVX targets, and we already assert for this at the top of the function

Added: 
    

Modified: 
    llvm/lib/Target/X86/X86ISelLowering.cpp

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Target/X86/X86ISelLowering.cpp b/llvm/lib/Target/X86/X86ISelLowering.cpp
index f3fa2b512612..0d12cf519a8b 100644
--- a/llvm/lib/Target/X86/X86ISelLowering.cpp
+++ b/llvm/lib/Target/X86/X86ISelLowering.cpp
@@ -52552,7 +52552,7 @@ static SDValue combineConcatVectorOps(const SDLoc &DL, MVT VT,
       LLVM_FALLTHROUGH;
     case X86ISD::VPERMILPI:
       if (!IsSplat && NumOps == 2 && (VT == MVT::v8f32 || VT == MVT::v8i32) &&
-          Subtarget.hasAVX() && Op0.getOperand(1) == Ops[1].getOperand(1)) {
+          Op0.getOperand(1) == Ops[1].getOperand(1)) {
         SDValue Res = DAG.getBitcast(MVT::v8f32, ConcatSubOperand(VT, Ops, 0));
         Res = DAG.getNode(X86ISD::VPERMILPI, DL, MVT::v8f32, Res,
                           Op0.getOperand(1));


        


More information about the llvm-commits mailing list