Log in

View Full Version : W32Dasm FIX CPU usage


Lekara
September 21st, 2004, 16:52
When I open a file in W32dasm and do nothing , the cpu goes 100% (2.0 GHz) , but when the menu is opened it is 3% (normal).

There must be some loop going on that is useless .

Q: 1.How to find that loop in O.D. ?
2.How to set break point ?

Eto hvala!

[email=][/pivoosjecko@yahoo.com]

jayte
September 21st, 2004, 19:05
My guess, is that he (the program's author) is basically polling for Windows messages using PeekMessage in his main message loop, instead of GetMessage (which doesn't return 'till there's a message).

Anyway... this is why (the 100% CPU usage) that particular technique is somewhat ill-advised.

As for your questions... find the address of the program's Winmain, and WndProc... have a look.

Jeff

JDog45
September 22nd, 2004, 01:38
ditto ^^^