Revert "Add Constant Hoisting Pass" (r200034)
authorHans Wennborg <hans@hanshq.net>
Sat, 25 Jan 2014 01:18:18 +0000 (01:18 +0000)
committerHans Wennborg <hans@hanshq.net>
Sat, 25 Jan 2014 01:18:18 +0000 (01:18 +0000)
commit503793e834a8d0e5db8b192ce66e4916389249b4
tree797cd4908c85538f8c746388ece092a62c1f72d0
parent2760cc2967c3d289a88a2d9527caa02f0d9e82b6
Revert "Add Constant Hoisting Pass" (r200034)

This commit caused -Woverloaded-virtual warnings. The two new
TargetTransformInfo::getIntImmCost functions were only added to the superclass,
and to the X86 subclass. The other targets were not updated, and the
warning highlighted this by pointing out that e.g. ARMTTI::getIntImmCost was
hiding the two new getIntImmCost variants.

We could pacify the warning by adding "using TargetTransformInfo::getIntImmCost"
to the various subclasses, or turning it off, but I suspect that it's wrong to
leave the functions unimplemnted in those targets. The default implementations
return TCC_Free, which I don't think is right e.g. for ARM.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@200058 91177308-0d34-0410-b5e6-96231b3b80d8
20 files changed:
include/llvm/Analysis/TargetTransformInfo.h
include/llvm/CodeGen/SelectionDAG.h
include/llvm/CodeGen/SelectionDAGNodes.h
include/llvm/InitializePasses.h
include/llvm/LinkAllPasses.h
include/llvm/Transforms/Scalar.h
lib/Analysis/TargetTransformInfo.cpp
lib/CodeGen/Passes.cpp
lib/CodeGen/SelectionDAG/DAGCombiner.cpp
lib/CodeGen/SelectionDAG/SelectionDAG.cpp
lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp
lib/CodeGen/SelectionDAG/SelectionDAGDumper.cpp
lib/CodeGen/SelectionDAG/TargetLowering.cpp
lib/Target/X86/X86TargetTransformInfo.cpp
lib/Transforms/Scalar/CMakeLists.txt
lib/Transforms/Scalar/CodeGenPrepare.cpp
lib/Transforms/Scalar/ConstantHoisting.cpp [deleted file]
lib/Transforms/Scalar/Scalar.cpp
test/CodeGen/ARM/memcpy-inline.ll
test/CodeGen/X86/large-constants.ll [deleted file]