[PATCH] D104409: GlobalISel/Utils: Refactor integer/float constant match functions

Petar Avramovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 15 08:21:10 PDT 2021


Petar.Avramovic updated this revision to Diff 372710.
Petar.Avramovic added a comment.

Rebase and ping.
Brief summary:
Add support for g_fconstant matching and option to return APFloat.
Rename getConstantVRegValWithLookThrough into get{I|F|Any}ConstantVRegValWithLookThrough. Remove HandleFConstant argument, use function with appropriate name instead.
Add matchers for Reg and APInt/Float: g_constant m_GCst(&ValueAndVReg) and g_fconstant m_GFCst(&FPValueAndVReg)


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D104409/new/

https://reviews.llvm.org/D104409

Files:
  llvm/include/llvm/CodeGen/GlobalISel/MIPatternMatch.h
  llvm/include/llvm/CodeGen/GlobalISel/Utils.h
  llvm/lib/CodeGen/GlobalISel/CombinerHelper.cpp
  llvm/lib/CodeGen/GlobalISel/GISelKnownBits.cpp
  llvm/lib/CodeGen/GlobalISel/InstructionSelector.cpp
  llvm/lib/CodeGen/GlobalISel/LegalizerHelper.cpp
  llvm/lib/CodeGen/GlobalISel/Utils.cpp
  llvm/lib/Target/AArch64/GISel/AArch64GlobalISelUtils.cpp
  llvm/lib/Target/AArch64/GISel/AArch64InstructionSelector.cpp
  llvm/lib/Target/AArch64/GISel/AArch64LegalizerInfo.cpp
  llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerCombiner.cpp
  llvm/lib/Target/AArch64/GISel/AArch64PostLegalizerLowering.cpp
  llvm/lib/Target/AArch64/GISel/AArch64PreLegalizerCombiner.cpp
  llvm/lib/Target/AMDGPU/AMDGPUInstructionSelector.cpp
  llvm/lib/Target/AMDGPU/AMDGPULegalizerInfo.cpp
  llvm/lib/Target/AMDGPU/AMDGPURegBankCombiner.cpp
  llvm/lib/Target/AMDGPU/AMDGPURegisterBankInfo.cpp
  llvm/lib/Target/X86/X86InstructionSelector.cpp
  llvm/unittests/CodeGen/GlobalISel/PatternMatchTest.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D104409.372710.patch
Type: text/x-patch
Size: 52030 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210915/340a160c/attachment.bin>


More information about the llvm-commits mailing list