diff options
author | Hans Wennborg <hans@hanshq.net> | 2014-01-25 01:18:18 +0000 |
---|---|---|
committer | Hans Wennborg <hans@hanshq.net> | 2014-01-25 01:18:18 +0000 |
commit | 503793e834a8d0e5db8b192ce66e4916389249b4 (patch) | |
tree | 797cd4908c85538f8c746388ece092a62c1f72d0 /include/llvm/Analysis/TargetTransformInfo.h | |
parent | 2760cc2967c3d289a88a2d9527caa02f0d9e82b6 (diff) | |
download | llvm-503793e834a8d0e5db8b192ce66e4916389249b4.tar.gz llvm-503793e834a8d0e5db8b192ce66e4916389249b4.tar.bz2 llvm-503793e834a8d0e5db8b192ce66e4916389249b4.tar.xz |
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
Diffstat (limited to 'include/llvm/Analysis/TargetTransformInfo.h')
-rw-r--r-- | include/llvm/Analysis/TargetTransformInfo.h | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/include/llvm/Analysis/TargetTransformInfo.h b/include/llvm/Analysis/TargetTransformInfo.h index f2613e35c5..a8975b7a4f 100644 --- a/include/llvm/Analysis/TargetTransformInfo.h +++ b/include/llvm/Analysis/TargetTransformInfo.h @@ -92,7 +92,6 @@ public: enum TargetCostConstants { TCC_Free = 0, ///< Expected to fold away in lowering. TCC_Basic = 1, ///< The cost of a typical 'add' instruction. - TCC_Load = 3, TCC_Expensive = 4 ///< The cost of a 'div' instruction on x86. }; @@ -300,13 +299,6 @@ public: /// immediate of the specified type. virtual unsigned getIntImmCost(const APInt &Imm, Type *Ty) const; - /// \brief Return the expected cost of materialization for the given integer - /// immediate of the specified type for a given instruction. The cost can be - /// zero if the immediate can be folded into the specified instruction. - virtual unsigned getIntImmCost(unsigned Opcode, const APInt &Imm, - Type *Ty) const; - virtual unsigned getIntImmCost(Intrinsic::ID IID, const APInt &Imm, - Type *Ty) const; /// @} /// \name Vector Target Information |