]> Cypherpunks repositories - gostls13.git/commit
[dev.link] cmd/link: use new relocation accessors in DWARF generation
authorCherry Zhang <cherryyz@google.com>
Mon, 16 Mar 2020 16:09:52 +0000 (12:09 -0400)
committerCherry Zhang <cherryyz@google.com>
Mon, 16 Mar 2020 17:33:50 +0000 (17:33 +0000)
commit61a0b0d62461a8697db9869cfaf39471228e7903
tree1f223044870f388a83a32ef31bace43e10fed6dd
parent8a074fa275261a3dd1690f81e4fa6c45bdbb0471
[dev.link] cmd/link: use new relocation accessors in DWARF generation

This gives some speedup and reduces some allocations:

(linking cmd/compile)
DwarfGenerateDebugInfo    63.2ms ± 3%    41.7ms ± 3%  -34.04%  (p=0.008 n=5+5)

DwarfGenerateDebugInfo    20.0MB ± 0%    10.1MB ± 0%  -49.62%  (p=0.008 n=5+5)

There are code that modify relocations, which are still using
the earlier loader.Reloc slice for now.

Change-Id: I3359ba305bf82cc882ae3c0f548d6ccfc8add789
Reviewed-on: https://go-review.googlesource.com/c/go/+/223663
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Than McIntosh <thanm@google.com>
src/cmd/link/internal/ld/deadcode2.go
src/cmd/link/internal/ld/decodesym2.go
src/cmd/link/internal/ld/dwarf.go