[flang-commits] [clang] [compiler-rt] [llvm] [lld] [libc] [flang] [libcxx] Fix ISel crash when lowering BUILD_VECTOR (PR #73186)

Simon Pilgrim via flang-commits flang-commits at lists.llvm.org
Thu Nov 23 04:53:57 PST 2023


================
@@ -7254,6 +7255,10 @@ static SDValue lowerBuildVectorAsBroadcast(BuildVectorSDNode *BVOp,
     EVT CVT = Ld.getValueType();
     assert(!CVT.isVector() && "Must not broadcast a vector type");
 
+    // 512 bit vpbroadcastw is only available with AVX512BW
+    if (ScalarSize == 16 && IsGT256 && !Subtarget.hasBWI())
+      return SDValue();
----------------
RKSimon wrote:

Isn't X86DAGToDAGISel::PreprocessISelDAG() is supposed to handle this?

https://github.com/llvm/llvm-project/pull/73186


More information about the flang-commits mailing list