Messages in this thread | | | Date | Thu, 7 Feb 2019 14:28:01 +0100 | From | Hugo Lefeuvre <> | Subject | Re: [PATCH 1/3] sched/wait: use freezable_schedule when possible |
| |
Hi,
> > The result is a potential performance gain during freeze, since less > > tasks have to be awaken. > > I'm curious did you try the freezing process and see if pointless wakeups are > reduced? That would be an added bonus if you did.
Test env: fresh Debian QEMU vm with 4.19 stable kernel.
Test process:
- Added two debug logs to freeze_task:
bool freeze_task(struct task_struct *p) { unsigned long flags; [snip] pr_info("freezing a task"); [snip] if (freezer_should_skip(p)) { pr_info("skeeping a task"); return false; } [snip] }
- Triggered manual freeze:
# echo freezer > /sys/power/pm_test # echo test_resume > /sys/power/disk # echo disk > /sys/power/state
- grep -c to get the number of "freezing a task" and "skeeping a task" lines in kern.log.
Results:
Without my patch: 448 calls freeze_task, 12 skipped. With my patch: 448 calls, 32 skipped.
2.6x more tasks skipped.
Not sure this is the best way to test this patch, though. Any advice?
regards, Hugo
-- Hugo Lefeuvre (hle) | www.owl.eu.com RSA4096_ 360B 03B3 BF27 4F4D 7A3F D5E8 14AA 1EB8 A247 3DFD ed25519_ 37B2 6D38 0B25 B8A2 6B9F 3A65 A36F 5357 5F2D DC4C [unhandled content-type:application/pgp-signature] | |