]> Cypherpunks repositories - gostls13.git/commit
cmd/link: re-use duplicate symbol object
authorMichael Hudson-Doyle <michael.hudson@canonical.com>
Mon, 21 Mar 2016 04:29:29 +0000 (17:29 +1300)
committerMichael Hudson-Doyle <michael.hudson@canonical.com>
Mon, 21 Mar 2016 07:48:30 +0000 (07:48 +0000)
commitb6fe2c2c20327d8f85581de848fe9687d4cc7c79
treef59840dbe2eb818ec732aca28b39f8c42088fac5
parente451c9025dc513cb2235c02c7683531e74e6aac4
cmd/link: re-use duplicate symbol object

Nothing cares about it.

I did this after looking at the memprof output, but it helps performance a bit:

name       old s/op    new s/op    delta
LinkCmdGo   0.44 ± 3%   0.43 ± 3%  -2.20%   (p=0.000 n=94+90)
LinkJuju    3.98 ± 5%   3.94 ± 5%  -1.19%  (p=0.000 n=100+91)

As well as MaxRSS (i.e. what /usr/bin/time -f '%M' prints):

name       old MaxRSS  new MaxRSS  delta
LinkCmdGo   130k ± 0%   120k ± 3%  -7.79%   (p=0.000 n=79+90)
LinkJuju    862k ± 6%   827k ± 8%  -4.01%  (p=0.000 n=100+99)

Change-Id: I6306b7b3369576a688659e2ecdb0815b4152ae96
Reviewed-on: https://go-review.googlesource.com/20972
Run-TryBot: Michael Hudson-Doyle <michael.hudson@canonical.com>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/cmd/link/internal/ld/objfile.go
src/cmd/link/internal/ld/sym.go