[all-commits] [llvm/llvm-project] dd0c7f: [MLIR][Linalg] Fix crash in tileToForallOpImpl for...
Mehdi Amini via All-commits
all-commits at lists.llvm.org
Mon Apr 13 11:16:14 PDT 2026
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: dd0c7f1f344f22a29d3c483966f89ffb5f70850e
https://github.com/llvm/llvm-project/commit/dd0c7f1f344f22a29d3c483966f89ffb5f70850e
Author: Mehdi Amini <joker.eph at gmail.com>
Date: 2026-04-13 (Mon, 13 Apr 2026)
Changed paths:
M mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp
M mlir/test/Dialect/Linalg/tile-to-forall.mlir
Log Message:
-----------
[MLIR][Linalg] Fix crash in tileToForallOpImpl for rank-0 ops (#189000)
When tiling a rank-0 linalg.generic op, tileUsingSCF returns an empty
loops vector (rank-0 ops have no parallel dimensions and produce no
scf.forall). Two call sites unconditionally accessed
tilingResult.loops.front(), causing a crash:
- tileToForallOpImpl: the loop normalization block was entered whenever
mixedNumThreads was empty, regardless of whether any loops exist. Guard
it with \!tilingResult.loops.empty().
- TileUsingForallOp::apply: tileOps.push_back was called
unconditionally. Guard it with \!tilingResult.loops.empty().
Add regression tests for both the tile_sizes and num_threads paths,
verifying that the linalg.generic is preserved and no scf.forall is
emitted.
Fixes #187073
Assisted-by: Claude Code
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