Click to search Andy Jarrett.co.uk RSS feed

Loading Twitter

Max your CPU

I was at the Apple store yesterday with the need to run both my CPU's at max for some tests. The "Genius" put the following in two separate Terminal windows
Yes > /dev/null

The YES commandsimply sends an endless stream of y’s to standard output until killed. The reason the guy did it twice is to ensure that both CPU's are being used. This should work on any *nix machine but if you only have 1 CPU you only need to do it once

If are even to lazy to open two windows you can just put the following in one:
Yes > /dev/null & Yes > /dev/null

Comments Comments (1) | Print Print | Send Send | 279 Views

(Comment Moderation is enabled. Your comment will not appear until approved.)
Heh that's a pretty neat little trick, I wonder why you have to do it twice for it consume both CPUs you would think that just the once would consume all available processing power on the entire system, that logic would suggest that any one application thread can only ever consume a maximum 1 CPU's power?

Interesting.

Rob
BlogCFC by Raymond Camden + Twitter @AndyJ + ColdFusion jobs + Contact Me + Snippets/Downloads + RSS .