[llvm] [AMDGPU] Reject image-load merges when either op has TFE/LWE (PR #210583)
Yudistira Putra via llvm-commits
llvm-commits at lists.llvm.org
Mon Jul 20 08:14:07 PDT 2026
Yudis-bit wrote:
Thanks for the feedback. I have read the [LLVM AI Tool Use Policy](https://llvm.org/docs/AIToolPolicy.html) and added an AI-tool disclosure to the PR description.
I agree that TFE/LWE operations should be excluded earlier. I updated `collectMergeableInsts()` so MIMG instructions with enabled TFE or LWE are skipped before they enter the mergeable candidate list. The previous pair-level additions to `dmasksCanBeCombined()` have been removed, leaving it identical to upstream.
I updated the MIR tests to add regression coverage for ordinary→TFE and ordinary→LWE orderings, while relying on existing tests `image_load_not_merged_7` and `image_load_not_merged_8` for the reverse orderings. Verified that the focused image-load merge tests pass.
I kept the possible `AMDGPUImageIntrinsicOptimizer` concern outside this PR.
https://github.com/llvm/llvm-project/pull/210583
More information about the llvm-commits
mailing list