All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ingo Molnar <mingo@elte.hu>
To: Peter Zijlstra <peterz@infradead.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>,
	Jason Baron <jbaron@redhat.com>,
	Steven Rostedt <srostedt@redhat.com>,
	lkml <linux-kernel@vger.kernel.org>
Subject: Re: [rfd] function-graph augmentation
Date: Fri, 20 Feb 2009 09:39:02 +0100	[thread overview]
Message-ID: <20090220083902.GD24555@elte.hu> (raw)
In-Reply-To: <1235077304.4612.662.camel@laptop>


* Peter Zijlstra <peterz@infradead.org> wrote:

> Hi,
> 
> I was thinking how best to augment the function graph tracer 
> with various information. It seemed useful to add 
> argument/return tracer entries which, when found after a 
> function entry, or function exit entry would be rendered in 
> the trace.
> 
> So supposing something like;
> 
>  3)               |  handle_mm_fault() {                                        
>  3)               |    count_vm_event() {                                       
>  3)   0.243 us    |      test_ti_thread_flag();                                 
>  3)   0.754 us    |    }                                                        
>  3)   0.249 us    |    pud_alloc();                                             
>  3)   0.251 us    |    pmd_alloc();                                             
>  3)               |    __do_fault() {                                           
>  3)               |      filemap_fault() {                                      
>  3)               |        find_lock_page() {                                   
>  3)               |          find_get_page() {                                  
>  3)   0.248 us    |            test_ti_thread_flag();                           
>  3)   0.844 us    |          }                                                  
>  3)   1.341 us    |        }                                                    
>  3)   1.837 us    |      }                                                      
>  3)   0.275 us    |      _spin_lock();                                          
>  3)   0.257 us    |      page_add_file_rmap();                                  
>  3)   0.233 us    |      native_set_pte_at();                                   
>  3)               |      _spin_unlock() {                                       
>  3)   0.248 us    |        test_ti_thread_flag();                               
>  3)   0.742 us    |      }                                                      
>  3)               |      unlock_page() {                                        
>  3)   0.243 us    |        page_waitqueue();                                    
>  3)   0.237 us    |        __wake_up_bit();                                     
>  3)   1.209 us    |      }                                                      
>  3)   6.274 us    |    }                                                        
>  3)   8.806 us    |  } 
> 
> Say we found:
> 
> trace_graph_entry -- handle_mm_fault()
> trace_func_arg -- address:0xffffffff
> trace_func_arg -- write_access:1
> 
> We'd render:
> 
>  3)               |  handle_mm_fault(.address=0xffffffff, .write_access=1) {
> 
> trace_graph_return -- handle_mm_fault()
> trace_func_ret -- 2
> 
> We'd render:
> 
>  3)   8.806 us    |  } = 2
> 
> Then we can register with tracepoints inside functions to add 
> these generic trace_func_arg/_ret entries to augment the graph 
> (and or function) tracer.
> 
> Does that make sense?

Yeah, it looks really nice that way.

	Ingo

      parent reply	other threads:[~2009-02-20  8:39 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-19 21:01 [rfd] function-graph augmentation Peter Zijlstra
2009-02-19 21:28 ` Frederic Weisbecker
2009-02-19 21:38   ` Frederic Weisbecker
2009-02-20  8:56   ` Ingo Molnar
2009-02-20 13:30     ` Arnaldo Carvalho de Melo
2009-02-20 14:04       ` Arnaldo Carvalho de Melo
2009-02-20 14:17         ` Ingo Molnar
2009-02-20 14:18         ` Peter Zijlstra
2009-02-20 14:32           ` Arnaldo Carvalho de Melo
2009-02-20 14:36     ` Frederic Weisbecker
2009-02-20  8:39 ` Ingo Molnar [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20090220083902.GD24555@elte.hu \
    --to=mingo@elte.hu \
    --cc=fweisbec@gmail.com \
    --cc=jbaron@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=srostedt@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.