-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[AMDGPU][SDAG] Add test for ISD::PTRADD handling in SelectionDAGAddressAnalysis #142777
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
ritter-x2a
merged 1 commit into
main
from
users/ritter-x2a/06-04-_amdgpu_sdag_add_test_for_isd_ptradd_handling_in_selectiondagaddressanalysis
Jun 26, 2025
Merged
[AMDGPU][SDAG] Add test for ISD::PTRADD handling in SelectionDAGAddressAnalysis #142777
ritter-x2a
merged 1 commit into
main
from
users/ritter-x2a/06-04-_amdgpu_sdag_add_test_for_isd_ptradd_handling_in_selectiondagaddressanalysis
Jun 26, 2025
+28
−0
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This was referenced Jun 4, 2025
This was referenced Jun 4, 2025
@llvm/pr-subscribers-backend-amdgpu Author: Fabian Ritter (ritter-x2a) ChangesPre-committing test to show improvements in a follow-up PR. Full diff: https://github.com/llvm/llvm-project/pull/142777.diff 1 Files Affected:
diff --git a/llvm/test/CodeGen/AMDGPU/ptradd-sdag-optimizations.ll b/llvm/test/CodeGen/AMDGPU/ptradd-sdag-optimizations.ll
index 656003f45c54b..bce59307446ce 100644
--- a/llvm/test/CodeGen/AMDGPU/ptradd-sdag-optimizations.ll
+++ b/llvm/test/CodeGen/AMDGPU/ptradd-sdag-optimizations.ll
@@ -132,3 +132,32 @@ declare noalias ptr addrspace(4) @llvm.amdgcn.implicitarg.ptr()
declare i64 @llvm.amdgcn.dispatch.id()
declare noalias ptr addrspace(4) @llvm.amdgcn.dispatch.ptr()
+
+; Taken from memcpy-param-combinations.ll, tests PTRADD handling in
+; SelectionDAGAddressAnalysis.
+define void @memcpy_p1_p4_sz16_align_1_1(ptr addrspace(1) align 1 %dst, ptr addrspace(4) align 1 readonly %src) {
+; GFX942_PTRADD-LABEL: memcpy_p1_p4_sz16_align_1_1:
+; GFX942_PTRADD: ; %bb.0: ; %entry
+; GFX942_PTRADD-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
+; GFX942_PTRADD-NEXT: global_load_dwordx2 v[4:5], v[2:3], off
+; GFX942_PTRADD-NEXT: s_waitcnt vmcnt(0)
+; GFX942_PTRADD-NEXT: global_store_dwordx2 v[0:1], v[4:5], off
+; GFX942_PTRADD-NEXT: global_load_dwordx2 v[2:3], v[2:3], off offset:8
+; GFX942_PTRADD-NEXT: s_waitcnt vmcnt(0)
+; GFX942_PTRADD-NEXT: global_store_dwordx2 v[0:1], v[2:3], off offset:8
+; GFX942_PTRADD-NEXT: s_waitcnt vmcnt(0)
+; GFX942_PTRADD-NEXT: s_setpc_b64 s[30:31]
+;
+; GFX942_LEGACY-LABEL: memcpy_p1_p4_sz16_align_1_1:
+; GFX942_LEGACY: ; %bb.0: ; %entry
+; GFX942_LEGACY-NEXT: s_waitcnt vmcnt(0) expcnt(0) lgkmcnt(0)
+; GFX942_LEGACY-NEXT: global_load_dwordx4 v[2:5], v[2:3], off
+; GFX942_LEGACY-NEXT: s_waitcnt vmcnt(0)
+; GFX942_LEGACY-NEXT: global_store_dwordx4 v[0:1], v[2:5], off
+; GFX942_LEGACY-NEXT: s_waitcnt vmcnt(0)
+; GFX942_LEGACY-NEXT: s_setpc_b64 s[30:31]
+entry:
+ tail call void @llvm.memcpy.p1.p4.i64(ptr addrspace(1) noundef nonnull align 1 %dst, ptr addrspace(4) noundef nonnull align 1 %src, i64 16, i1 false)
+ ret void
+}
+
|
shiltian
approved these changes
Jun 4, 2025
1fe91cb
to
b1fc342
Compare
efdaf03
to
80a86ba
Compare
5537fe6
to
14a92fd
Compare
This was referenced Jun 11, 2025
14a92fd
to
df620d7
Compare
df4a8d1
to
3764eec
Compare
arsenm
approved these changes
Jun 13, 2025
df620d7
to
c0eab93
Compare
3f911ac
to
fd680df
Compare
5df6cfa
to
a7d0f6b
Compare
760e22e
to
554316b
Compare
a7d0f6b
to
e8eccce
Compare
e8eccce
to
510b307
Compare
554316b
to
00afb5a
Compare
This was referenced Jun 23, 2025
00afb5a
to
506c77e
Compare
510b307
to
ade6820
Compare
Merge activity
|
2c35c97
to
61ad2a3
Compare
Base automatically changed from
users/ritter-x2a/06-04-_amdgpu_sdag_add_isd_ptradd_dag_combines
to
main
June 26, 2025 07:40
…ssAnalysis Pre-committing test to show improvements in a follow-up PR.
ade6820
to
a83dc2c
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Pre-committing test to show improvements in a follow-up PR.