[Mlir-commits] [mlir] [MLIR][XeGPU][TransformOps] Add insert_prefetch op (PR #167356)

Tuomas Kärnä llvmlistbot at llvm.org
Mon Nov 10 10:27:55 PST 2025


tkarna wrote:

> > The parent scf.for loop is matched automatically (as parent of the load op), it is no longer passed in as an argument.
> 
> What happens when there is no parent scf.for, prefetch insertion will still happen? If insertion does not happen, what would be the value of create_nd_desc returned? Previous definition required passing scf.for, so this ambiguous case will not happen.

The op fails if `scf.for` op cannot be found, or if the corresponding load op resides outside the `scf.for` op (indicating that the tile is loop independent). As the op fails, there's no return value. See the [transform-ops-invalid.mlir](https://github.com/llvm/llvm-project/pull/167356/files#diff-dba2521dbb7a414f32695d71142e638274a32cac99877dcfae690c63577f606a) test.

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


More information about the Mlir-commits mailing list