Re: çåï[PATCH 2/4] perf tools: relate 'start' & 'end' to perf_session

From: David Ahern
Date: Wed Nov 06 2013 - 10:15:52 EST


On 11/6/13, 4:23 AM, çæå wrote:
Hi David:
The goal is to simplify transfering the times to function
perf_session__process_events() and other functions in the sample
processing path. Session is a parameter throughout the total sample
processing path.

Right. By putting the time check in session code you are going to be dropping samples related to task events too. e.g., a task is created after the session is started and before the time window. Samples for the task (FORK, MMAP, COMM) will get dropped as will events for other tasks (e.g., EXIT). Then samples during the time window will not correlate nicely/correctly to a task with a name and maps.

I have patches locally with this same idea -- collect data for a broad time window but only show/analyze samples for a specific time window. Instead of having the time check in the session code I have it in the commands (report, script, etc). e.g., in sample event processing:

if (perf_time__skip_sample(sample))
goto out;

where that function has the logic to compare sample timestamps to a user given window.

I seem to recall Namhyung send out a patch on time intervals as well.

David
--
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/