[dev.link] cmd/link: hoist dwarfGenerateDebugSyms out of dodata()

Hoist dwarfGenerateDebugSyms call up out of dodata to before
loadlibfull. This required a couple of small tweaks to the
loader and to loadlibfull.

Change-Id: I48ffb450d2e48b9e55775b73a6debcd27dbb7b9c
Reviewed-on: https://go-review.googlesource.com/c/go/+/228221
Run-TryBot: Cherry Zhang <cherryyz@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Jeremy Faller <jeremy@golang.org>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
This commit is contained in:
Than McIntosh 2020-04-13 15:38:03 -04:00
parent 3216d14f78
commit eed3ef581b
5 changed files with 21 additions and 22 deletions

View file

@ -1923,8 +1923,6 @@ func (ctxt *Link) dodata() {
ctxt.datap = append(ctxt.datap, data[symn]...)
}
dwarfGenerateDebugSyms(ctxt)
var i int
for ; i < len(dwarfp); i++ {
s := dwarfp[i]