summaryrefslogtreecommitdiffstats
path: root/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2016-01-06 20:20:48 +0000
committerdim <dim@FreeBSD.org>2016-01-06 20:20:48 +0000
commite13d34a8ff8cbd5565582c4efc3c00d9d2aab26f (patch)
tree7ea42cf427bda317125421123460445eb3c7075f /contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp
parente06c171d67ab436f270b15f7e364a8d8f77c01f2 (diff)
parentfc74ff5a0792641885551a63d9ddf8cbfdf76e3c (diff)
downloadFreeBSD-src-e13d34a8ff8cbd5565582c4efc3c00d9d2aab26f.zip
FreeBSD-src-e13d34a8ff8cbd5565582c4efc3c00d9d2aab26f.tar.gz
Update clang to trunk r256945.
Diffstat (limited to 'contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp')
-rw-r--r--contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp10
1 files changed, 0 insertions, 10 deletions
diff --git a/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp b/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp
index 3877433..5ae861e 100644
--- a/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp
+++ b/contrib/llvm/tools/clang/lib/CodeGen/CodeGenPGO.cpp
@@ -721,17 +721,7 @@ CodeGenPGO::applyFunctionAttributes(llvm::IndexedInstrProfReader *PGOReader,
if (!haveRegionCounts())
return;
- uint64_t MaxFunctionCount = PGOReader->getMaximumFunctionCount();
uint64_t FunctionCount = getRegionCount(nullptr);
- if (FunctionCount >= (uint64_t)(0.3 * (double)MaxFunctionCount))
- // Turn on InlineHint attribute for hot functions.
- // FIXME: 30% is from preliminary tuning on SPEC, it may not be optimal.
- Fn->addFnAttr(llvm::Attribute::InlineHint);
- else if (FunctionCount <= (uint64_t)(0.01 * (double)MaxFunctionCount))
- // Turn on Cold attribute for cold functions.
- // FIXME: 1% is from preliminary tuning on SPEC, it may not be optimal.
- Fn->addFnAttr(llvm::Attribute::Cold);
-
Fn->setEntryCount(FunctionCount);
}
OpenPOWER on IntegriCloud