[PATCH] D138087: GlobalISel: Fold some idempotent operations

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 15 20:33:53 PST 2022


arsenm created this revision.
arsenm added reviewers: paquette, aemerson, Pierre-vh, foad.
Herald added subscribers: kosarev, kerbowa, jvesely.
Herald added a project: All.
arsenm requested review of this revision.
Herald added a subscriber: wdng.
Herald added a project: LLVM.

This makes the existing fabs_fabs fold redundant, which
I thought was using more tablegen matching, but apparently not.
I'm not sure how to make match work with multiple opcodes. There
are a few more this could handle, but these are the ones that
legalization are more likely to introduce.


https://reviews.llvm.org/D138087

Files:
  llvm/include/llvm/Target/GlobalISel/Combine.td
  llvm/test/CodeGen/AMDGPU/GlobalISel/postlegalizer-combiner-fcanonicalize.mir
  llvm/test/CodeGen/AMDGPU/GlobalISel/postlegalizer-combiner-freeze.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D138087.475671.patch
Type: text/x-patch
Size: 10186 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221116/97b7d971/attachment.bin>


More information about the llvm-commits mailing list