mirror of
https://github.com/RGBCube/serenity
synced 2025-05-15 07:34:59 +00:00
Kernel: Use a separate timer for profiling the system
This updates the profiling subsystem to use a separate timer to trigger CPU sampling. This timer has a higher resolution (1000Hz) and is independent from the scheduler. At a later time the resolution could even be made configurable with an argument for sys$profiling_enable() - but not today.
This commit is contained in:
parent
d6b3513aab
commit
8614d18956
5 changed files with 46 additions and 8 deletions
|
@ -10,7 +10,6 @@
|
|||
#include <AK/Time.h>
|
||||
#include <Kernel/Debug.h>
|
||||
#include <Kernel/Panic.h>
|
||||
#include <Kernel/PerformanceManager.h>
|
||||
#include <Kernel/Process.h>
|
||||
#include <Kernel/RTC.h>
|
||||
#include <Kernel/Scheduler.h>
|
||||
|
@ -501,8 +500,6 @@ void Scheduler::timer_tick(const RegisterState& regs)
|
|||
return; // TODO: This prevents scheduling on other CPUs!
|
||||
#endif
|
||||
|
||||
PerformanceManager::add_cpu_sample_event(*current_thread, regs);
|
||||
|
||||
if (current_thread->tick())
|
||||
return;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue