[PATCH] D74188: GlobalISel: Fix lowering of G_CTLZ/G_CTTZ

Matt Arsenault via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Feb 6 18:21:13 PST 2020


arsenm created this revision.
arsenm added reviewers: aemerson, paquette, aditya_nandakumar, Petar.Avramovic, dsanders.
Herald added subscribers: kerbowa, volkan, hiraditya, rovka, nhaehnle, wdng, jvesely.
Herald added a project: LLVM.

The type passed to lower was invalid, so I'm not sure how this was
even working before. The source and destination type also do not have
to match, so make sure to use the right ones.


https://reviews.llvm.org/D74188

Files:
  llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp
  llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
  llvm/lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp
  llvm/test/CodeGen/AMDGPU/GlobalISel/legalize-ctlz.mir
  llvm/test/CodeGen/AMDGPU/GlobalISel/legalize-cttz.mir
  llvm/test/CodeGen/AMDGPU/GlobalISel/regbankselect-ctlz.mir
  llvm/test/CodeGen/AMDGPU/GlobalISel/regbankselect-cttz.mir
  llvm/test/CodeGen/ARM/GlobalISel/arm-legalize-bitcounts.mir

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D74188.243067.patch
Type: text/x-patch
Size: 32709 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200207/192690cc/attachment.bin>


More information about the llvm-commits mailing list