Skip to content
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

[GlobalOpt] Handle DL.getAllocaAddrSpace() != 0 #65847

Merged
merged 3 commits into from
Sep 9, 2023

Conversation

tylanphear
Copy link
Contributor

@tylanphear tylanphear commented Sep 9, 2023

Fix crash on RAUW due to locals and globals having different address
spaces. This is the intent of the original code, but it assumes the
alloca address space is 0. This patch fixes the code to check that the
global's address space matches DL.getAllocaAddrSpace() instead.

Fixes #65155

Fix crash on RAUW due to alloca's and globals having different address
spaces. This is the intent of the original code, but it assumes the
alloca address space is 0. This patch fixes the code to check that the
global's address space matches `DL.getAllocaAddrSpace()` instead.
@tylanphear tylanphear requested a review from a team September 9, 2023 10:27
@tylanphear tylanphear requested a review from a team as a code owner September 9, 2023 10:27
Copy link
Contributor

@arsenm arsenm left a comment

Choose a reason for hiding this comment

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

LGTM except the test needs cleanup to avoid failing when AMDGPU isn't built

@tylanphear tylanphear merged commit 52f6f41 into llvm:main Sep 9, 2023
2 checks passed
@tylanphear tylanphear deleted the fix_65155_check_addrspace branch September 9, 2023 17:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Compilation Aborted (core dumped)
3 participants