This is an archive of the discontinued LLVM Phabricator instance.

[OpenMP][Plugin] Update the global address calculation
ClosedPublic

Authored by tianshilei1992 on Jul 20 2023, 2:28 PM.

Details

Summary

Current global address caculation doesn't work for AMDGPU in some cases (https://reviews.llvm.org/D142569#4506212).
The root cause is the sh_addr is not substracted when caculating the address.

Diff Detail

Event Timeline

tianshilei1992 created this revision.Jul 20 2023, 2:28 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 20 2023, 2:28 PM
tianshilei1992 requested review of this revision.Jul 20 2023, 2:28 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 20 2023, 2:28 PM

What is the special case that makes this not work? I figured this was working in general since I've used it for the rpc symbol as well.

jdoerfert accepted this revision.Jul 23 2023, 1:27 PM

What is the special case that makes this not work? I figured this was working in general since I've used it for the rpc symbol as well.

It seems to depend on the section the data ends up in. Not 100% sure. If this doesn't break anyone, it's good.

This revision is now accepted and ready to land.Jul 23 2023, 1:27 PM

remove the overloaded AMDGPU version

I'm gonna land this patch and see if AMD's buildbot is happy.