From 24b886b0d1addda95111797fec3ed6cc3d5c31d5 Mon Sep 17 00:00:00 2001 From: apio Date: Wed, 11 Dec 2024 19:18:25 +0100 Subject: [PATCH] kernel: Log each thread's instruction pointer when dumping scheduler stats --- kernel/src/thread/Scheduler.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/kernel/src/thread/Scheduler.cpp b/kernel/src/thread/Scheduler.cpp index 35cb458d..79d024da 100644 --- a/kernel/src/thread/Scheduler.cpp +++ b/kernel/src/thread/Scheduler.cpp @@ -457,8 +457,9 @@ namespace Scheduler for (const auto* thread : g_threads) { - kdbgln("Thread %p (belongs to pid %4d) %c [%-20s] %4d, state = %d", thread, thread->process->id, - thread->is_kernel ? 'k' : 'u', thread->cmdline.chars(), thread->tid, (int)thread->state); + kdbgln("Thread %p (belongs to pid %4d) %c [%-20s] %4d, state = %d, ip = %p", thread, thread->process->id, + thread->is_kernel ? 'k' : 'u', thread->cmdline.chars(), thread->tid, (int)thread->state, + (void*)thread->ip()); } for (const auto* process : g_processes)