Skip to content

Commit fcb2062

Browse files
committed
[𝘀𝗽𝗿] initial version
Created using spr 1.3.4
1 parent dbee0d5 commit fcb2062

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

llvm/lib/Support/DebugCounter.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,11 @@ DebugCounter &DebugCounter::instance() {
172172
void DebugCounter::push_back(const std::string &Val) {
173173
if (Val.empty())
174174
return;
175+
#ifdef NDEBUG
176+
// isCountingEnabled is hardcoded to false in NDEBUG.
177+
errs() << "Requested --debug-counter in non-debug LLVM build. This is a "
178+
"no-op.\n";
179+
#endif
175180

176181
// The strings should come in as counter=chunk_list
177182
auto CounterPair = StringRef(Val).split('=');

0 commit comments

Comments
 (0)