Skip to content

Commit 44d6e43

Browse files
committed
Add tracepoint to unpark
Signed-off-by: tajila <[email protected]>
1 parent b2f9c71 commit 44d6e43

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

thread/common/omrthread.c

+4
Original file line numberDiff line numberDiff line change
@@ -3345,17 +3345,21 @@ omrthread_park(int64_t millis, intptr_t nanos)
33453345
void
33463346
omrthread_unpark(omrthread_t thread)
33473347
{
3348+
uintptr_t slowPath = 0;
33483349
ASSERT(thread);
33493350

33503351
THREAD_LOCK(thread, CALLER_UNPARK_THREAD);
33513352

33523353
thread->flags |= J9THREAD_FLAG_UNPARKED;
33533354

33543355
if (thread->flags & J9THREAD_FLAG_PARKED) {
3356+
slowPath = 1;
33553357
NOTIFY_WRAPPER(thread);
33563358
}
33573359

33583360
THREAD_UNLOCK(thread);
3361+
3362+
Trc_THR_Unpark(slowPath);
33593363
}
33603364

33613365

thread/j9thr.tdf

+2
Original file line numberDiff line numberDiff line change
@@ -73,3 +73,5 @@ TraceException=Trc_THR_omrthread_get_cpu_time_ex_clock_gettime_failed Overhead=1
7373
TraceException=Trc_THR_fixupThreadAccounting_omrthread_get_cpu_time_ex_error Overhead=1 Level=1 NoEnv Test Template="omrthread_get_cpu_time_ex returned error=%zd for thread=0x%p"
7474

7575
TraceEvent=Trc_THR_EnableRawMonitorSpin_CustomSpinOption Overhead=1 Level=3 NoEnv Test Template="(ENABLE_RAW_MONITOR_SPIN) Using custom spin counts: %s, monitor: %p, threeTierSpinCount1: %zu, threeTierSpinCount2: %zu, threeTierSpinCount3: %zu, adaptSpin: %zu"
76+
77+
TraceEvent=Trc_THR_Unpark Overhead=1 Level=5 NoEnv Test Template="Unpark slow path taken=%zu"

0 commit comments

Comments
 (0)