[llvm] [AMDGPU][InstCombine] Optimize constant shuffle patterns (PR #192246)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Apr 15 05:43:47 PDT 2026
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff origin/main HEAD --extensions cpp -- llvm/lib/Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp --diff_from_common_commit
``````````
:warning:
The reproduction instructions above might return results for more than one PR
in a stack if you are using a stacked PR workflow. You can limit the results by
changing `origin/main` to the base branch/commit you want to compare against.
:warning:
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/llvm/lib/Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp b/llvm/lib/Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp
index 95310e7d0..8e6fa4839 100644
--- a/llvm/lib/Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp
+++ b/llvm/lib/Target/AMDGPU/AMDGPUInstCombineIntrinsic.cpp
@@ -722,8 +722,8 @@ GCNTTIImpl::hoistLaneIntrinsicThroughOperand(InstCombiner &IC,
// Match llvm.amdgcn.mbcnt.lo / mbcnt.hi patterns that compute the lane ID.
// WaveSize is needed because standalone mbcnt.lo returns lane % 32, which only
-// equals the lane ID on wave32. On wave64, the full mbcnt.hi(-1, mbcnt.lo(-1, 0))
-// chain is required.
+// equals the lane ID on wave32. On wave64, the full mbcnt.hi(-1, mbcnt.lo(-1,
+// 0)) chain is required.
static bool matchLaneID(const Value *V, unsigned WaveSize) {
const auto *II = dyn_cast<IntrinsicInst>(V);
if (!II)
``````````
</details>
https://github.com/llvm/llvm-project/pull/192246
More information about the llvm-commits
mailing list