This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Document the intended semantics of llvm.amdgcn.s.buffer.load
ClosedPublic

Authored by foad on Mar 29 2022, 6:31 AM.

Diff Detail

Event Timeline

foad created this revision.Mar 29 2022, 6:31 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 29 2022, 6:31 AM
Herald added subscribers: kerbowa, t-tye, tpr and 4 others. · View Herald Transcript
foad requested review of this revision.Mar 29 2022, 6:31 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 29 2022, 6:31 AM
dstuttard added inline comments.Mar 29 2022, 6:38 AM
llvm/include/llvm/IR/IntrinsicsAMDGPU.td
957

The added description would imply that this should be updated too (since it isn't necessarily SGPR/imm)

foad updated this revision to Diff 418862.Mar 29 2022, 6:47 AM

Remove SGPR/imm comment.

foad marked an inline comment as done.Mar 29 2022, 6:47 AM
alex-t added inline comments.Mar 30 2022, 3:49 AM
llvm/include/llvm/IR/IntrinsicsAMDGPU.td
953

Does this imply that the divergent descriptor and uniform offset result in s_buffer_load too?

foad added inline comments.Mar 30 2022, 5:15 AM
llvm/include/llvm/IR/IntrinsicsAMDGPU.td
953

For this patch I just wanted to say what is special about llvm.amdgcn.s.buffer.load. I don't want to say anything about divergent descriptors because (a) they are not fully supported yet (globalisel inserts a waterfall loop for them but selectiondag does not) and (b) if/when we do document that they are supported, it would apply to many intrinsics (all the ones that take a descriptor argument) not just this one.

(But the answer to your question is yes, I would expect divergent descriptor and uniform offset to result in s_buffer_load.)

alex-t accepted this revision.Mar 30 2022, 1:46 PM
This revision is now accepted and ready to land.Mar 30 2022, 1:46 PM
This revision was landed with ongoing or failed builds.Mar 31 2022, 1:13 AM
This revision was automatically updated to reflect the committed changes.