I need a good tool for analysing CPU... - Windows Mobile Development and Hacking General

I need a good tool for analysing CPU on WM devices, that doesn't consume too much itself and i s able to show details about the threads running etc...
Would appreciate any suggestions you might have.
Esp, one that might automatically record the output to a file...
Thanks in advance!

Related

Uni speed and ROMs

We use the Universal for speech systems for people with disabilities. However the speed of the device is marginal for us, because the system itself uses a massive (30%+) fraction of the processor time even when the system is at idle.
I've just been asked if using any alternate ROM images might help speed the device up much, and I haven't got a clue. Help!
Does anyone know if any of the ROM images that are out there makes a significant difference to the speed of the universal? Is there a ROM image around which completely removes all phone functionality (not all our users use the phone)?
I'd be very grateful for any guidance, before we start trying ROM images at random...
Stuart
Hello, first of all, -and I'm not sure about this- I think that the ROMs images are not available at this site's FTP anymore.
Then, if you can have a ROM, prefer the "plain vanilla" ones, unless you might need several extra programs, if you need speed, you need a light and simple ROM, there are several of them, from Helmi's, to Ivan's and others that I just can't remember now, look out in the posts and find a stable one to use, test it with your app until you think is the right one.
Alternatively you can increase your CPU's clock, but this drains the battery faster, a solution for this might be to install a larger battery, your use of the uni might permit all of these things.
I haven't tested any custom ROMs, but I have a friend with a uni that has installed in its uni a Helmi's ROM, I saw it, it seems quite speedier than my T-mobile one, he told me that the voice tags call fuction didn't work and something else, but, was it faster indeed.
bye
stuartaw said:
We use the Universal for speech systems for people with disabilities. However the speed of the device is marginal for us, because the system itself uses a massive (30%+) fraction of the processor time even when the system is at idle.
I've just been asked if using any alternate ROM images might help speed the device up much, and I haven't got a clue. Help!
Does anyone know if any of the ROM images that are out there makes a significant difference to the speed of the universal? Is there a ROM image around which completely removes all phone functionality (not all our users use the phone)?
I'd be very grateful for any guidance, before we start trying ROM images at random...
Stuart
Click to expand...
Click to collapse
have you tried to kill useless proggy at startup???
if you want i may be able to make a clean rom for you...
actually try increasing the pagingpool a simple hexedit on existing roms (wm6 section of this forum look for helmi's kitchen)
Thanks for the suggestions so far.
fallenczar said:
have you tried to kill useless proggy at startup???
Click to expand...
Click to collapse
I've tried killing everything I can. The processor is occupied by one thread within devices.exe; and I can't really kill that process... Everything else had minimal/no impact.
Stuart
What application are you using to identify process usage? 30% sounds very high to me.
PaulMdx said:
What application are you using to identify process usage? 30% sounds very high to me.
Click to expand...
Click to collapse
The remote tools in Visual Studio. Shows 1%-4% processor usage at idle for other PDAs, 30-35% for TyTN and Universal (the only 2 HTC machines I had access to). I used the kernel tracker thing to track execution, and it was one particular thread in devices.exe which was both busy, and also, sometimes, thrashing around at <100 micro-s frequency.
This figure does fit with our other experiences. The particular speed problem we have is with a library which is spec-ed to work on any machine with 400Mhz+ processor. Works fine on other machines, including some quite old PDAs, but has 'issues' due to slow processor on the Universal and is simply unusable on the TyTN.
I couldn't find anything I could do to improve this in RAM - and a colleague asked if any of the alternate ROMs might help - and I've haven't got a clue, but hoped someone might know if any of the ROMs are visibly faster.
Stuart
Have you tried changing the default clock speed?
Hi Stuart,
I think there are a lot of applications out there which allow you to overclock and change the clock speed of Xscale CPU's. Things like XCPUScalar 2007. If you look at this thread(http://forum.xda-developers.com/showthread.php?t=304786)you should be able to find some useful information regarding scaling the CPU speed, hope this helps.
Will.

fieldtest users: need help!

Hi, I'm developping a sublayer to abstract the way the developpers use CellID, and the methods to get the datas from different devices.
I reverse engineered fieldtest.exe and would like to test it. I contacted some of you, and none gave me the informations I was needing. The problem is: I think I have the correct request, but don't know what kind of structure it is. If you could provide a screenshot, it would be a great help to quickly identify the structure.
I don't have a Hermes, and I cannot try it by myself.
Could you please test this in debug version (D and not R)
http://usuc.dyndns.org/tv/gsm/gsmcelluloz/
Here you'll see the result (maps of signals per cellid)
http://usuc.dyndns.org/tv/gsm/
Thanks to send me the \Temp\gsmcelluloz.txt files (stop it after a minute, could quickly become very big!) to: [email protected]
This way, you'll be able to use a DLL to get cellid which will work on many devices, because it uses COM port method, GSMTestMode method, offset method and soon (I hope) fieldtest method.
I will try it when get home, so i can run a backup in case the worst happens and i need to hard reset
It's just an application, it won't brick your device
Anyway, It reminds me to make one.... It's always useful to have a recent backup...
It will show only "0" for now, because I don't have the gsmcelluloz_log.txt files made on HERMES to understand how the answer looks like. But shortly after I'll have those files, it will show the real values.
Please add a fieldtest screenshot to help me identify the fields
Thanks
i've mailed you the log file and the screen shot.
Here are my logs. Hope it helps.

XDA new OS

Hi
ok heres my idea
we takes a htc hermes and fully wipe all the memory, radio gsmrom and os roms and rewrite the partition table so all we have is a ipl and spl roms left
then we customise a spl for efficiency and to remove the radio functions and any unneeded functions
then we write a new base kernel that is original and lightweight using nesscary drivers from linux source tree if we need them then to create a lightweight enviroment from the ground up with the ablity to run wince applications and linux applications and then my plan is too either turn it into a gaming / video / camera
ok questions
why?
it is mainly to show it can be done
but also i have a htc hermes and htc universal and i always use the universal
so i dont want to use the hermes for phone usage, but it would be good to have a gaming console off of it or video player because it would make the battery last longer and i find that playing games and wtching videos on wince is often slow and jumpy and this way we can access the raw power of the pda
do the experts on these fourms think this is possible?
i know it will be a long and tedious task but i think it will provide a better replacement then linux ontop of windows ce
i do have a fair bit of kernel and bootloader experience and am ok with asm learning ARM shouldnt be too hard, and im a CS student with plenty of free time
so what do you guys think?
i will be making a more detailed specification over the next week this is jsut for opinuon and feed back
Lloyd
lloydsparkes said:
Hi
ok heres my idea...
Click to expand...
Click to collapse
I don't think it would work... The full ROM image is in 3 parts, at the very least, the radio ROM itself is stored on the PGA that handles the hardware - so doesn't affect the base OS anyway so nothing to gain by going near that.
I guess, in theory, if you _really_ knew what you were doing you could write yourself a new OS part assuming you'd worked out the hardware addressing for all the bits you would want to use/need to use in your OS.
I think the project to try and get Linux running on Hermes a while ago sorted some of this stuff out...
See this thread and this wiki page
Certainly the wiki page has some extremely useful info should such a kernel rewrite be attempted.
HTH and good luck!
ok kool thanks
i have plenty of spare time so i will research it alot more my only resaon for wnating to touch the radio rom is to get more memory but kool thanks

Qualcomm QPST Memory Debug Application

Hi all
I have an Xperia X2, and was able to use the Qualcomm QPST Memory Debug Application to take a dump of the memory contents (11 files, mostly .bin and .cmm files, total size about 160MB).
Does anyone know how to interrogate these files offline? Any help would be greatly appreciated.
Thanks in advance
Neil
http://www.qualcomm.com/blog/2010/05/07/android-debugging-using-lauterbach-trace32-software
The otherway is analyze in editor of choice. Quacomm make the chips so too, they make the tiols :-B
This post is quite old now, perhaps you have some things to add to your thread now it's quite highly ranked in Google? I always liked petools and there are some unrelated sysinternals apps that are useful.. Maybe..
What I would love is Numega Softice to attaxh so much better than trying to use debug to rewrite registers - lol.. Takes me back to my childhood.. Shame softice was dropped.. Such an excellent app! The ultimate

[Q] What debug and log tools are available?

Hi,
I'm interested to know which debugging/logging tools are available.
I'd like to get more information about the processes at startup, and specially logs of the CPU usage by each application over a period of time.
I've been searching for some time and the only I've found are the old Htc Test applications, but can't get what I want.
Noted that HTC devices have a builtin debug tool (debuglog.dll). Anyone knows how to use it?
Also found the following the following post describing the HTCDiagDriver and the possibility to analyze the device using QUALCOMM eXtensible Diagnostic Monitor.
http://forum.xda-developers.com/showpost.php?p=12624471&postcount=2
Anyone uses it?
Global debuglog can be enabled via DebugTool.exe (available in Htc Test Applications). It depends on debuglog.dll, yeah. Read manual, it works quite well.
Then, if you want to get log for selected app, launch it via IDA.
Also we have CeLog available, I will post needed launchers soon. I can hardly call it useful as we have retail/ship SYS builds. The only useful purpose for us is page faults chart.
EDIT: CeLog attached.
Some of the builds come with the Perfman package. That s.o.b. will really slow down your device, though, and it creates a massive log file, which I could never find the tools to analyze. I think celog does it, though, which is pretty sweet.
The htc debugger works better. You just change one of the debug flags and reset, and the device starts writing the log file. It doesn't slow down the device nearly as much as perfman. I think celog may work on that log file, too. You can royally eff up your device with that tool, though, if you mess with the radio flags. It's pretty cool how it writes to flash memory. Too bad you can't change other things with it like the page pool size.
ultrashot said:
Also we have CeLog available, I will post needed launchers soon. I can hardly call it useful as we have retail/ship SYS builds. The only useful purpose for us is page faults chart.
EDIT: CeLog attached.
Click to expand...
Click to collapse
I have been playing with the tool on my Tornado and observed the following (usage related):
Use it while the device is disconnected from PC. The overhead of repllog.exe (connected to ActiveSync on XP PC) and syncing is just filling your log. For my installation (no further MS Mobile development tools on the PC) kerneltracker.exe does not connect to the device anyway.
Though obvious, the files CeLog*.exe have to run on the device, so copy them to a convenient place there.
The CeLogAttach.exe seems to start the kernel logging and it slows down the device (kind of obvious). There is no way to stop this logging. Something like CeLogDetach would be needed, if it exists, to restore the state before CeLogAttach.exe was run.
The CeLogFlush.exe will flush the existing log but also immediately start the logging again.
The CeLogStopFlush.exe does just what the name tells - it stops the flush to file of the (still ongoing) logging.
After transfering the celog.clg file (from \Release\ directory of the device) it can be opened in kerneltracker.exe. Then you see all the kernelactivities logged and aligned per process/thread on a zoom-able timeline (10ms - 10s) including the labels of the logged primitives. With event filtering you can sort out what you are not interested in. Here you may need advice on what to look after when you want to hunt down a certain device behaviour.
I have checked for page-faults, Virtual Memory related actions (Allocate, Copy, Free) and also Module actions (load, free) to get a clue if and how modules and paging (or better said: the use of the Page-Pool) is correlated. Nothing eye-striking coming up here, but it may just be for the unknowing observer like myself.
@ultrashot: I could not find anything I would call a "page faults chart" - where is that - or what is that?
Looking further: If I change certain device properties (like increase the pagepool or playing with OSB advanced options) I fear that the logged information here is just far too detailed for a useful compare. For that you would have to create identical conditions for the action under scrutiny - something that cannot be done with a disconnected device.
So I have to admit that all objective compare of such tuning and tweaking is far above my head and I just have to join the many that make more or less clever assumptions trusting on their model of actions in their heads. I hope that the better knowing heads continue to spread their wisdom without only telling RTFM or guide with LMGTFY (which can help if the results really point to right places).
tobbbie said:
@ultrashot: I could not find anything I would call a "page faults chart" - where is that - or what is that?
Click to expand...
Click to collapse
Use Event filter->Miscellaneous->Page fault.
I am not too advanced user of this tool. If we had builds with extra celog instrumentation, we could have take much more from this tool. However, there are some articles in the internets about celog, so anyone who wants to be get more info may just try to google it. I don't want
ultrashot said:
Use Event filter->Miscellaneous->Page fault.
Click to expand...
Click to collapse
That is what I did already when telling about the items I cared below. Page faults are however part of generic virtual memory management and they do also apply for any normal loaded executables. As you know I seek for traces of module related paging and the use of the page-pool.
So it will stay with the trial and error and side-by-side compare with two devices having different settings. Not a big thing doing that...
Some interesting articles on MSDN regarding the paging pool (aka "pagepool"):
Kernel Blog article explaining the fundamentals (highly recommended): http://blogs.msdn.com/b/ce_base/archive/2008/01/19/paging-and-the-windows-ce-paging-pool.aspx
Pagepool Variable explained and simple methods to measure impact: http://msdn.microsoft.com/en-us/library/aa451041.aspx
-> this is what kitchentools are patching in the kernel
Then some more backup on virtual memory - just to complete on that:
http://blogs.msdn.com/b/ce_base/archive/2006/10/30/what-is-virtual-memory.aspx
http://blogs.msdn.com/b/hegenderfer/archive/2007/08/31/slaying-the-virtual-memory-monster.aspx
http://blogs.msdn.com/b/hegenderfer...aying-the-virtual-memory-monster-part-ii.aspx
And to get back to the debug tools topic of this thread, linked form the first article an introduction to the Remote Kernel Tracker to explain what you can actually see there (and why you cannot see certain things as we have shipped ROM builds and not profiling builds to deal with): http://blogs.msdn.com/b/sloh/archive/2005/05/17/introduction-to-remote-kernel-tracker.aspx
Great insight if you want to get a glimpse of how Windows CE operates under the hood.
...reading a little deeper in the MSDN articles, Sue Loh mentions there when talking about the paging pool size determination:
The best tool I know is that readlog.exe will print you a page fault report if you turn on the “verbose” and “summary” options. If you get multiple faults on the same pages, your pool may be too small (you may also be unloading and re-loading the same module, ejecting its pages from memory, so look for module load events in the log too). If you don’t get many repeats, your pool may be bigger than you need.
Click to expand...
Click to collapse
To avoid dealing with a full setup of the Mobile Development toolsets, could any one (ultrashot - you have been so helpful - could you??) post that mentioned "readlog" tool? If there is something like "CeLogDetach.exe", please add it too.
BTW: you may notice that the paging pool is a central part of the Windows CE memory management when it comes to running executable code from "memory mapped files" (as Sue Loh calls them). In my understanding these are simply what we know as "modules".
A lot of tweaking strategies go around that when building ROMs with OSBuilder. There are several ways how to avoid or optimize the use of the paging pool for certain or all modules in OSB. I think these options deserve an own thread and I am not sure if the one OSB thread we have should be cluttered with discussing this.
don't have any of those.

Categories

Resources