summaryrefslogtreecommitdiffstats
path: root/llvm/unittests/ADT/StatisticTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/unittests/ADT/StatisticTest.cpp')
-rw-r--r--llvm/unittests/ADT/StatisticTest.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/unittests/ADT/StatisticTest.cpp b/llvm/unittests/ADT/StatisticTest.cpp
index ae518277270..17a5c7fc204 100644
--- a/llvm/unittests/ADT/StatisticTest.cpp
+++ b/llvm/unittests/ADT/StatisticTest.cpp
@@ -19,6 +19,7 @@ namespace {
STATISTIC(Counter, "Counts things");
STATISTIC(Counter2, "Counts other things");
+#if LLVM_ENABLE_STATS
static void
extractCounters(const std::vector<std::pair<StringRef, unsigned>> &Range,
OptionalStatistic &S1, OptionalStatistic &S2) {
@@ -29,6 +30,7 @@ extractCounters(const std::vector<std::pair<StringRef, unsigned>> &Range,
S2 = S;
}
}
+#endif
TEST(StatisticTest, Count) {
EnableStatistics();
OpenPOWER on IntegriCloud