]> Cypherpunks repositories - gostls13.git/commit
cmd/link: grow rdBuf lazily
authorShahar Kohanim <skohanim@gmail.com>
Mon, 4 Apr 2016 19:36:43 +0000 (22:36 +0300)
committerShahar Kohanim <skohanim@gmail.com>
Mon, 4 Apr 2016 21:22:44 +0000 (21:22 +0000)
commitbc942823069fd004166360164e13821ded38f11c
treeecb95e45167a229a6e874c473a70a3cb4d6bc9f4
parenta9ea36afbbf39555b7a215651535f0eef89db37c
cmd/link: grow rdBuf lazily

Counting the final buffer size usually doesn't result in the buffer growing,
so assume that it doesn't need to grow and only grow if necessary.

name       old secs    new secs    delta
LinkCmdGo   0.49 ± 4%   0.48 ± 3%  -1.31%   (p=0.000 n=95+95)

name       old MaxRSS  new MaxRSS  delta
LinkCmdGo   122k ± 4%   121k ± 5%    ~     (p=0.065 n=96+100)

Change-Id: I85e7f5688a61ef5ef2b1b7afe56507e71c5bd5b1
Reviewed-on: https://go-review.googlesource.com/21509
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Shahar Kohanim <skohanim@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: David Crawshaw <crawshaw@golang.org>
src/cmd/link/internal/ld/objfile.go