This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Select d16 stores even when sramecc is enabled
ClosedPublic

Authored by foad on Jun 25 2021, 6:38 AM.

Details

Summary

The sramecc feature changes the behaviour of d16 loads so they do not
preserve the unused 16 bits of the result register, but it has no impact
on d16 stores, so we should make use of them even when the feature is
enabled.

Diff Detail

Event Timeline

foad created this revision.Jun 25 2021, 6:38 AM
foad requested review of this revision.Jun 25 2021, 6:38 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 25 2021, 6:38 AM

Are you sure about this? This is still rmw on a cache line.

foad added a comment.Jun 25 2021, 8:34 AM

Are you sure about this? This is still rmw on a cache line.

No, I'm not sure, it's just based on the documentation I've seen which says that sramecc affects d16 loads.

This revision is now accepted and ready to land.Jun 25 2021, 10:34 AM
arsenm added inline comments.Jun 25 2021, 11:51 AM
llvm/test/CodeGen/AMDGPU/store-hi16.ll
106

Should make this a plain GFX9 check then? This is just dropping all the GFX906 checks

foad updated this revision to Diff 422798.Apr 14 2022, 3:11 AM

Change GFX900 checks to plain GFX9 since they are not different in gfx906.

Herald added a project: Restricted Project. · View Herald TranscriptApr 14 2022, 3:11 AM
Herald added a subscriber: hsmhsm. · View Herald Transcript
arsenm accepted this revision.Apr 14 2022, 6:18 PM
This revision was landed with ongoing or failed builds.Apr 19 2022, 1:35 AM
This revision was automatically updated to reflect the committed changes.