From: Lee Revell <rlrevell@joe-job.com>
To: linux-kernel <linux-kernel@vger.kernel.org>
Cc: john stultz <johnstul@us.ibm.com>, Ingo Molnar <mingo@elte.hu>
Subject: sched_clock -> check_tsc_unstable -> tsc_read_c3_time ?!?
Date: Thu, 13 Oct 2005 16:01:27 -0400 [thread overview]
Message-ID: <1129233687.16243.52.camel@mindpipe> (raw)
Looking at the latency traces it appears that sched_clock could be
optimized a bit:
evolutio-16296 0D.h4 32us : activate_task (try_to_wake_up)
evolutio-16296 0D.h4 33us : sched_clock (activate_task)
evolutio-16296 0D.h4 33us : check_tsc_unstable (sched_clock)
evolutio-16296 0D.h4 34us : tsc_read_c3_time (sched_clock)
evolutio-16296 0D.h4 35us : recalc_task_prio (activate_task)
check_tsc_unstable and tsc_read_c3_time appear to be new. Here they
are:
49 /* Code to mark and check if the TSC is unstable
50 * due to cpufreq or due to unsynced TSCs
51 */
52 static int tsc_unstable;
53 int check_tsc_unstable(void)
54 {
55 return tsc_unstable;
56 }
73 u64 tsc_read_c3_time(void)
74 {
75 return tsc_c3_offset;
76 }
Shouldn't these be inlined or something? I know it's only a few
microseconds, but it seems like excessive function call overhead to me.
I don't use power management and the TSC is stable on this machine. Why
do we have to call these simple accessor functions over and over?
Lee
next reply other threads:[~2005-10-13 20:01 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-10-13 20:01 Lee Revell [this message]
2005-10-13 20:11 ` sched_clock -> check_tsc_unstable -> tsc_read_c3_time ?!? john stultz
2005-10-13 20:13 ` Lee Revell
2005-10-14 4:35 ` Ingo Molnar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1129233687.16243.52.camel@mindpipe \
--to=rlrevell@joe-job.com \
--cc=johnstul@us.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox