[llvm-branch-commits] [llvm] [X86] Fix bf16 VBROADCAST lowering and selection without AVX512BW+VLX (PR #240805)

Emilio Cota via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Thu Nov 12 07:47:04 PST 2026


================
@@ -43658,7 +43661,9 @@ static SDValue combineTargetShuffle(SDValue N, const SDLoc &DL,
       MVT NewVT =
           MVT::getVectorVT(BCVT.getSimpleVT().getScalarType(),
                            VT.getSizeInBits() / BCVT.getScalarSizeInBits());
-      return DAG.getBitcast(VT, DAG.getNode(X86ISD::VBROADCAST, DL, NewVT, BC));
+      if (TLI.isTypeLegal(NewVT))
----------------
cota wrote:

Yes, for the rebroadcast_v8i32_from_v8bf16 test. It tries to create a v16bf16 node, which raises "Unexpected illegal type!"

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


More information about the llvm-branch-commits mailing list