GlobalISel: Add combine for G_UREM by power of 2
authorMatt Arsenault <Matthew.Arsenault@amd.com>
Wed, 6 Jan 2021 23:45:12 +0000 (18:45 -0500)
committerMatt Arsenault <Matthew.Arsenault@amd.com>
Thu, 7 Jan 2021 21:36:35 +0000 (16:36 -0500)
commit1f9b6ef91ffd8ea487aa083d146c7568e7243457
tree6020311b36650b3a0e59cd0a697ab657c9d0ae55
parent9e1aaa9943b814c22ae03f4abb3171dac8062801
GlobalISel: Add combine for G_UREM by power of 2

Really I want this in the legalizer, but this is a start.
llvm/include/llvm/CodeGen/GlobalISel/CombinerHelper.h
llvm/include/llvm/Target/GlobalISel/Combine.td
llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
llvm/test/CodeGen/AMDGPU/GlobalISel/combine-urem-pow-2.mir [new file with mode: 0644]
llvm/test/CodeGen/AMDGPU/GlobalISel/urem.i32.ll
llvm/test/CodeGen/AMDGPU/GlobalISel/urem.i64.ll