[llvm-branch-commits] [llvm] [NFC][AMDGPU] Store through a global pointer in recursive search llvm-split tests (PR #233260)

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Sun Oct 18 09:20:42 PDT 2026


llvmorg-github-actions[bot] wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-backend-amdgpu

Author: Dmitry Sidorov (MrSidims)

<details>
<summary>Changes</summary>

Their function sizes then do not depend on the cost of flat stores.

---

<sub>Stack created with <a href="https://github.com/github/gh-stack">GitHub Stacks CLI</a> • <a href="https://gh.io/stacks-feedback">Give Feedback 💬</a></sub>

---
Full diff: https://github.com/llvm/llvm-project/pull/233260.diff


2 Files Affected:

- (modified) llvm/test/tools/llvm-split/AMDGPU/recursive-search-2.ll (+17-17) 
- (modified) llvm/test/tools/llvm-split/AMDGPU/recursive-search-8.ll (+17-17) 


``````````diff
diff --git a/llvm/test/tools/llvm-split/AMDGPU/recursive-search-2.ll b/llvm/test/tools/llvm-split/AMDGPU/recursive-search-2.ll
index bf16cdd08d22bf..452c7acbcfd49e 100644
--- a/llvm/test/tools/llvm-split/AMDGPU/recursive-search-2.ll
+++ b/llvm/test/tools/llvm-split/AMDGPU/recursive-search-2.ll
@@ -53,11 +53,11 @@
 ; SPLIT5-CHECK4: define amdgpu_kernel void @ABC()
 
 define amdgpu_kernel void @A() {
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
   call void @HelperA()
   ret void
 }
@@ -69,10 +69,10 @@ define internal void @HelperA() {
 }
 
 define amdgpu_kernel void @B() {
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
   call void @HelperB()
   ret void
 }
@@ -85,14 +85,14 @@ define internal void @HelperB() {
 }
 
 define amdgpu_kernel void @C() {
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
   call void @HelperC()
   ret void
 }
diff --git a/llvm/test/tools/llvm-split/AMDGPU/recursive-search-8.ll b/llvm/test/tools/llvm-split/AMDGPU/recursive-search-8.ll
index be78815d5945b6..4bc3a73b028d60 100644
--- a/llvm/test/tools/llvm-split/AMDGPU/recursive-search-8.ll
+++ b/llvm/test/tools/llvm-split/AMDGPU/recursive-search-8.ll
@@ -52,11 +52,11 @@
 ; SPLIT5-CHECK4: define amdgpu_kernel void @ABC()
 
 define amdgpu_kernel void @A() {
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
   call void @HelperA()
   ret void
 }
@@ -68,10 +68,10 @@ define internal void @HelperA() {
 }
 
 define amdgpu_kernel void @B() {
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
   call void @HelperB()
   ret void
 }
@@ -84,14 +84,14 @@ define internal void @HelperB() {
 }
 
 define amdgpu_kernel void @C() {
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
-  store volatile i64 42, ptr null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
+  store volatile i64 42, ptr addrspace(1) null
   call void @HelperC()
   ret void
 }

``````````

</details>


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


More information about the llvm-branch-commits mailing list