[all-commits] [llvm/llvm-project] f5e8e9: [mlir][VectorOps] Fold extract on constant_mask (#...

Lukas Sommer via All-commits all-commits at lists.llvm.org
Mon Mar 2 07:55:13 PST 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: f5e8e98a4ef4a4889523101b4d4039e13bccbdf4
      https://github.com/llvm/llvm-project/commit/f5e8e98a4ef4a4889523101b4d4039e13bccbdf4
  Author: Lukas Sommer <lukas.sommer at amd.com>
  Date:   2026-03-02 (Mon, 02 Mar 2026)

  Changed paths:
    M mlir/lib/Dialect/Vector/IR/VectorOps.cpp
    M mlir/test/Dialect/Vector/canonicalize.mlir

  Log Message:
  -----------
  [mlir][VectorOps] Fold extract on constant_mask (#183780)

Fold `vector.extract(vector.constant_mask)` to `vector.constant_mask` if
possible.

If the static position is outside of the masked area, the pattern will
fold to a constant all-false value instead.

Dynamic positions are only supported if the mask covers the entire
vector in that dimension.

Assisted-by: Claude Code

---------

Signed-off-by: Lukas Sommer <lukas.sommer at amd.com>



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