[prev in list] [next in list] [prev in thread] [next in thread] 

List:       oprofile-list
Subject:    Re: wanna pick up the thread profiling TODO item
From:       Philippe Elie <phil.el () wanadoo ! fr>
Date:       2002-08-28 10:17:03
[Download RAW message or body]

Ka Fai Lau wrote:

>I have done a smiliar DCPI project in my school but I
>was using RTC because I couldn't get APIC work.  I
>believe the DCPI idea is really cool and I am really
>excited that oprofile get it started on Linux :D.
>
>I am interested to implement the TODO list item -
>"thread profiling".  Can someone give me some idea
>about what is the direction and what should be
>expected?
>
TODO:
 o thread profiling in the old and new flavour (2.5 introduce a new 
thread handling)
   - what is different ??

As the question mark say there is nothing visible to oprofile between
old and new kernel thread handling

I dunno a lot about thread implementation in linux but imho most
of the work must be made in daemon/post-profile tools, the module
only need to change slightly notification of sys_call clone/fork/vfork
allowing the daemon to differentiate between a thread start and a
process start.

I've not a clear view of how daemon must handle threaded process but
clearly we need to add relation ship between main process and thread
process. We can't use a simple samples filename change, adding a field
in filename which give the parent of this thread with a magic value for
no parent, can't work because we create sample file lazilly and so on if
pid 33 create a thread with pid 34, then pid 34 create a thread pid 35 the
relation ship is broken if pid 34 don't receive any sample :/

for now the priority is to define if we need and how to dump the
parent/child thread relation in the samples files directory

John, this can have impact on the future pp_interface, we already drop
the parent_pid field in the new pp_interface because, due to lazilly
samples file creation, the parent/child process can be broken, I suspect
we try to encode too many things in samples file name ?

regards,
Phil




[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic