in reply to Threads Mac Os x

What percent of cpu usage do you see on the Mac using "top"?

If you have an 8 core machine in one cpu it may manifest itself as a single cpu in "top" but running at 800% (if all threads are taking up 100% of each core)

Replies are listed 'Best First'.
Re^2: Threads Mac Os x
by vinay052003 (Initiate) on Feb 27, 2011 at 02:35 UTC
    I see CPU usage around 100% only. If all the CPUs were being used then I would've seen something like 700% or or higher. When I "top" I see the following: PID COMMAND %CPU TIME #TH 7867 perl5.10.0 96.6 26:15:19 8/6 (where #TH: total number of threas/number of running threads)
      When I "top" I see the following:
      PID COMMAND %CPU TIME #TH 7867 perl5.10.0 96.6 26:15:19 8/6
      (where #TH: total number of threas/number of running threads)

      I would interpret that to mean that at the moment in time when you ran the command, 6 of your 8 threads were running concurrently, and between them they were using 96% of your total cpu capacity.

      In other words, if you have a single threaded process running flat out on a single core, I would expect the highest %cpu value shown to be 100/8 = 12.5%.

      The fact that at the instance that the command ran, only 6 of 8 threads was actually using a core, just means that in that brief instance, some other higher priority processes--like your display driver, or your network driver, or your disk driver--needed to do something.


      Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
      "Science is about questioning the status quo. Questioning authority".
      In the absence of evidence, opinion is indistinguishable from prejudice.
        I guess that makes sense. I really appreciate your help guys. Thanks.