This is an archive of the discontinued LLVM Phabricator instance.

AMDGPU : median3 matching incomplete or not working
ClosedPublic

Authored by aakanksha555 on Nov 9 2018, 9:49 AM.

Diff Detail

Repository
rL LLVM

Event Timeline

aakanksha555 created this revision.Nov 9 2018, 9:49 AM
arsenm added inline comments.Nov 9 2018, 11:04 AM
lib/Target/AMDGPU/SIInstructions.td
582 ↗(On Diff #173365)

Extra whitespace change

test/CodeGen/AMDGPU/umed3.ll
368 ↗(On Diff #173365)

The signed version should go in smed3.ll

This could also use the helper functions like the rest of the tests. Should also have the various permutations

369 ↗(On Diff #173365)

Run instnamer on this

aakanksha555 marked 2 inline comments as done.

Added 16 test cases with the permutations of min(max(a, b), max(min(a, b), c))

Removed a redundant test case.

arsenm accepted this revision.Nov 12 2018, 8:15 AM

LGTM

lib/Target/AMDGPU/SIInstructions.td
583 ↗(On Diff #173416)

Extra whitespace change

This revision is now accepted and ready to land.Nov 12 2018, 8:15 AM

Also change the message before committing to be more descriptive. It sounds like something is broken as is

This revision was automatically updated to reflect the committed changes.