[Cbe-oss-dev] Re Refactored cell powerpc oprofile patch

Carl Love cel at us.ibm.com
Thu Mar 6 11:34:26 EST 2008


It looks like it provides a lot of similar functionality as the code in
arch/powerpc/platforms/cell/pmu.c.  Specifically, implementation of
shadow registers, the low level register read/write.  A few differences
that I do see is the pmu.c provides more basic functionality for
reading/writing registers and accessing the trace buffer.  Basically our
call reads one entry and returns it where as your code reads the some
specified number of bytes from the buffer putting it in a user specified
location.  That functionality is left to the caller to take care of by
the cell pmu.c functions.  Also, you have put a lot of logic for
figuring out the island number event number mapping into the kernel,
i.e. functions like pm_translate_signal_group_number_on_island().  There
seems to be a fair bit of event signal organization put into the code.
The cell implementation keeps all of this out of the kernel.  pmu.c just
provides the ability to read/write a value to the register it.  For
example your ps3_enable_pm() function handles setting up the bookmark
registers as writing the register to enable the counters.  In general it
appears that the ps3-lpm module puts a lot more complexity at the lower
level calls then the cell pmu.c code. 

At the high level, it appears that the functionality provided by your
driver and pmu.c is similar.  There is a fair difference implementation
philosophy.

             Carl Love



On Wed, 2008-03-05 at 15:39 -0800, Geoff Levand wrote:
> On 03/05/2008 08:38 AM, Carl Love wrote:
> > Can you give an overview of what the ps3-lpm module does?  What happens
> > when ps3-lpm.c is remmodded?  I guess I need to understand what the
> > module does so I can figure out what impact it has on OProfile.  I
> > understand the processor architecture but I am not at all familiar with
> > the PS3 system as a whole.
> 
> ps3-lpm is the driver for the PS3's Logical Performance Monitor.  I
> think you can get a good idea of it by looking at the driver's source
> code:
> 
>   http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=blob;f=drivers/ps3/ps3-lpm.c;hb=HEAD
> 
> -Geoff
> 
> 




More information about the cbe-oss-dev mailing list