[PowerPC] Mark all instructions as non-cheap for MachineLICM
authorHal Finkel <hfinkel@anl.gov>
Thu, 8 Jan 2015 22:11:49 +0000 (22:11 +0000)
committerHal Finkel <hfinkel@anl.gov>
Thu, 8 Jan 2015 22:11:49 +0000 (22:11 +0000)
commitb7c01bf40324a859614b88d1dd6416b6c5a430ef
tree82fcc08a53e172600f3d4fafb01ce6a8a8c33a0f
parent9d1500e68f00e76492b9d7ac6fda5803abf96857
[PowerPC] Mark all instructions as non-cheap for MachineLICM

MachineLICM uses a callback named hasLowDefLatency to determine if an
instruction def operand has a 'low' latency. If all relevant operands have a
'low' latency, the instruction is considered too cheap to hoist out of loops
even in low-register-pressure situations. On PowerPC cores, both the embedded
cores and the others, there is no reason to believe that this is a good choice:
all instructions have a cost inside a loop, and hoisting them when not limited
by register pressure is a reasonable default.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225471 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/PowerPC/PPCInstrInfo.h
test/CodeGen/PowerPC/addi-licm.ll [new file with mode: 0644]