User forums > Using Code::Blocks

High CPU usage

<< < (2/11) > >>

rickg22:
you're constantly debugging and setpping into your app, right?

Anonymous:
no... not debugging at all.

Anonymous:
ok, I've done some more testing, this time altering code, compiling and debugging, and then letting it idle for 5-10 minutes. The results are as follows:

no plugins: 0-1%
compiler + gdb: 3-5%
compiler + gdb + code completion w/caching: 3-6%
compiler + gdb + code completion wo/caching: 4-8%
all plugins: 7-10%

I've also found that simply moving the mouse over codeblocks, raises cpu usage to 20-70% depending on mouse speed. This is regardless of whether codeblocks has focus or not.

rickg22:
hmmmmmmm interesting. Hadn't noticed. I guess this is part of the events management (wxWidgets).

thomas:
Hmm... cannot confirm that observation.

System: Athlon64 3400 / 1G / WinXP SP2 /c::b 1.0finalbeta

2 Projects loaded, 6 files open, all plugins loaded, no Debugger, idle:
Total CPU 2%,
taskmgr.exe 1%    <--- that's where my cpu goes :)
svchost.exe 1%     <---
codeblocks.exe  0%

same, but moving Mouse up and down over project manager:
codeblocks.exe 18%   (quite clear why that has to be)

frenzily moving Mouse over editor window:
codeblocks.exe 24%   (quite clear, too)

compiling project:
cc1.exe 99%  (well, duh :-)  )

debugging app that is blocking in a syscall (getchar):
codeblocks.exe 0%
app.exe 0%

debugging app that runs in a tight infinite loop with a watch:
codeblocks.exe 5%
app.exe 95%

This looks quite normal to me, does it not?

EDIT:
Forgot about the "moving mouse thing":
Moving the mouse fires a lot of events and requires calculations like "do tooltips have to be popped up?" and "do I need to change a button's outline?" or "is some plugin maybe involved?", so quite clearly this takes cpu.
I can get Windows Explorer to use 3-4% cpu by moving the mouse, too, and Explorer does quite a lot less than an IDE.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version