aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/link/internal/ld/errors.go
AgeCommit message (Collapse)Author
2022-11-02cmd/link: remove unnecessary use of sync.Once alongside sync.MutexRuss Cox
There does not seem to be any point to this sync.Once. I noticed because I was surveying uses of sync.Once to understand usage patterns. This seems to be a dreg left over from some earlier instance of the code. Change-Id: I99dd258d865a41d0e8f6cfa55887855e477fb9c2 Reviewed-on: https://go-review.googlesource.com/c/go/+/445755 Auto-Submit: Russ Cox <rsc@golang.org> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Russ Cox <rsc@golang.org> Reviewed-by: Cherry Mui <cherryyz@google.com>
2020-08-17all: add empty line between copyright header and package clauseTobias Klauser
Makes sure the copyright notice is not interpreted as the package level godoc. Change-Id: I2afce7c9d620f19d51ec1438b1d0db1774b57146 Reviewed-on: https://go-review.googlesource.com/c/go/+/248760 Run-TryBot: Tobias Klauser <tobias.klauser@gmail.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Dave Cheney <dave@cheney.net>
2020-05-14[dev.link] cmd/link: delete sym.Symbol and sym.RelocCherry Zhang
This deletes all sym.Symbol and sym.Reloc references. This is certainly not complete, and there are more cleanups to do. But I feel this makes a good first round. Change-Id: I7621d016957f7ef114be5f0606fcb3ad6aee71c8 Reviewed-on: https://go-review.googlesource.com/c/go/+/234097 Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-04-28[dev.link] cmd/link: convert dwarfcompress to using the loaderCherry Zhang
Change-Id: I34f806b54e8e0985a30ef38ea4324352aabfc845 Reviewed-on: https://go-review.googlesource.com/c/go/+/229995 Run-TryBot: Cherry Zhang <cherryyz@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-04-24[dev.link] cmd/link: move more error handling into loaderThan McIntosh
Move the guts of ctxt.Errorf into loader.Loader, so that we can make calls to it from functions that have a "*loader.Loader" available but not a "ctxt *Link". This is needed to start converting hooks like "adddynrel" in the arch-specific portions of the linker to use loader APIs. Change-Id: Ieedd4583b66504be0e77d7f3fbadafe0d2307a69 Reviewed-on: https://go-review.googlesource.com/c/go/+/229497 Run-TryBot: Than McIntosh <thanm@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com> Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-04-02[dev.link] all: merge branch 'master' into dev.linkCherry Zhang
The only conflict is a modify-deletion conflict in cmd/link/internal/ld/link.go, where the old error reporter is deleted in the new linker. Ported to cmd/link/internal/ld/errors.go. Change-Id: I5c78f398ea95bc1d7e6579c84dd8252c9f2196b7
2020-03-25[dev.link] cmd/link: relocating Errorf() to ErrorReporterThan McIntosh
Add an Errorf method to ErrorReporter. The hope is that we can consolidate error handling/reporting in this helper, and eventually do away with Link.Errorf and the global Errorf function (which can be removed once we've eliminated enough uses of *sym.Symbol). Change-Id: Ie1147020b8409b9c57acfd71c942b287b214afca Reviewed-on: https://go-review.googlesource.com/c/go/+/224380 Reviewed-by: Jeremy Faller <jeremy@golang.org>
2020-03-04[dev.link] cmd/link: remove *Link from relocsymJeremy Faller
This is the last step requried before relocsym can go parallel. Change-Id: Id1c1c530c2b9277917208c3767eeb29e02c17a9c Reviewed-on: https://go-review.googlesource.com/c/go/+/220841 Run-TryBot: Jeremy Faller <jeremy@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Cherry Zhang <cherryyz@google.com>
2020-02-28[dev.link] cmd/link: remove some dependence on *LinkJeremy Faller
In an effort to make relocation application thread-safe remove another dependence on context. Change-Id: Ic53ea122cce72117fcebe56e386b710755f6eb68 Reviewed-on: https://go-review.googlesource.com/c/go/+/220838 Run-TryBot: Jeremy Faller <jeremy@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Cherry Zhang <cherryyz@google.com> Reviewed-by: Than McIntosh <thanm@google.com>