• Brad Fitzpatrick's avatar
    net/http: parse Request-Line in a function, remove an allocation · 7e7f8993
    Brad Fitzpatrick authored
    Removes another per-request allocation. Also makes the code more
    readable, IMO. And more testable.
    
    benchmark                                   old ns/op    new ns/op    delta
    BenchmarkServerFakeConnWithKeepAliveLite        10539        10324   -2.04%
    
    benchmark                                  old allocs   new allocs    delta
    BenchmarkServerFakeConnWithKeepAliveLite           20           19   -5.00%
    
    benchmark                                   old bytes    new bytes    delta
    BenchmarkServerFakeConnWithKeepAliveLite         1609         1559   -3.11%
    
    R=golang-dev, gri
    CC=golang-dev
    https://golang.org/cl/8118044
    7e7f8993
Name
Last commit
Last update
api Loading commit data...
doc Loading commit data...
include Loading commit data...
lib Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.hgignore Loading commit data...
.hgtags Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...