aboutsummaryrefslogtreecommitdiff
path: root/include/llvm/Analysis/CodeMetrics.h
diff options
context:
space:
mode:
authorKenneth Uildriks <kennethuil@gmail.com>2010-10-08 13:57:31 +0000
committerKenneth Uildriks <kennethuil@gmail.com>2010-10-08 13:57:31 +0000
commitca52c8ba12285c0e86f1b6d3b354342c59e2a416 (patch)
treef52b5fe896d2b417ef41ff8d6917999c112afe18 /include/llvm/Analysis/CodeMetrics.h
parentd7b8d91d4a2a284bbe9ef6f32b3c25daa7ea0513 (diff)
Start separating out code metrics into code size metrics and code performance metrics. Partial Specialization will apply the former to function specializations, and the latter to all callsites that can use a specialization, in order to decide whether to create a specialization
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116057 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/CodeMetrics.h')
-rw-r--r--include/llvm/Analysis/CodeMetrics.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/llvm/Analysis/CodeMetrics.h b/include/llvm/Analysis/CodeMetrics.h
index 1a67409ad1..e89ad9026d 100644
--- a/include/llvm/Analysis/CodeMetrics.h
+++ b/include/llvm/Analysis/CodeMetrics.h
@@ -77,7 +77,12 @@ namespace llvm {
/// many instructions will be constant folded if the specified value is
/// constant.
unsigned CountCodeReductionForConstant(Value *V);
-
+
+ /// CountBonusForConstant - Figure out an approximation for how much
+ /// per-call performance boost we can expect if the specified value is
+ /// constant.
+ unsigned CountBonusForConstant(Value *V);
+
/// CountCodeReductionForAlloca - Figure out an approximation of how much
/// smaller the function will be if it is inlined into a context where an
/// argument becomes an alloca.