aboutsummaryrefslogtreecommitdiff
path: root/test/Analysis
diff options
context:
space:
mode:
authorEaswaran Raman <eraman@google.com>2018-11-02 17:39:31 +0000
committerEaswaran Raman <eraman@google.com>2018-11-02 17:39:31 +0000
commit6ed7d3348e3a35bb59c1c3b1027c19baf6f761b6 (patch)
tree26b8f2e8da3d8b8e7a29f2aac41767df86402969 /test/Analysis
parent062cd21484f5cc70015e168155cdae306c1a0f3a (diff)
[ProfileSummary] Add options to override hot and cold count thresholds.
Summary: The hot and cold count thresholds are derived from the summary, but for debugging purposes it is convenient to provide the actual thresholds. Reviewers: davidxl Subscribers: llvm-commits Differential Revision: https://reviews.llvm.org/D54040 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@346005 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Analysis')
-rw-r--r--test/Analysis/ProfileSummary/basic.ll12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/Analysis/ProfileSummary/basic.ll b/test/Analysis/ProfileSummary/basic.ll
index e417e459f04..966a1117c47 100644
--- a/test/Analysis/ProfileSummary/basic.ll
+++ b/test/Analysis/ProfileSummary/basic.ll
@@ -1,19 +1,31 @@
; RUN: opt < %s -disable-output -passes=print-profile-summary -S 2>&1 | FileCheck %s
+; RUN: opt < %s -disable-output -profile-summary-hot-count=500 -passes=print-profile-summary -S 2>&1 | FileCheck %s -check-prefixes=OVERRIDE-HOT
+; RUN: opt < %s -disable-output -profile-summary-cold-count=0 -passes=print-profile-summary -S 2>&1 | FileCheck %s -check-prefixes=OVERRIDE-COLD
+; RUN: opt < %s -disable-output -profile-summary-cold-count=200 -profile-summary-hot-count=1000 -passes=print-profile-summary -S 2>&1 | FileCheck %s -check-prefixes=OVERRIDE-BOTH
define void @f1() !prof !20 {
; CHECK-LABEL: f1 :hot
+; OVERRIDE-HOT-LABEL: f1
+; OVERRIDE-COLD-LABEL: f1 :hot
+; OVERRIDE-BOTH-LABEL: f1
ret void
}
define void @f2() !prof !21 {
; CHECK-LABEL: f2 :cold
+; OVERRIDE-HOT-LABEL: f2 :cold
+; OVERRIDE-COLD-LABEL: f2
+; OVERRIDE-BOTH-LABEL: f2
ret void
}
define void @f3() !prof !22 {
; CHECK-LABEL: f3
+; OVERRIDE-HOT-LABEL: f3
+; OVERRIDE-COLD-LABEL: f3
+; OVERRIDE-BOTH-LABEL: f3
ret void
}