public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Steven Rostedt <rostedt@goodmis.org>
Cc: "Tim Bird" <tim.bird@am.sony.com>,
	"Ryan Mallon" <ryan@bluewatersys.com>,
	"Peter Zijlstra" <a.p.zijlstra@chello.nl>,
	"Frederic Weisbecker" <fweisbec@gmail.com>,
	"Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>,
	"linux kernel" <linux-kernel@vger.kernel.org>,
	linux-arm-kernel <linux-arm-kernel@lists.arm.linux.org.uk>
Subject: Re: How to use a different sched_clock() for ftrace on omap?
Date: Thu, 7 May 2009 15:59:11 +0200	[thread overview]
Message-ID: <20090507135911.GD481@elte.hu> (raw)
In-Reply-To: <alpine.DEB.2.00.0905070953170.32734@gandalf.stny.rr.com>


* Steven Rostedt <rostedt@goodmis.org> wrote:

> On Thu, 7 May 2009, Ingo Molnar wrote:
> 
> > 
> > * Tim Bird <tim.bird@am.sony.com> wrote:
> > 
> > > Hi all,
> > > 
> > > I've worked up a replacement sched_clock for ftrace on my omap 
> > > platform. The current sched_clock, based on the 32K timer, has low 
> > > resolution and doesn't provide very useful results.
> > 
> > hm, why dont you replace the real sched_clock() with it? High 
> > resolution sched_clock() gives (much!) better scheduling, better 
> > fairness, etc.
> 
> Probably because it is board specific, that he can not replace it. But I 
> think something like Ryan's idea would be good. Instead of aliasing, just 
> make another weak symbol.
> 
> 
> unsigned long long __attribute__((weak)) board_sched_clock(void)
> {
> 	[ original sched_clock code ]
> }
> 
> unsigned long long sched_clock(void)
> {
> 	return board_sched_clock();
> }
> 
> Then Tim could define a "board_sched_clock" that would be used 
> when that board is active.

that sounds good. Weak aliases are now generally supported in Linux, 
we excluded that one broken GCC version that messed them up.

	Ingo

  reply	other threads:[~2009-05-07 14:02 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-05-06 23:54 How to use a different sched_clock() for ftrace on omap? Tim Bird
2009-05-07  0:34 ` Ryan Mallon
2009-05-07  8:51 ` Ingo Molnar
2009-05-07 13:56   ` Steven Rostedt
2009-05-07 13:59     ` Ingo Molnar [this message]
     [not found] <cyZbZ-7Eg-9@gated-at.bofh.it>
2009-05-07 14:08 ` Kevin Hilman
2009-05-07 17:19   ` Tim Bird
2009-05-07 17:34     ` Kevin Hilman

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=20090507135911.GD481@elte.hu \
    --to=mingo@elte.hu \
    --cc=a.p.zijlstra@chello.nl \
    --cc=fweisbec@gmail.com \
    --cc=linux-arm-kernel@lists.arm.linux.org.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=ryan@bluewatersys.com \
    --cc=tim.bird@am.sony.com \
    --cc=u.kleine-koenig@pengutronix.de \
    /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