summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSimon Pilgrim <llvm-dev@redking.me.uk>2018-11-13 13:45:10 +0000
committerSimon Pilgrim <llvm-dev@redking.me.uk>2018-11-13 13:45:10 +0000
commit077a42ca9f6980334a3a5d171c6176f560f48e26 (patch)
treef34e676e0e6bd7f5c131f8adf54ad2042a6c06e1
parent2fe1076a0888b4cdc22abc33ef2e5d9a7d8de1b1 (diff)
downloadbcm5719-llvm-077a42ca9f6980334a3a5d171c6176f560f48e26.tar.gz
bcm5719-llvm-077a42ca9f6980334a3a5d171c6176f560f48e26.zip
[TTI] Make TargetTransformInfo::getOperandInfo static. NFCI.
It has no member dependencies and this makes it easier to reuse in other cost analysis code. llvm-svn: 346755
-rw-r--r--llvm/include/llvm/Analysis/TargetTransformInfo.h6
-rw-r--r--llvm/lib/Analysis/TargetTransformInfo.cpp3
2 files changed, 4 insertions, 5 deletions
diff --git a/llvm/include/llvm/Analysis/TargetTransformInfo.h b/llvm/include/llvm/Analysis/TargetTransformInfo.h
index eb0e0270157..6ddea8bbdce 100644
--- a/llvm/include/llvm/Analysis/TargetTransformInfo.h
+++ b/llvm/include/llvm/Analysis/TargetTransformInfo.h
@@ -744,9 +744,9 @@ public:
/// and the number of execution units in the CPU.
unsigned getMaxInterleaveFactor(unsigned VF) const;
- /// Collect properties of V used in cost analyzis, e.g. OP_PowerOf2.
- OperandValueKind getOperandInfo(Value *V,
- OperandValueProperties &OpProps) const;
+ /// Collect properties of V used in cost analysis, e.g. OP_PowerOf2.
+ static OperandValueKind getOperandInfo(Value *V,
+ OperandValueProperties &OpProps);
/// This is an approximation of reciprocal throughput of a math/logic op.
/// A higher cost indicates less expected throughput.
diff --git a/llvm/lib/Analysis/TargetTransformInfo.cpp b/llvm/lib/Analysis/TargetTransformInfo.cpp
index eecc898fb5f..25ebcdec3be 100644
--- a/llvm/lib/Analysis/TargetTransformInfo.cpp
+++ b/llvm/lib/Analysis/TargetTransformInfo.cpp
@@ -389,8 +389,7 @@ unsigned TargetTransformInfo::getMaxInterleaveFactor(unsigned VF) const {
}
TargetTransformInfo::OperandValueKind
-TargetTransformInfo::getOperandInfo(Value *V,
- OperandValueProperties &OpProps) const {
+TargetTransformInfo::getOperandInfo(Value *V, OperandValueProperties &OpProps) {
OperandValueKind OpInfo = OK_AnyValue;
OpProps = OP_None;
OpenPOWER on IntegriCloud