[all-commits] [llvm/llvm-project] 0dadfa: [mlir][Vector] Fix scalable dim guard in broadcast...

Cheng-Chieh Liu via All-commits all-commits at lists.llvm.org
Thu Sep 24 09:16:31 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 0dadfa004c8bac744279c168e5edb6b265a02e7c
      https://github.com/llvm/llvm-project/commit/0dadfa004c8bac744279c168e5edb6b265a02e7c
  Author: Cheng-Chieh Liu <jay87406 at gmail.com>
  Date:   2026-09-24 (Thu, 24 Sep 2026)

  Changed paths:
    M mlir/lib/Dialect/Vector/Transforms/LowerVectorBroadcast.cpp
    M mlir/test/Dialect/Vector/vector-broadcast-lowering-transforms.mlir

  Log Message:
  -----------
  [mlir][Vector] Fix scalable dim guard in broadcast lowering (#225021)

The scalable outer dim guard in `BroadcastOpLowering` only covered the
"stretch not at start" case (`m != 0`). The "stretch at start" case
unrolls the same `dstType.getDimSize(0)` trip count and has the same
bug: broadcasting e.g. `vector<1x4xf32>` to `vector<[3]x4xf32>` only
fills the static minimum lanes via `vector.insert`, leaving the rest as
`ub.poison`.

Widen the guard to cover both cases, and add a regression test.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list