summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h
diff options
context:
space:
mode:
authorKrzysztof Parzyszek <kparzysz@codeaurora.org>2018-06-12 15:12:50 +0000
committerKrzysztof Parzyszek <kparzysz@codeaurora.org>2018-06-12 15:12:50 +0000
commitbea23d065ea4e434e3e3713e70f9a8c610ac12c2 (patch)
tree3da79e1f5836b31928750c42bea1a2f8bae118c6 /llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h
parent724c2173934ca57f7da0743ba83674ad062c8dfb (diff)
downloadbcm5719-llvm-bea23d065ea4e434e3e3713e70f9a8c610ac12c2.tar.gz
bcm5719-llvm-bea23d065ea4e434e3e3713e70f9a8c610ac12c2.zip
[Hexagon] Make floating point operations expensive for vectorization
llvm-svn: 334508
Diffstat (limited to 'llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h')
-rw-r--r--llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h b/llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h
index 99de5c017e2..a232f99fc40 100644
--- a/llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h
+++ b/llvm/lib/Target/Hexagon/HexagonTargetTransformInfo.h
@@ -46,6 +46,11 @@ class HexagonTTIImpl : public BasicTTIImplBase<HexagonTTIImpl> {
bool useHVX() const;
bool isTypeForHVX(Type *VecTy) const;
+ // Returns the number of vector elements of Ty, if Ty is a vector type,
+ // or 1 if Ty is a scalar type. It is incorrect to call this function
+ // with any other type.
+ unsigned getTypeNumElements(Type *Ty) const;
+
public:
explicit HexagonTTIImpl(const HexagonTargetMachine *TM, const Function &F)
: BaseT(TM, F.getParent()->getDataLayout()),
OpenPOWER on IntegriCloud