mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-22 04:25:13 +00:00
Add "times scheduled" field to /proc/summary
This commit is contained in:
parent
44045b258c
commit
e4bfcd2346
Notes:
sideshowbarker
2024-07-19 18:39:54 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/e4bfcd23463
2 changed files with 4 additions and 7 deletions
|
@ -24,13 +24,14 @@ bool ProcFileSystem::initialize()
|
|||
auto stringImpl = StringImpl::createUninitialized(tasks.size() * 128, buffer);
|
||||
memset(buffer, 0, stringImpl->length());
|
||||
char* ptr = buffer;
|
||||
ptr += ksprintf(ptr, "PID OWNER STATE NAME\n");
|
||||
ptr += ksprintf(ptr, "PID OWNER STATE NSCHED NAME\n");
|
||||
for (auto* task : tasks) {
|
||||
ptr += ksprintf(ptr, "%w %w:%w %b %s\n",
|
||||
ptr += ksprintf(ptr, "%w %w:%w %b %w %s\n",
|
||||
task->pid(),
|
||||
task->uid(),
|
||||
task->gid(),
|
||||
task->state(),
|
||||
task->timesScheduled(),
|
||||
task->name().characters());
|
||||
}
|
||||
ptr += ksprintf(ptr, "kmalloc: alloc: %u / free: %u\n", sum_alloc, sum_free);
|
||||
|
|
|
@ -101,7 +101,7 @@ static void undertaker_main()
|
|||
{
|
||||
for (;;) {
|
||||
Task::doHouseKeeping();
|
||||
sleep(10);
|
||||
sleep(300);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -114,10 +114,6 @@ static void init_stage2()
|
|||
|
||||
auto keyboard = make<Keyboard>();
|
||||
|
||||
extern void panel_main();
|
||||
//new Task(panel_main, "panel", IPC::Handle::PanelTask, Task::Ring0);
|
||||
//new Task(led_disco, "led-disco", IPC::Handle::Any, Task::Ring0);
|
||||
|
||||
Disk::initialize();
|
||||
|
||||
#ifdef TEST_VFS
|
||||
|
|
Loading…
Add table
Reference in a new issue