[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1337853048.9783.92.camel@laptop>
Date: Thu, 24 May 2012 11:50:48 +0200
From: Peter Zijlstra <a.p.zijlstra@...llo.nl>
To: Jiri Olsa <jolsa@...hat.com>
Cc: acme@...hat.com, mingo@...e.hu, paulus@...ba.org,
cjashfor@...ux.vnet.ibm.com, fweisbec@...il.com,
eranian@...gle.com, gorcunov@...nvz.org, tzanussi@...il.com,
mhiramat@...hat.com, robert.richter@....com, fche@...hat.com,
linux-kernel@...r.kernel.org, masami.hiramatsu.pt@...achi.com,
drepper@...il.com, asharma@...com, benjamin.redelings@...cent.org
Subject: Re: [PATCH 02/16] perf: Add ability to attach registers dump to
sample
On Wed, 2012-05-23 at 21:32 +0200, Jiri Olsa wrote:
> /*
> + * Values for sample_regs when PERF_SAMPLE_REGS is set.
> + * Defines register set to be attached to the sample.
> + */
> +enum perf_sample_regs {
> + PERF_SAMPLE_REGS_USER = 1U << 0, /* user registers */
> + PERF_SAMPLE_REGS_MAX = 1U << 1, /* non-ABI */
> +};
> + __u64 sample_regs; /* enum perf_sample_regs */
> +
> + /*
> + * Arch specific mask for PERF_SAMPLE_REGS_USER setup.
> + * Defines set of user regs to dump on samples.
> + * See asm/perf_regs.h for details.
> + */
> + __u64 sample_regs_user;
This all just smells.. :/
So you're wasting 64 bits to specify PERF_SAMPLE_REGS_USER while also
implying we'll need another u64 for every other value of
perf_sample_regs?
What are we doing here and why?
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists