lkml.org 
[lkml]   [2013]   [Nov]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: 答复:答复:[PATCH 2/4] perf too ls: relate 'start' & 'end' to perf session
On 11/7/13, 5:14 AM, 秦承刚 wrote:
> Hi, David
> The samples for the task before the end of the time window are not
> influenced by the time window. The time window only cover the sample
> events in the ordered_samples. FORK, MMAP, COMM events are not in the
> ordered_samples. They are delivered in the function
> "perf_session__process_event". The task events that are after the end of
> the time window can be ingnored safely.

following builtin-report.c:
perf_session__process_events() -> __perf_session__process_events() -->
perf_session__process_event():

ret = perf_evlist__parse_sample(session->evlist, event, &sample);
if (ret)
return ret;

if (tool->ordered_samples) {
ret = perf_session_queue_event(session, event, &sample,
file_offset);
if (ret != -ETIME)
return ret;
}

All samples are dropped into the ordered_samples queue if they have a
timestamp. And I believe it was the sample_id_all patch that put a
timestamp on task events too (~2.6.35 or 36 timeframe).


> Would you give me a link to your patch?

https://github.com/dsahern/linux/blob/timehist-timeofday-3.9/tools/perf/util/time-utils.c
and
https://github.com/dsahern/linux/blob/timehist-timeofday-3.9/tools/perf/builtin-timehist.c

I did not push the builtin-report.c change, but it follows directly from
the timehist command.

David
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2013-11-07 17:01    [W:0.086 / U:0.128 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site