News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

CPU usage when idle.

Started by orefa, September 23, 2005, 11:37:33 PM

Previous topic - Next topic

orefa

Curious... I just noticed in Windows task manager that CB uses up a little bit of CPU time even when it's not in use. A workspace with two projects are open, but no compilation nor editing is happening, yet task manager shows fluctuating percentages of CPU time between 2% and 8% on my system. That's quite a bit for an unused application. A background thread must be active. What is it doing?

thomas

OnIdle.
It is a known issue that has been adressed here: http://forums.next.codeblocks.org/index.php/topic,467.0.html
Moving the mouse takes even higher amounts of CPU, up to 30-40%. If you profile Code::Blocks, you see it spends almost all that time inside the message dispatcher and the idle message handler.

There's a patch to remove most of that idle processing. Haven't looked at CVS lately since I've been away for a week and half, but I think Yiannis has fixed it in CVS, too.
"We should forget about small efficiencies, say about 97% of the time: Premature quotation is the root of public humiliation."

orefa