Skip to content

Conversation

@zhaomaosu
Copy link
Contributor

Address Sanitizer pass changed the way to get stack offset from PtrIntAdd to GEP instruction. We need to update the pattern match rule correspondingly.

Address Sanitizer pass changed the way to get stack offset from
PtrIntAdd to GEP instruction. We need to update the patter match
corresponding.
@zhaomaosu zhaomaosu requested a review from a team as a code owner November 19, 2025 06:38
@zhaomaosu zhaomaosu requested a review from wenju-he November 19, 2025 06:39
Copy link
Contributor

@wenju-he wenju-he left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

using namespace PatternMatch;
Value *X;
if (match(V, m_IntToPtr(m_Add(m_PtrToInt(m_Value(X)), m_ConstantInt()))))
if (match(V, m_GEP(m_Value(X), m_Constant())))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this the right way to move forward considering that GEP is going to be deprecated upstream in the near future?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated it to use m_PtrAdd.

@zhaomaosu
Copy link
Contributor Author

Hi @intel/llvm-gatekeepers, this PR is ready to be merged.

@steffenlarsen steffenlarsen merged commit 3d70234 into intel:sycl Nov 21, 2025
36 of 38 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants