Skip to content

Commit

Permalink
refer to --userspace-metric-event on error with -E
Browse files Browse the repository at this point in the history
  • Loading branch information
Tessa Todorowski committed Jun 6, 2024
1 parent 8e13667 commit 50d7f49
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/perf/counter/group/reader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,12 @@ Reader<T>::Reader(ExecutionScope scope, bool enable_on_exec)
<< " counters at once might exceed the hardware limit of simultaneously "
"openable counters.";
}

if (perf::counter::CounterProvider::instance().has_group_counters(
ExecutionScope(scope)))
{
Log::error() << "Try using --userspace-metric-event if the error persists.";
}
throw e;
}
}
Expand Down

0 comments on commit 50d7f49

Please sign in to comment.