This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU] Select flat atomic fmin/fmax
ClosedPublic

Authored by mbrkusanin on Mar 15 2023, 6:55 AM.

Details

Summary

Also disables global atomic fmin/fmax x2 patterns on gfx11

Diff Detail

Event Timeline

mbrkusanin created this revision.Mar 15 2023, 6:55 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 15 2023, 6:55 AM
mbrkusanin requested review of this revision.Mar 15 2023, 6:55 AM
arsenm added inline comments.
llvm/test/CodeGen/AMDGPU/fp-min-max-flat-atomics-f64.ll
3

Use explicit -global-isel=0

llvm/test/CodeGen/AMDGPU/fp-min-max-flat-atomics.ll
3

Ditto

rampitec added inline comments.Mar 15 2023, 3:46 PM
llvm/test/CodeGen/AMDGPU/fp-min-max-flat-atomics-f64.ll
4

Add prefix GCN to both lines, that way autogenerated checks will be common for SDAG and ISel if match. Here and in other tests.

mbrkusanin edited the summary of this revision. (Show Details)
  • gfx11 has no x2/f64 insts so global_atomic_*_x2 patterns are no longer in isGFX10Plus group (new test for gfx10 only: fp-min-max-global-atomics-f64.ll)
  • updated tests so they would better match with common check lines
mbrkusanin marked 2 inline comments as done.Mar 16 2023, 5:56 AM
mbrkusanin added inline comments.
llvm/test/CodeGen/AMDGPU/fp-min-max-flat-atomics-f64.ll
4

Added common GFX10 and GFX11 check labels across tests because SDAG and GISel can match. Instruction was renamed for GFX11 so I did not add GCN label for all.

This revision is now accepted and ready to land.Mar 16 2023, 9:59 AM
This revision was automatically updated to reflect the committed changes.
llvm/test/CodeGen/AMDGPU/fp-min-max-global-atomics-f64.ll