This is an archive of the discontinued LLVM Phabricator instance.

AMDGPU/GlobalISel: Handle legacy grid ID intrinsics
ClosedPublic

Authored by arsenm on Jan 17 2022, 6:45 AM.

Details

Summary

Handle the llvm.r600.* intrinsics which are still in use in libclc. I
thought it would be possible to switch it to using
llvm.amdgcn.implicitarg.ptr already, but it turns out the implicit
arguments are currently split into a piece before and after the
explicit kernel arguments.

Diff Detail

Event Timeline

arsenm created this revision.Jan 17 2022, 6:45 AM
arsenm requested review of this revision.Jan 17 2022, 6:45 AM
Herald added a project: Restricted Project. · View Herald TranscriptJan 17 2022, 6:46 AM
Herald added a subscriber: wdng. · View Herald Transcript
foad added a comment.Jan 17 2022, 6:51 AM

I don't understand. Why do we need to handle llvm.r600.* intrinsics on amdgcn subtargets? Why does globalisel need to handle them, when it doesn't support r600?

I don't understand. Why do we need to handle llvm.r600.* intrinsics on amdgcn subtargets? Why does globalisel need to handle them, when it doesn't support r600?

This is so old, it's a holdover when the backend was still called r600. Ideally clover would complete its migration to using an ABI that looks a lot closer to the HSA ABI, but that's been stuck for years. For the moment it's easier to keep the existing scheme working

foad added a comment.Jan 27 2022, 2:26 AM

No objection from me, but I don't know anything about clover or these intrinsics. Is there anyone who has an interest in clover who could review it?

arsenm accepted this revision.Apr 5 2022, 7:18 PM
This revision is now accepted and ready to land.Apr 5 2022, 7:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptApr 5 2022, 7:18 PM
Herald added a subscriber: hsmhsm. · View Herald Transcript