]> granicus.if.org Git - llvm/commit
[Stats] Add ALWAYS_ENABLED_STATISTIC enabled regardless of LLVM_ENABLE_STATS.
authorVolodymyr Sapsai <vsapsai@apple.com>
Fri, 11 Oct 2019 00:57:41 +0000 (00:57 +0000)
committerVolodymyr Sapsai <vsapsai@apple.com>
Fri, 11 Oct 2019 00:57:41 +0000 (00:57 +0000)
commitd02a34d72e17383a9b5c68de2023af6bc7629479
treeb7c4a9f712320021d300e7335bda7b70fb68723f
parent70a8e547383d48e14a67fd84894cb39a6c83e63a
[Stats] Add ALWAYS_ENABLED_STATISTIC enabled regardless of LLVM_ENABLE_STATS.

The intended usage is to measure relatively expensive operations. So the
cost of the statistic is negligible compared to the cost of a measured
operation and can be enabled all the time without impairing the
compilation time.

rdar://problem/55715134

Reviewers: dsanders, bogner, rtereshin

Reviewed By: dsanders

Subscribers: hiraditya, jkorous, dexonsmith, ributzka, cfe-commits, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D68252

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@374490 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/ADT/Statistic.h
lib/Support/Statistic.cpp
unittests/ADT/StatisticTest.cpp