diff options
author | Hal Finkel <hfinkel@anl.gov> | 2013-01-03 02:34:09 +0000 |
---|---|---|
committer | Hal Finkel <hfinkel@anl.gov> | 2013-01-03 02:34:09 +0000 |
commit | 82860f63e1678077fe665c21179b9df47fd313bb (patch) | |
tree | 771f722fcf336a1b1a88c1090fb01f39c86ef371 /include | |
parent | e5ab1bee8c1b4ae58bc108c28194af56379e55ac (diff) | |
download | llvm-82860f63e1678077fe665c21179b9df47fd313bb.tar.gz llvm-82860f63e1678077fe665c21179b9df47fd313bb.tar.bz2 llvm-82860f63e1678077fe665c21179b9df47fd313bb.tar.xz |
Add a subtype parameter to VTTI::getShuffleCost
In order to cost subvector insertion and extraction, we need to know
the type of the subvector being extracted.
No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171453 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/Target/TargetTransformImpl.h | 2 | ||||
-rw-r--r-- | include/llvm/TargetTransformInfo.h | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/include/llvm/Target/TargetTransformImpl.h b/include/llvm/Target/TargetTransformImpl.h index 3b6ed1abd3..bbdb4f1dc2 100644 --- a/include/llvm/Target/TargetTransformImpl.h +++ b/include/llvm/Target/TargetTransformImpl.h @@ -72,7 +72,7 @@ public: virtual unsigned getArithmeticInstrCost(unsigned Opcode, Type *Ty) const; virtual unsigned getShuffleCost(ShuffleKind Kind, Type *Tp, - int Index) const; + int Index, Type *SubTp) const; virtual unsigned getCastInstrCost(unsigned Opcode, Type *Dst, Type *Src) const; diff --git a/include/llvm/TargetTransformInfo.h b/include/llvm/TargetTransformInfo.h index 6336afcffe..1dc2b07ddf 100644 --- a/include/llvm/TargetTransformInfo.h +++ b/include/llvm/TargetTransformInfo.h @@ -170,10 +170,10 @@ public: } /// Returns the cost of a shuffle instruction of kind Kind and of type Tp. - /// The index parameter is used by some of the shuffle kinds to add - /// additional information. + /// The index and subtype parameters are used by some of the shuffle kinds + /// to add additional information. virtual unsigned getShuffleCost(ShuffleKind Kind, Type *Tp, - int Index = 0) const { + int Index = 0, Type *SubTp = 0) const { return 1; } |