]> Cypherpunks repositories - gostls13.git/commit
cmd/internal/obj: build ctxt.Text during Sym init
authorJosh Bleecher Snyder <josharian@gmail.com>
Thu, 13 Apr 2017 00:43:30 +0000 (17:43 -0700)
committerJosh Bleecher Snyder <josharian@gmail.com>
Thu, 13 Apr 2017 02:29:05 +0000 (02:29 +0000)
commitc18fd098401805478fac6a3ff42bfad9a66a16d3
treeac3e9e37267c8d19b87eea803ac642b2b7463602
parent9dbba36a979323357f7f0e68664b522c67c30ecf
cmd/internal/obj: build ctxt.Text during Sym init

Instead of constructing ctxt.Text in Flushplist,
which will be called concurrently,
do it in InitTextSym, which must be called serially.
This allows us to avoid a mutex for ctxt.Text,
and preserves the existing ordering of functions
for debug output.

Passes toolstash-check.

Updates #15756

Change-Id: I6322b4da24f9f0db7ba25e5b1b50e8d3be2deb37
Reviewed-on: https://go-review.googlesource.com/40502
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
src/cmd/internal/obj/plist.go