diff options
author | Joseph Schuchart <joseph.schuchart@tu-dresden.de> | 2014-07-10 07:50:51 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2014-07-16 16:57:33 -0400 |
commit | 0f5f5bcd112292f14b75750dde7461463bb1c7bb (patch) | |
tree | bb87bcdd3d703c5f397d46db0c7bd7c14d144e62 /tools/perf/scripts/python/sched-migration.py | |
parent | 05f832e3a267d6e45d092595bdf9339d127ea137 (diff) |
perf script: Add callchain to generic and tracepoint events
This provides valuable information for tracing performance problems.
Since this change alters the interface for the python scripts, also
adjust the script generation and the provided scripts.
Signed-off-by: Joseph Schuchart <joseph.schuchart@tu-dresden.de>
Acked-by: Thomas Ilsche <thomas.ilsche@tu-dresden.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@gmail.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Thomas Ilsche <thomas.ilsche@tu-dresden.de>
Link: http://lkml.kernel.org/r/53BE7E1B.10503@tu-dresden.de
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/scripts/python/sched-migration.py')
-rw-r--r-- | tools/perf/scripts/python/sched-migration.py | 41 |
1 files changed, 20 insertions, 21 deletions
diff --git a/tools/perf/scripts/python/sched-migration.py b/tools/perf/scripts/python/sched-migration.py index 74d55ec08aed..de66cb3b72c9 100644 --- a/tools/perf/scripts/python/sched-migration.py +++ b/tools/perf/scripts/python/sched-migration.py | |||
@@ -369,93 +369,92 @@ def trace_end(): | |||
369 | 369 | ||
370 | def sched__sched_stat_runtime(event_name, context, common_cpu, | 370 | def sched__sched_stat_runtime(event_name, context, common_cpu, |
371 | common_secs, common_nsecs, common_pid, common_comm, | 371 | common_secs, common_nsecs, common_pid, common_comm, |
372 | comm, pid, runtime, vruntime): | 372 | common_callchain, comm, pid, runtime, vruntime): |
373 | pass | 373 | pass |
374 | 374 | ||
375 | def sched__sched_stat_iowait(event_name, context, common_cpu, | 375 | def sched__sched_stat_iowait(event_name, context, common_cpu, |
376 | common_secs, common_nsecs, common_pid, common_comm, | 376 | common_secs, common_nsecs, common_pid, common_comm, |
377 | comm, pid, delay): | 377 | common_callchain, comm, pid, delay): |
378 | pass | 378 | pass |
379 | 379 | ||
380 | def sched__sched_stat_sleep(event_name, context, common_cpu, | 380 | def sched__sched_stat_sleep(event_name, context, common_cpu, |
381 | common_secs, common_nsecs, common_pid, common_comm, | 381 | common_secs, common_nsecs, common_pid, common_comm, |
382 | comm, pid, delay): | 382 | common_callchain, comm, pid, delay): |
383 | pass | 383 | pass |
384 | 384 | ||
385 | def sched__sched_stat_wait(event_name, context, common_cpu, | 385 | def sched__sched_stat_wait(event_name, context, common_cpu, |
386 | common_secs, common_nsecs, common_pid, common_comm, | 386 | common_secs, common_nsecs, common_pid, common_comm, |
387 | comm, pid, delay): | 387 | common_callchain, comm, pid, delay): |
388 | pass | 388 | pass |
389 | 389 | ||
390 | def sched__sched_process_fork(event_name, context, common_cpu, | 390 | def sched__sched_process_fork(event_name, context, common_cpu, |
391 | common_secs, common_nsecs, common_pid, common_comm, | 391 | common_secs, common_nsecs, common_pid, common_comm, |
392 | parent_comm, parent_pid, child_comm, child_pid): | 392 | common_callchain, parent_comm, parent_pid, child_comm, child_pid): |
393 | pass | 393 | pass |
394 | 394 | ||
395 | def sched__sched_process_wait(event_name, context, common_cpu, | 395 | def sched__sched_process_wait(event_name, context, common_cpu, |
396 | common_secs, common_nsecs, common_pid, common_comm, | 396 | common_secs, common_nsecs, common_pid, common_comm, |
397 | comm, pid, prio): | 397 | common_callchain, comm, pid, prio): |
398 | pass | 398 | pass |
399 | 399 | ||
400 | def sched__sched_process_exit(event_name, context, common_cpu, | 400 | def sched__sched_process_exit(event_name, context, common_cpu, |
401 | common_secs, common_nsecs, common_pid, common_comm, | 401 | common_secs, common_nsecs, common_pid, common_comm, |
402 | comm, pid, prio): | 402 | common_callchain, comm, pid, prio): |
403 | pass | 403 | pass |
404 | 404 | ||
405 | def sched__sched_process_free(event_name, context, common_cpu, | 405 | def sched__sched_process_free(event_name, context, common_cpu, |
406 | common_secs, common_nsecs, common_pid, common_comm, | 406 | common_secs, common_nsecs, common_pid, common_comm, |
407 | comm, pid, prio): | 407 | common_callchain, comm, pid, prio): |
408 | pass | 408 | pass |
409 | 409 | ||
410 | def sched__sched_migrate_task(event_name, context, common_cpu, | 410 | def sched__sched_migrate_task(event_name, context, common_cpu, |
411 | common_secs, common_nsecs, common_pid, common_comm, | 411 | common_secs, common_nsecs, common_pid, common_comm, |
412 | comm, pid, prio, orig_cpu, | 412 | common_callchain, comm, pid, prio, orig_cpu, |
413 | dest_cpu): | 413 | dest_cpu): |
414 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, | 414 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, |
415 | common_pid, common_comm) | 415 | common_pid, common_comm, common_callchain) |
416 | parser.migrate(headers, pid, prio, orig_cpu, dest_cpu) | 416 | parser.migrate(headers, pid, prio, orig_cpu, dest_cpu) |
417 | 417 | ||
418 | def sched__sched_switch(event_name, context, common_cpu, | 418 | def sched__sched_switch(event_name, context, common_cpu, |
419 | common_secs, common_nsecs, common_pid, common_comm, | 419 | common_secs, common_nsecs, common_pid, common_comm, common_callchain, |
420 | prev_comm, prev_pid, prev_prio, prev_state, | 420 | prev_comm, prev_pid, prev_prio, prev_state, |
421 | next_comm, next_pid, next_prio): | 421 | next_comm, next_pid, next_prio): |
422 | 422 | ||
423 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, | 423 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, |
424 | common_pid, common_comm) | 424 | common_pid, common_comm, common_callchain) |
425 | parser.sched_switch(headers, prev_comm, prev_pid, prev_prio, prev_state, | 425 | parser.sched_switch(headers, prev_comm, prev_pid, prev_prio, prev_state, |
426 | next_comm, next_pid, next_prio) | 426 | next_comm, next_pid, next_prio) |
427 | 427 | ||
428 | def sched__sched_wakeup_new(event_name, context, common_cpu, | 428 | def sched__sched_wakeup_new(event_name, context, common_cpu, |
429 | common_secs, common_nsecs, common_pid, common_comm, | 429 | common_secs, common_nsecs, common_pid, common_comm, |
430 | comm, pid, prio, success, | 430 | common_callchain, comm, pid, prio, success, |
431 | target_cpu): | 431 | target_cpu): |
432 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, | 432 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, |
433 | common_pid, common_comm) | 433 | common_pid, common_comm, common_callchain) |
434 | parser.wake_up(headers, comm, pid, success, target_cpu, 1) | 434 | parser.wake_up(headers, comm, pid, success, target_cpu, 1) |
435 | 435 | ||
436 | def sched__sched_wakeup(event_name, context, common_cpu, | 436 | def sched__sched_wakeup(event_name, context, common_cpu, |
437 | common_secs, common_nsecs, common_pid, common_comm, | 437 | common_secs, common_nsecs, common_pid, common_comm, |
438 | comm, pid, prio, success, | 438 | common_callchain, comm, pid, prio, success, |
439 | target_cpu): | 439 | target_cpu): |
440 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, | 440 | headers = EventHeaders(common_cpu, common_secs, common_nsecs, |
441 | common_pid, common_comm) | 441 | common_pid, common_comm, common_callchain) |
442 | parser.wake_up(headers, comm, pid, success, target_cpu, 0) | 442 | parser.wake_up(headers, comm, pid, success, target_cpu, 0) |
443 | 443 | ||
444 | def sched__sched_wait_task(event_name, context, common_cpu, | 444 | def sched__sched_wait_task(event_name, context, common_cpu, |
445 | common_secs, common_nsecs, common_pid, common_comm, | 445 | common_secs, common_nsecs, common_pid, common_comm, |
446 | comm, pid, prio): | 446 | common_callchain, comm, pid, prio): |
447 | pass | 447 | pass |
448 | 448 | ||
449 | def sched__sched_kthread_stop_ret(event_name, context, common_cpu, | 449 | def sched__sched_kthread_stop_ret(event_name, context, common_cpu, |
450 | common_secs, common_nsecs, common_pid, common_comm, | 450 | common_secs, common_nsecs, common_pid, common_comm, |
451 | ret): | 451 | common_callchain, ret): |
452 | pass | 452 | pass |
453 | 453 | ||
454 | def sched__sched_kthread_stop(event_name, context, common_cpu, | 454 | def sched__sched_kthread_stop(event_name, context, common_cpu, |
455 | common_secs, common_nsecs, common_pid, common_comm, | 455 | common_secs, common_nsecs, common_pid, common_comm, |
456 | comm, pid): | 456 | common_callchain, comm, pid): |
457 | pass | 457 | pass |
458 | 458 | ||
459 | def trace_unhandled(event_name, context, common_cpu, common_secs, common_nsecs, | 459 | def trace_unhandled(event_name, context, event_fields_dict): |
460 | common_pid, common_comm): | ||
461 | pass | 460 | pass |