Loop Strength Reduce: Scaling factor cost.
authorQuentin Colombet <qcolombet@apple.com>
Fri, 31 May 2013 21:29:03 +0000 (21:29 +0000)
committerQuentin Colombet <qcolombet@apple.com>
Fri, 31 May 2013 21:29:03 +0000 (21:29 +0000)
commit06f5ebc5a1604b01689cf2d482dd05f956538af6
tree052709f167b5eaa2b9cd8b704361e6f8c92b5236
parente17388fd34a12dd0ecb8e347645b945db91d90a7
Loop Strength Reduce: Scaling factor cost.

Account for the cost of scaling factor in Loop Strength Reduce when rating the
formulae. This uses a target hook.

The default implementation of the hook is: if the addressing mode is legal, the
scaling factor is free.

<rdar://problem/13806271>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@183045 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Analysis/TargetTransformInfo.h
include/llvm/Target/TargetLowering.h
lib/Analysis/TargetTransformInfo.cpp
lib/CodeGen/BasicTargetTransformInfo.cpp
lib/Transforms/Scalar/LoopStrengthReduce.cpp