• Brad Fitzpatrick's avatar
    bufio: reuse Writer buffers after Flush · 99f67228
    Brad Fitzpatrick authored
    A bufio.Writer.Flush marks the usual end of a Writer's
    life. Recycle its internal buffer on those explicit flushes,
    but not on normal, as-needed internal flushes.
    
    benchmark               old ns/op    new ns/op    delta
    BenchmarkWriterEmpty         1959          727  -62.89%
    
    benchmark              old allocs   new allocs    delta
    BenchmarkWriterEmpty            2            1  -50.00%
    
    benchmark               old bytes    new bytes    delta
    BenchmarkWriterEmpty         4215           83  -98.03%
    
    R=gri, iant
    CC=gobot, golang-dev, voidlogic7
    https://golang.org/cl/9459044
    99f67228
Name
Last commit
Last update
..
cmd Loading commit data...
lib9 Loading commit data...
libbio Loading commit data...
libmach Loading commit data...
pkg Loading commit data...
Make.dist Loading commit data...
all.bash Loading commit data...
all.bat Loading commit data...
all.rc Loading commit data...
clean.bash Loading commit data...
clean.bat Loading commit data...
clean.rc Loading commit data...
make.bash Loading commit data...
make.bat Loading commit data...
make.rc Loading commit data...
race.bash Loading commit data...
race.bat Loading commit data...
run.bash Loading commit data...
run.bat Loading commit data...
run.rc Loading commit data...
sudo.bash Loading commit data...