--- a/src/hotspot/share/jfr/periodic/jfrThreadCPULoadEvent.cpp Sun Aug 25 19:09:22 2019 +0200
+++ b/src/hotspot/share/jfr/periodic/jfrThreadCPULoadEvent.cpp Mon Aug 26 13:09:14 2019 +0200
@@ -119,6 +119,9 @@
while (iter.has_next()) {
JavaThread* const jt = iter.next();
assert(jt != NULL, "invariant");
+ if (jt->jfr_thread_local()->is_excluded()) {
+ continue;
+ }
++number_of_threads;
EventThreadCPULoad event(UNTIMED);
if (JfrThreadCPULoadEvent::update_event(event, jt, cur_wallclock_time, processor_count)) {