[H-GEN] Hyperthreading and CPU utilisation
Anthony Towns
aj at azure.humbug.org.au
Mon Aug 25 01:07:21 EDT 2003
On Mon, Aug 25, 2003 at 02:07:05PM +1000, Michael Anthon wrote:
> top - 13:41:42 up 6 days, 3:29, 6 users, load average: 0.45, 0.18,
> 0.40
> Tasks: 246 total, 2 running, 244 sleeping, 0 stopped, 0 zombie
> Cpu0 : 0.3% user, 0.0% system, 0.0% nice, 99.7% idle
> Cpu1 : 0.3% user, 3.6% system, 0.0% nice, 96.1% idle
> Cpu2 : 0.7% user, 0.0% system, 0.0% nice, 99.3% idle
> Cpu3 : 23.9% user, 76.1% system, 0.0% nice, 0.0% idle
^^^^^ ^^^^^
23.9 + 76.1 adds up to 100 in my book.
> PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
> 25073 root 18 0 328 328 272 R 99.9 0.0 0:33.50 cat
And that's reasonable if you're using cat to generate load, which is
limited by its read() and write() calls.
> Now, perhaps I am totally misunderstanding HT but is this truly going to
> utilise only 50% of the CPU's capacity when only running a single active
> process?
HT breaks each processor into two virtual processors, which depending
on load can *both* be as effective as one real processor. Linux treats
each virtual CPU almost the same as a real CPU on regular SMP, except to
not worry about switching tasks between virtual CPUs on the same real CPU.
> I guess what I am trying to understand is if this is giving me
> a true understanding of system preformance
It's not really, no. That's not really what top's aim is, though, either.
You'll need to be running four or five processes at once to get any real
idea of what's going on.
Cheers,
aj
--
Anthony Towns <aj at humbug.org.au> <http://azure.humbug.org.au/~aj/>
I don't speak for anyone save myself. GPG signed mail preferred.
``Is this some kind of psych test?
Am I getting paid for this?''
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 307 bytes
Desc: not available
URL: <http://lists.humbug.org.au/pipermail/general/attachments/20030825/de036d29/attachment.sig>
More information about the General
mailing list