How to remove the cpu usage limit?

I have to run a C program on terminal as fast as possible. However, there seems to be a cpu usage limit for the terminal, the program supose to run around 15 seconds on a linux machine with similar configuration where cpu usage is at 85-95%. But, it runs one minute on my macbook pro with cpu usage less than 15%. Finally, my question is, how do I utilize all of the 85% idle cpu for this program or at least most of the idle cpu?

MacBook Pro, Mac OS X (10.7.3)

Posted on Apr 10, 2012 11:17 PM

Reply
2 replies

Apr 11, 2012 12:48 AM in response to JimmyZ1012

Per se, MacOS X does not impose any CPU usage limits other than those from the processor scheduling priorities. Standard Unix scheduling priorities go from -20 to +20, with the default being 0. If you have administrator privileges, you increase your process' priority (a more negative value) with the nice or renice commands. See their man pages. On a four-core 15" or 17" MBP, even setting max -20 priority should not impact the rest of the system too much.


You may also want to go over and discuss these things in the Unix forums:


https://discussions.apple.com/community/mac_os/mac_os_x_technologies

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

How to remove the cpu usage limit?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.