[PATCH] D31852: [PowerPC] Eliminate compares - convert reg/reg instructions fed by constants to reg/imm instructions

Nemanja Ivanovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 10 13:41:21 PDT 2017


nemanjai updated this revision to Diff 118462.
nemanjai added a comment.

This isn't really dependent on the compare elimination patches (although it will find more opportunities once those land).

- Rebased to top of trunk
- Added handling for `(isel %truereg, %falsereg, (cmpi (li $imm1), $imm2))` and another test case
- Added an option to turn off fixed-point transformation
- Added a few more useful stats


Repository:
  rL LLVM

https://reviews.llvm.org/D31852

Files:
  lib/Target/PowerPC/PPC.h
  lib/Target/PowerPC/PPCInstrInfo.cpp
  lib/Target/PowerPC/PPCInstrInfo.h
  lib/Target/PowerPC/PPCMIPeephole.cpp
  lib/Target/PowerPC/PPCTargetMachine.cpp
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-add.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-and.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-cmp.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-or-xor.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-ori.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-rldicl.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-sld.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-srd.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-subfc.mir
  test/CodeGen/PowerPC/fold-constants-into-imm-instrs-xori.mir
  test/CodeGen/PowerPC/simplifyConstCmpToISEL.ll
  test/CodeGen/PowerPC/variable_elem_vec_extracts.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D31852.118462.patch
Type: text/x-patch
Size: 74536 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171010/a2ed9a3e/attachment.bin>


More information about the llvm-commits mailing list