Messages in this thread Patch in this message | | | Date | Thu, 25 Sep 2008 23:41:34 +0200 | From | Ingo Molnar <> | Subject | Re: [RFC PATCH 1/3] Unified trace buffer |
| |
* Ingo Molnar <mingo@elte.hu> wrote:
> * Linus Torvalds <torvalds@linux-foundation.org> wrote: > > > On Thu, 25 Sep 2008, Linus Torvalds wrote: > > > > > > You also ignore the early trace issues, and have apparently not used > > > it for FTRACE. You also ignore the fact that without TSC, it goes > > > into the same "crap mode" that is appropriate for the scheduler, but > > > totally useless for tracing. > > > > Oh, and I didn't notice (because Steven pointed out "notrace" and I > > didn't see any of them), that in order to get things to work you had > > just added > > > > CFLAGS_REMOVE_lockdep.o = -pg > > CFLAGS_REMOVE_lockdep_proc.o = -pg > > CFLAGS_REMOVE_mutex-debug.o = -pg > > CFLAGS_REMOVE_rtmutex-debug.o = -pg > > CFLAGS_REMOVE_cgroup-debug.o = -pg > > CFLAGS_REMOVE_sched_clock.o = -pg > > CFLAGS_REMOVE_sched.o = -mno-spe -pg > > > > all ovr the place, which was part of my argument against this crap in > > the first place. > > Really, we traced all these files for ages. I can restore it if it's > worthwile - but lockdep totally kills the usability of function > traces, it inserts thousands of uninteresting events over and over > again.
to prove it, i just applied this patch:
Index: linux/kernel/Makefile =================================================================== --- linux.orig/kernel/Makefile +++ linux/kernel/Makefile @@ -21,7 +21,6 @@ CFLAGS_REMOVE_mutex-debug.o = -pg CFLAGS_REMOVE_rtmutex-debug.o = -pg CFLAGS_REMOVE_cgroup-debug.o = -pg CFLAGS_REMOVE_sched_clock.o = -pg -CFLAGS_REMOVE_sched.o = -mno-spe -pg endif obj-$(CONFIG_PROFILING) += profile.o and sched.o was fully traced again. For example schedule() to idle is 38 function calls:
$ cd /debug/tracing $ echo ftrace > current_tracer $ cat trace # tracer: ftrace # # TASK-PID CPU# TIMESTAMP FUNCTION # | | | | | [...] ssh-2734 [001] 52.291772: schedule <-schedule_timeout ssh-2734 [001] 52.291772: hrtick_clear <-schedule ssh-2734 [001] 52.291774: _spin_lock <-schedule ssh-2734 [001] 52.291775: deactivate_task <-schedule ssh-2734 [001] 52.291776: dequeue_task <-deactivate_task ssh-2734 [001] 52.291777: dequeue_task_fair <-dequeue_task ssh-2734 [001] 52.291778: update_curr <-dequeue_task_fair ssh-2734 [001] 52.291779: calc_delta_mine <-update_curr ssh-2734 [001] 52.291780: hrtick_start_fair <-dequeue_task_fair ssh-2734 [001] 52.291782: find_busiest_group <-schedule ssh-2734 [001] 52.291783: idle_cpu <-find_busiest_group ssh-2734 [001] 52.291784: target_load <-find_busiest_group ssh-2734 [001] 52.291785: weighted_cpuload <-target_load ssh-2734 [001] 52.291786: weighted_cpuload <-find_busiest_group ssh-2734 [001] 52.291787: cpu_avg_load_per_task <-find_busiest_group ssh-2734 [001] 52.291788: source_load <-find_busiest_group ssh-2734 [001] 52.291789: weighted_cpuload <-source_load ssh-2734 [001] 52.291790: weighted_cpuload <-find_busiest_group ssh-2734 [001] 52.291791: cpu_avg_load_per_task <-find_busiest_group ssh-2734 [001] 52.291792: msecs_to_jiffies <-schedule ssh-2734 [001] 52.291792: msecs_to_jiffies <-schedule ssh-2734 [001] 52.291793: put_prev_task_fair <-schedule ssh-2734 [001] 52.291795: pick_next_task_fair <-schedule ssh-2734 [001] 52.291796: pick_next_task_rt <-schedule ssh-2734 [001] 52.291796: pick_next_task_fair <-schedule ssh-2734 [001] 52.291797: pick_next_task_idle <-schedule ssh-2734 [001] 52.291798: _spin_trylock <-tracing_record_cmdline ssh-2734 [001] 52.291800: _spin_unlock <-tracing_record_cmdline ssh-2734 [001] 52.291802: __switch_to <-thread_return <idle>-0 [001] 52.291804: finish_task_switch <-thread_return <idle>-0 [001] 52.291805: _spin_unlock_irq <-finish_task_switch <idle>-0 [001] 52.291806: tick_nohz_stop_sched_tick <-cpu_idle <idle>-0 [001] 52.291807: ktime_get <-tick_nohz_stop_sched_tick <idle>-0 [001] 52.291807: ktime_get_ts <-ktime_get <idle>-0 [001] 52.291808: getnstimeofday <-ktime_get_ts <idle>-0 [001] 52.291808: acpi_pm_read <-getnstimeofday <idle>-0 [001] 52.291810: set_normalized_timespec <-ktime_get_ts <idle>-0 [001] 52.291811: get_next_timer_interrupt <-tick_nohz_stop_sched_tick it worked just fine in my first blind attempt.
Ingo
| |