• Russ Cox's avatar
    runtime: parallelize garbage collector mark + sweep · d324f214
    Russ Cox authored
    Running test/garbage/parser.out.
    
    On a 4-core Lenovo X201s (Linux):
    31.12u 0.60s 31.74r 	 1 cpu, no atomics
    32.27u 0.58s 32.86r 	 1 cpu, atomic instructions
    33.04u 0.83s 27.47r 	 2 cpu
    
    On a 16-core Xeon (Linux):
    33.08u 0.65s 33.80r 	 1 cpu, no atomics
    34.87u 1.12s 29.60r 	 2 cpu
    36.00u 1.87s 28.43r 	 3 cpu
    36.46u 2.34s 27.10r 	 4 cpu
    38.28u 3.85s 26.92r 	 5 cpu
    37.72u 5.25s 26.73r	 6 cpu
    39.63u 7.11s 26.95r	 7 cpu
    39.67u 8.10s 26.68r	 8 cpu
    
    On a 2-core MacBook Pro Core 2 Duo 2.26 (circa 2009, MacBookPro5,5):
    39.43u 1.45s 41.27r 	 1 cpu, no atomics
    43.98u 2.95s 38.69r 	 2 cpu
    
    On a 2-core Mac Mini Core 2 Duo 1.83 (circa 2008; Macmini2,1):
    48.81u 2.12s 51.76r 	 1 cpu, no atomics
    57.15u 4.72s 51.54r 	 2 cpu
    
    The handoff algorithm is really only good for two cores.
    Beyond that we will need to so something more sophisticated,
    like have each core hand off to the next one, around a circle.
    Even so, the code is a good checkpoint; for now we'll limit the
    number of gc procs to at most 2.
    
    R=dvyukov
    CC=golang-dev
    https://golang.org/cl/4641082
    d324f214
Name
Last commit
Last update
..
archive Loading commit data...
asn1 Loading commit data...
big Loading commit data...
bufio Loading commit data...
builtin Loading commit data...
bytes Loading commit data...
cmath Loading commit data...
compress Loading commit data...
container Loading commit data...
crypto Loading commit data...
csv Loading commit data...
debug Loading commit data...
ebnf Loading commit data...
encoding Loading commit data...
exec Loading commit data...
exp Loading commit data...
expvar Loading commit data...
flag Loading commit data...
fmt Loading commit data...
go Loading commit data...
gob Loading commit data...
hash Loading commit data...
html Loading commit data...
http Loading commit data...
image Loading commit data...
index/suffixarray Loading commit data...
io Loading commit data...
json Loading commit data...
log Loading commit data...
mail Loading commit data...
math Loading commit data...
mime Loading commit data...
net Loading commit data...
netchan Loading commit data...
old Loading commit data...
os Loading commit data...
patch Loading commit data...
path Loading commit data...
rand Loading commit data...
reflect Loading commit data...
regexp Loading commit data...
rpc Loading commit data...
runtime Loading commit data...
scanner Loading commit data...
smtp Loading commit data...
sort Loading commit data...
strconv Loading commit data...
strings Loading commit data...
sync Loading commit data...
syscall Loading commit data...
syslog Loading commit data...
tabwriter Loading commit data...
template Loading commit data...
testing Loading commit data...
time Loading commit data...
try Loading commit data...
unicode Loading commit data...
unsafe Loading commit data...
url Loading commit data...
utf16 Loading commit data...
utf8 Loading commit data...
websocket Loading commit data...
xml Loading commit data...
Makefile Loading commit data...
deps.bash Loading commit data...