Re: measuring performance on multiprocessor system
From: sinister (sinister_at_nospam.invalid)
Date: 12/02/04
- Previous message: Nathan Dietsch: "Re: measuring performance on multiprocessor system"
- In reply to: Dave: "Re: measuring performance on multiprocessor system"
- Next in thread: sinister: "Re: measuring performance on multiprocessor system"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Thu, 02 Dec 2004 12:27:49 GMT
"Dave" <nospam@nowhere.com> wrote in message news:41ad9b31@212.67.96.135...
> Nathan Dietsch wrote:
>
>> First, don't use top on newer Solaris versions like 9, use prstat instead
>> as Michael said. Pete also noted that mpstat would be good, this command
>> will give you the figures for all of your CPUs, rather than an average.
>
>
> I was thinking this was true at one point, but I'm running Solaris 9 on a
> quad processor system, and after checking with prstat some time back, just
> about everything agreed. Below is some data.
Thanks for posting this illuminating example.
>> Second, I don't understand why it gave 12%.
>> Top shows the CPU% as a percentage of all available CPUs (100% for
>> all)[0]. So a single-threaded app can only use one CPU, so 100/12 should
>> be ~8%. Are you sure that you have 12 processors which are online in the
>> machine? psrinfo will give you that information.
>
> Parts of Matlab are threaded, and so do use multiple processors. I'm
My impression from a google search is that Matlab itself is single-threaded,
but it calls on multithreaded libraries.
> not a proficient user of Matlab (much prefer Mathematica myself). However,
> I just inverted a 10000x10000 matrix in Matlab version 6.5, release 13 and
> found it was using 47% of my CPU time according to both prstat. I'm using
> a quad processor Sun Ultra 80.
>
>
> Here's the prstat output.
>
> sparrow /export/home/drkirkby % prstat
> PID USERNAME SIZE RSS STATE PRI NICE TIME CPU PROCESS/NLWP
> 2219 drkirkby 1750M 1654M cpu2 20 0 0:18:51 55% matlab/27
> 1789 drkirkby 71M 57M sleep 49 0 0:04:55 1.8% mozilla-bin/5
> 19061 root 148M 52M sleep 59 0 1:07:02 0.9% Xsun/1
> 2306 drkirkby 2848K 1736K sleep 49 0 0:00:02 0.1% top/1
> 2310 drkirkby 4624K 4368K sleep 49 0 0:00:00 0.1% prstat/1
> 2320 drkirkby 4624K 4368K cpu0 59 0 0:00:00 0.1% prstat/1
> 19370 drkirkby 17M 13M sleep 49 0 0:14:48 0.0% sunpcbinary/3
> 28119 drkirkby 7032K 4672K sleep 59 0 0:00:00 0.0% dtterm/1
> 336 root 1744K 88K sleep 59 0 0:00:00 0.0% smcboot/1
> 319 root 1064K 504K sleep 59 0 0:00:17 0.0% utmpd/1
> 337 root 1744K 88K sleep 59 0 0:00:00 0.0% smcboot/1
> 307 nobody 0K 0K zombie 0 - 0:00:00 0.0% /0
> 19182 drkirkby 7288K 3560K sleep 49 0 0:00:01 0.0% dtterm/1
> 306 nobody 1080K 96K sleep 59 0 0:00:00 0.0% lic_logger.sh/1
> 335 root 1744K 176K sleep 59 0 0:00:00 0.0% smcboot/1
> 286 root 3152K 184K sleep 59 0 0:00:00 0.0% lpsched/1
> 280 root 3896K 2584K sleep 59 0 0:00:57 0.0% nscd/23
> 19144 drkirkby 7032K 904K sleep 49 0 0:00:00 0.0% dtterm/1
> 264 root 2304K 704K sleep 59 0 0:00:27 0.0% cron/1
> 19063 root 2400K 240K sleep 59 0 0:00:00 0.0% fbconsole/1
> 260 root 3816K 1480K sleep 59 0 0:43:29 0.0% syslogd/17
> Total: 109 processes, 203 lwps, load averages: 2.38, 1.86, 1.05
>
> and here's tho output from top.
>
> last pid: 2321; load averages: 2.38, 1.93, 1.11 10:17:22
> 109 processes: 106 sleeping, 1 zombie, 2 on cpu
> CPU states: 43.0% idle, 52.1% user, 4.9% kernel, 0.0% iowait, 0.0% swap
> Memory: 4096M real, 1441M free, 1835M swap in use, 2306M swap free
>
> PID USERNAME THR PRI NICE SIZE RES STATE TIME CPU COMMAND
> 2219 drkirkby 27 0 0 1751M 1655M cpu/2 20:15 54.45% matlab
> 1789 drkirkby 5 49 0 71M 57M sleep 4:58 1.26% mozilla-bin
> 19061 root 1 59 0 148M 52M sleep 67:04 1.04% Xsun
> 2321 drkirkby 1 59 0 2848K 1760K cpu/1 0:00 0.31% top
> 2306 drkirkby 1 49 0 2848K 1736K sleep 0:02 0.13% top
> 2310 drkirkby 1 49 0 4624K 4368K sleep 0:00 0.07% prstat
> 19143 drkirkby 5 49 0 9480K 6608K sleep 0:33 0.05% dtwm
> 19370 drkirkby 3 49 0 17M 13M sleep 14:48 0.05% sunpcbinary
> 28119 drkirkby 1 59 0 7040K 4680K sleep 0:00 0.04% dtterm
> 28121 drkirkby 1 59 0 3128K 2464K sleep 0:00 0.01% tcsh
> 280 root 23 59 0 3896K 2584K sleep 0:57 0.00% nscd
> 260 root 17 59 0 3816K 1480K sleep 43:29 0.00% syslogd
> 22237 root 1 59 0 2752K 952K sleep 2:05 0.00% nmbd
> 1 root 1 59 0 1248K 312K sleep 1:42 0.00% init
> 192 root 1 49 0 4400K 912K sleep 1:02 0.00% sendmail
> 264 root 1 59 0 2304K 704K sleep 0:27 0.00% cron
> 319 root 1 59 0 1064K 504K sleep 0:17 0.00% utmpd
> 28549 drkirkby 1 49 0 7088K 4728K sleep 0:08 0.00% dtterm
>
>
>> The 12% figure just does not make sense to me.
>
> It does I think.
>
> I suspect the problem is there are likely to be lots of users contending
> for the same 12 CPUs.
We have *lots* of users on our systems. But the number of processes that
use up lots of CPU resources (as shown by top, and where "lots" would be >
2%, say) is pretty small.
>
- Previous message: Nathan Dietsch: "Re: measuring performance on multiprocessor system"
- In reply to: Dave: "Re: measuring performance on multiprocessor system"
- Next in thread: sinister: "Re: measuring performance on multiprocessor system"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|