OSDN Git Service

[Constant Hoisting] Make the constant materialization cost operand dependent
authorJuergen Ributzka <juergen@apple.com>
Fri, 21 Mar 2014 06:04:45 +0000 (06:04 +0000)
committerJuergen Ributzka <juergen@apple.com>
Fri, 21 Mar 2014 06:04:45 +0000 (06:04 +0000)
commitd3cf783ed12c8e658598a1a9173a27ea8481073b
treeb9ff8de7419efe9b43a7d1c407b4c8d05f6e1f2a
parent337eb3adbed6d1ba790555bd3a0dc2d02d2345bc
[Constant Hoisting] Make the constant materialization cost operand dependent

Extend the target hook to take also the operand index into account when
calculating the cost of the constant materialization.

Related to <rdar://problem/16381500>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204435 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Analysis/TargetTransformInfo.h
lib/Analysis/TargetTransformInfo.cpp
lib/Target/X86/X86TargetTransformInfo.cpp
lib/Transforms/Scalar/ConstantHoisting.cpp
test/CodeGen/X86/lsr-interesting-step.ll
test/CodeGen/X86/negate-add-zero.ll
test/Transforms/ConstantHoisting/X86/phi.ll