This is an archive of the discontinued LLVM Phabricator instance.

[AMDGPU][NFC] Refine matching SMRD offsets.
ClosedPublic

Authored by kosarev on Jun 20 2022, 2:41 AM.

Details

Summary

Tell the matcher what we are looking for instead of matching everything
and then discarding the result if doesn't fit.

Diff Detail

Event Timeline

kosarev created this revision.Jun 20 2022, 2:41 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 20 2022, 2:41 AM
kosarev requested review of this revision.Jun 20 2022, 2:41 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 20 2022, 2:41 AM
foad added inline comments.Jun 20 2022, 3:02 AM
llvm/lib/Target/AMDGPU/AMDGPUISelDAGToDAG.cpp
1889

Can you add a comment and document the arguments?

1971

Can you add a comment and document the arguments?

kosarev updated this revision to Diff 438652.Jun 21 2022, 5:20 AM

Added comments.

kosarev marked 2 inline comments as done.Jun 22 2022, 4:22 AM

Does GlobalISel need the equivalent change?

Does GlobalISel need the equivalent change?

Nope, it seems to have its own facilities to match such operands.

foad accepted this revision.Jul 5 2022, 12:28 AM

I don't understand all the selection logic here, but your changes look reasonable, and I especially like the API change of not passing in a bool &Imm parameter.

This revision is now accepted and ready to land.Jul 5 2022, 12:28 AM
This revision was landed with ongoing or failed builds.Jul 5 2022, 6:17 AM
This revision was automatically updated to reflect the committed changes.