Re: [PATCH V3 00/22] perf tools: Introduce an abstraction for Instruction Tracing

From: Adrian Hunter
Date: Mon Dec 15 2014 - 04:11:00 EST


On 12/12/14 20:53, Arnaldo Carvalho de Melo wrote:
> Em Fri, Dec 12, 2014 at 09:13:25AM -0700, David Ahern escreveu:
>> On 12/12/14 6:47 AM, Adrian Hunter wrote:
>>> Here is V3 of some more preparatory patches for Intel PT
>>> that introduce an abstraction for Instruction tracing.
>
>> This is an x86-Intel only feature correct? If that is the case then the code
>> should be not compiled for other architectures.

It is not that simple. In the case of recording, it is not needed for
architectures that don't support it, but in the case of session processing
any architecture can (or should be able to) process the perf.data file of
any other architecture.

I could add config options:

NO_ITRACE_RECORD
NO_ITRACE_PROCESS

And later:

NO_INTEL_PT
NO_INTEL_BTS

Arnaldo?

>
>
> My view so far is that what has been pushed for inclusion facilitates
> supporting an event stream that is so huge that needs to be mapped
> directly from hardware to tools, that would receive it in a special
> area obtained from perf_mmap(). What comes in those events? In this
> case, this Intel PT stuff, but noving (should) prevent it from being
> used for similar situations for other architectures.

That is true, although the only other potential user at the moment is ARM
ETM which is also tracing the instruction flow.

>
> I wonder if we could somehow rename this from 'itrace' to some other
> more meaningful name given the above understanding of this being just
> a way to directly funnel events from hardware to userspace together with
> perf metadata (PERF_RECORD_FORK, PERF_RECORD_MMAP, etc) + other events.

It is hardware-generated architecture-specific large-volume trace data.

What about 'atrace' short for architecture-specific trace?

I don't think the name matters, so long as it is fairly unique.

>
> In the kernel this was called a "AUX" thing, which I also think is
> vague...

I agree that AUX is too vague and also gets mixed up with lots of other
things called aux.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/