]> Cypherpunks repositories - gostls13.git/commit
[dev.link] cmd/link: remove unused slow paths from BytesAt/StringAt
authorThan McIntosh <thanm@google.com>
Wed, 16 Oct 2019 14:39:58 +0000 (10:39 -0400)
committerThan McIntosh <thanm@google.com>
Thu, 17 Oct 2019 14:20:15 +0000 (14:20 +0000)
commit6ecaae032520615a89c55c1ee31f0060feab0f4a
treeb2753318d40175c2eb6ade749b57cce00bf90ac4
parente5acb58c394c7d900d9aa948a9b601c49c97ab09
[dev.link] cmd/link: remove unused slow paths from BytesAt/StringAt

This change removes the NewReader function (no longer used by objdump)
and prunes away the now unused code paths from Reader.BytesAt and
Reader.StringAt, which helps with performance. At the moment the
reader operates by always ingesting the entire object file (either via
direct read or by mmap), meaning that there will always be a slice
available for us to index into.

Change-Id: I3af7396effe19e50ed594fe8d82fd2d15465687c
Reviewed-on: https://go-review.googlesource.com/c/go/+/201437
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>
src/cmd/internal/goobj2/objfile.go