SPARC64 context switching oddities

Peter Jeremy peter.jeremy at alcatel-lucent.com
Thu Jun 23 06:04:39 UTC 2011


I have a tool that measures the rate at which a single-byte token can
be passed between two processes via a socketpair and have been running
multiple copies of it on an otherwise idle V890 (16-CPU, 64GB RAM
running -current from about a week ago), capturing 'vmstat -s' output.
In the process, I have found several oddities:

1) The number of context switches doesn't match my expectations.
See http://i.imgur.com/TyU3j.jpg
It starts out unexpectedly high (~184k switches/sec) and then drops to
an unrealistically low value as the number of processes increases from
1 to about 20 pairs.  It then very slowly increases.  Based on one
process writing a token to a second process requiring one context
switch, I would expect the number of context switches to roughly match
the green (based on token passing rate) or blue (based on syscall
rate) lines.

2) The transfer rate dips initially then rises to a peak before tailing off.
See http://i.imgur.com/zVcfu.jpg and http://i.imgur.com/DhMmV.jpg
The red line shows the rate reported by the program and the green line
shows the rate estimated from the syscall rate.  I would expect a fairly
flat peak from 1 to about 16 pairs (since there are 16 execution threads
available) that then tailed off as scheduler overheads increased

Can anyone offer an explanation for this behaviour?

-- 
Peter Jeremy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-sparc64/attachments/20110623/e6b238a6/attachment.pgp


More information about the freebsd-sparc64 mailing list