summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorDavid Peixotto <dpeixott@codeaurora.org>2014-09-26 17:48:40 +0000
committerDavid Peixotto <dpeixott@codeaurora.org>2014-09-26 17:48:40 +0000
commit472b05b36caa538b46f6e302c353507da4ac3bc9 (patch)
treedac50a72e860ad4cb7750ef51877755ed4e7ac87 /llvm/lib
parentacd1906446815d320fa4478b0268684734128320 (diff)
downloadbcm5719-llvm-472b05b36caa538b46f6e302c353507da4ac3bc9.tar.gz
bcm5719-llvm-472b05b36caa538b46f6e302c353507da4ac3bc9.zip
Ignore annotation function calls in cost computation
The annotation instructions are dropped during codegen and have no impact on size. In some cases, the annotations were preventing the unroller from unrolling a loop because the annotation calls were pushing the cost over the unrolling threshold. Differential Revision: http://reviews.llvm.org/D5335 llvm-svn: 218525
Diffstat (limited to 'llvm/lib')
-rw-r--r--llvm/lib/Analysis/TargetTransformInfo.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/llvm/lib/Analysis/TargetTransformInfo.cpp b/llvm/lib/Analysis/TargetTransformInfo.cpp
index 9a0133a6c2b..e09babf1fbf 100644
--- a/llvm/lib/Analysis/TargetTransformInfo.cpp
+++ b/llvm/lib/Analysis/TargetTransformInfo.cpp
@@ -392,6 +392,7 @@ struct NoTTI final : ImmutablePass, TargetTransformInfo {
// FIXME: This is wrong for libc intrinsics.
return TCC_Basic;
+ case Intrinsic::annotation:
case Intrinsic::assume:
case Intrinsic::dbg_declare:
case Intrinsic::dbg_value:
OpenPOWER on IntegriCloud