diff options
author | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2009-09-29 14:25:15 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2009-11-05 07:53:53 +0100 |
commit | eed3b9cf3fe3fcc7a50238dfcab63a63914e8f42 (patch) | |
tree | b8db321400bc9a17e7cfefb82dbfb515a841fab2 /scripts/kallsyms.c | |
parent | 7bc7d637452383d56ba4368d4336b0dde1bb476d (diff) | |
download | blackbird-op-linux-eed3b9cf3fe3fcc7a50238dfcab63a63914e8f42.tar.gz blackbird-op-linux-eed3b9cf3fe3fcc7a50238dfcab63a63914e8f42.zip |
nohz: Reuse ktime in sub-functions of tick_check_idle.
On a system with NOHZ=y tick_check_idle calls tick_nohz_stop_idle and
tick_nohz_update_jiffies. Given the right conditions (ts->idle_active
and/or ts->tick_stopped) both function get a time stamp with ktime_get.
The same time stamp can be reused if both function require one.
On s390 this change has the additional benefit that gcc inlines the
tick_nohz_stop_idle function into tick_check_idle. The number of
instructions to execute tick_check_idle drops from 225 to 144
(without the ktime_get optimization it is 367 vs 215 instructions).
before:
0) | tick_check_idle() {
0) | tick_nohz_stop_idle() {
0) | ktime_get() {
0) | read_tod_clock() {
0) 0.601 us | }
0) 1.765 us | }
0) 3.047 us | }
0) | ktime_get() {
0) | read_tod_clock() {
0) 0.570 us | }
0) 1.727 us | }
0) | tick_do_update_jiffies64() {
0) 0.609 us | }
0) 8.055 us | }
after:
0) | tick_check_idle() {
0) | ktime_get() {
0) | read_tod_clock() {
0) 0.617 us | }
0) 1.773 us | }
0) | tick_do_update_jiffies64() {
0) 0.593 us | }
0) 4.477 us | }
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: john stultz <johnstul@us.ibm.com>
LKML-Reference: <20090929122533.206589318@de.ibm.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'scripts/kallsyms.c')
0 files changed, 0 insertions, 0 deletions