Why doesn't the OS use all my CPU?

I'm running a fairly resource intensive program. My machine has two processors. It runs Mac OS X. My program is doing multiprocessing using OpenMP. If I look in top/htop, it IS using more than 100%, but it is usually around 130%. If I add up the top few numbers, the sum is nowhere near 200%. Why doesn't my program use the rest? Or is the rest being used implicitly somewhere?

Thanks!
Without knowing the program in question, one can still at least say that the threads are waiting for something part of the time - most likely for a lock to be freed or for I/O operations to complete.
any process using 100% of total cpu is usually a sign of trouble.

remember the OS is working away underneath, daemons, services, the screen needs to be drawn,
disks handled, memory shuffled about
etc.
Last edited on
Ok, but that's what I'm saying. I know the OS needs a bunch of CPU. But that would show up in top as Xorg, or HAL, or DBUS, or whatever. But the SUM of all the things doesn't add up to 200%.
Topic archived. No new replies allowed.