Hello,
I've just finished a simple tutorial showing how to profile code on PSP, using both gprof and hardware profiler. Feel free to check it and comment.
This is my first such "publication" so please be tolerant.
http://zytek.nuxi.pl/psp/pspprofilingV1.pdf
I've msg oobles so he could put it into Tutorial section of ps2dev.org
new psp profiling tutorial
Nice,
One thing though you might be interested in, if you are running psplinkusb you can use the command profmode with either g or t option to specify global or thread profiler. In that mode you can access the profiler registers from user mode, no need to ever be in kernel mode to do it and as a bonus if you set thread mode it will actually context switch the registers so you only get a count of what that thread is doing.
Once you have enabled either mode (and done a psplink reset) then in your code you can call sceKernelReferThreadProfiler or sceKernelReferGlobalProfiler to get a pointer to the registers.
One thing though you might be interested in, if you are running psplinkusb you can use the command profmode with either g or t option to specify global or thread profiler. In that mode you can access the profiler registers from user mode, no need to ever be in kernel mode to do it and as a bonus if you set thread mode it will actually context switch the registers so you only get a count of what that thread is doing.
Once you have enabled either mode (and done a psplink reset) then in your code you can call sceKernelReferThreadProfiler or sceKernelReferGlobalProfiler to get a pointer to the registers.
Thanks zytek,
Very neat.
One question, could you possibly make this available as a plain text file.
Love the PDF, but when I have the most time to read, I only have a PSP.
Thanks TyRaNiDe (pronounced like cyanide),
How big you can hack a very small machine! ;)
Now I've finally go to try psplink again.
A lot of the time I'm using the serial port myself,
but I've underestimated it's advantage.
Art.
Very neat.
One question, could you possibly make this available as a plain text file.
Love the PDF, but when I have the most time to read, I only have a PSP.
Thanks TyRaNiDe (pronounced like cyanide),
How big you can hack a very small machine! ;)
Now I've finally go to try psplink again.
A lot of the time I'm using the serial port myself,
but I've underestimated it's advantage.
Art.
If not actually, then potentially.