From: Ingo Molnar <mingo@elte.hu>
To: Pekka Enberg <penberg@cs.helsinki.fi>
Cc: mingo@redhat.com, hpa@zytor.com, paulus@samba.org,
linux-kernel@vger.kernel.org, a.p.zijlstra@chello.nl,
ink@jurassic.park.msu.ru, tglx@linutronix.de, rth@twiddle.net,
mcree@orcon.net.nz, linux-tip-commits@vger.kernel.org
Subject: Re: [tip:perf/core] perf tools, Alpha: Add Alpha support to perf.h
Date: Mon, 26 Oct 2009 13:22:47 +0100 [thread overview]
Message-ID: <20091026122247.GA31982@elte.hu> (raw)
In-Reply-To: <84144f020910260508n47ef067ci4adfd02cd3f87edd@mail.gmail.com>
* Pekka Enberg <penberg@cs.helsinki.fi> wrote:
> Hi Ingo,
>
> On Mon, Oct 26, 2009 at 1:38 PM, tip-bot for Michael Cree
> <mcree@orcon.net.nz> wrote:
> > Commit-ID: fcd14b3203b538dca04a2b065c774c0b57863eec
> > Gitweb: http://git.kernel.org/tip/fcd14b3203b538dca04a2b065c774c0b57863eec
> > Author: Michael Cree <mcree@orcon.net.nz>
> > AuthorDate: Mon, 26 Oct 2009 21:32:06 +1300
> > Committer: Ingo Molnar <mingo@elte.hu>
> > CommitDate: Mon, 26 Oct 2009 09:45:41 +0100
> >
> > perf tools, Alpha: Add Alpha support to perf.h
> >
> > For the perf tool the patch implements an Alpha specific section
> > in the perf.h header file.
> >
> > Signed-off-by: Michael Cree <mcree@orcon.net.nz>
> > Cc: Richard Henderson <rth@twiddle.net>
> > Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
> > Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
> > Cc: Paul Mackerras <paulus@samba.org>
> > LKML-Reference: <1256545926-6972-1-git-send-email-mcree@orcon.net.nz>
> > Signed-off-by: Ingo Molnar <mingo@elte.hu>
> > ---
> > tools/perf/perf.h | 6 ++++++
> > 1 files changed, 6 insertions(+), 0 deletions(-)
> >
> > diff --git a/tools/perf/perf.h b/tools/perf/perf.h
> > index 8cc4623..216bdb2 100644
> > --- a/tools/perf/perf.h
> > +++ b/tools/perf/perf.h
> > @@ -47,6 +47,12 @@
> > #define cpu_relax() asm volatile("":::"memory")
> > #endif
> >
> > +#ifdef __alpha__
> > +#include "../../arch/alpha/include/asm/unistd.h"
> > +#define rmb() asm volatile("mb" ::: "memory")
> > +#define cpu_relax() asm volatile("" ::: "memory")
> > +#endif
>
> OK, I'll bite. We tell userspace developers not to include kernel
> headers. Why is it okay for perf to do it (especially for something
> that's in asm)?
The main counter-argument against inclusion was always "what if we break
them accidentally". I.e. it can become a semi-ABI - stuff we cannot
change because we cannot change the outside projects. With perf this
cannot occur - it's all in one Git tree and can always be fixed/changed.
Note that we reuse a couple of other facilities in tools/perf as well -
linux/list.h, rbtree.c, etc. - and this is good - you can code perf as
if you were hacking on the kernel! ;-)
Ingo
next prev parent reply other threads:[~2009-10-26 12:23 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-26 8:32 [PATCH] [alpha] Add minimal support for software performance events Michael Cree
2009-10-26 8:48 ` Ingo Molnar
2009-10-27 8:09 ` Michael Cree
2009-11-08 12:22 ` Ingo Molnar
2009-11-08 12:27 ` Ingo Molnar
2009-11-11 7:43 ` Michael Cree
2009-11-11 7:48 ` [tip:perf/core] perf tools: Test -fstack-protector-all compiler option for inclusion in CFLAGS tip-bot for Michael Cree
2009-10-27 18:29 ` [PATCH] [alpha] Add minimal support for software performance events Matt Turner
2009-10-28 20:56 ` Sam Ravnborg
2009-10-26 11:38 ` [tip:perf/core] perf tools, Alpha: Add Alpha support to perf.h tip-bot for Michael Cree
2009-10-26 12:08 ` Pekka Enberg
2009-10-26 12:22 ` Ingo Molnar [this message]
2009-10-28 20:58 ` Sam Ravnborg
2009-11-10 21:21 ` Peter Zijlstra
2009-12-01 4:30 ` [PATCH] [alpha] Add minimal support for software performance events Matt Turner
2009-12-01 9:31 ` Michael Cree
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=20091026122247.GA31982@elte.hu \
--to=mingo@elte.hu \
--cc=a.p.zijlstra@chello.nl \
--cc=hpa@zytor.com \
--cc=ink@jurassic.park.msu.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-tip-commits@vger.kernel.org \
--cc=mcree@orcon.net.nz \
--cc=mingo@redhat.com \
--cc=paulus@samba.org \
--cc=penberg@cs.helsinki.fi \
--cc=rth@twiddle.net \
--cc=tglx@linutronix.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