[PATCH] D57314: [PowerPC] more opportunity for converting reg+reg to reg+imm
Stefan Pintilie via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 28 10:15:57 PST 2019
stefanp added a comment.
Looked through this and tried a couple of things but overall it looks good.
My only comments are a couple of minor nit items.
================
Comment at: llvm/lib/Target/PowerPC/PPCInstrInfo.cpp:3209
// If DefMI also uses the register to be forwarded, we can only forward it
// if DefMI is being erased.
+ if (DefMI.modifiesRegister(Reg, &getRegisterInfo()))
----------------
nit:
Since you have updated the condition in the code can you also update the comment above it?
================
Comment at: llvm/test/CodeGen/PowerPC/convert-rr-to-ri-instr-add.mir:2
+# RUN: llc -mtriple=powerpc64le--linux-gnu -stop-after ppc-pre-emit-peephole %s -o - -verify-machineinstrs | FileCheck %s
+
+---
----------------
nit:
You should probably add to the test a comment to say what you are testing here.
It's not really obvious from the test because you just ask to stop after the peephole opt and that could mean you are looking for any number of things.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57314/new/
https://reviews.llvm.org/D57314
More information about the llvm-commits
mailing list