]> Cypherpunks repositories - gostls13.git/commit
cmd/link: replace interface{} fields with concrete types
authorMichael Hudson-Doyle <michael.hudson@canonical.com>
Wed, 27 May 2015 00:04:25 +0000 (12:04 +1200)
committerIan Lance Taylor <iant@golang.org>
Wed, 27 May 2015 04:03:32 +0000 (04:03 +0000)
commitcf2736c4c5bbb24b9a4ff9690887a0cb287ba34c
tree0fecedb7d74677e3d66f270b9ab9dfe95f7c06f6
parentbc89ad598e51b1f4935c2574edbabafff4dc1dea
cmd/link: replace interface{} fields with concrete types

The LSym.Section and Section.Elfsect fields were defined as interface{} but
always had the same concrete type (*Section and *ElfShdr respectively) so just
define them with that type. Reduces size of LSym from 328 to 320 bytes and
reduces best-of-10 maxresident size from 246028k to 238036k when linking
libstd.so.

Change-Id: Ie7112c53e4c2c7ce5fe233b81372aa5633f572e8
Reviewed-on: https://go-review.googlesource.com/10410
Reviewed-by: Minux Ma <minux@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/cmd/link/internal/amd64/asm.go
src/cmd/link/internal/arm/asm.go
src/cmd/link/internal/arm64/asm.go
src/cmd/link/internal/ld/data.go
src/cmd/link/internal/ld/elf.go
src/cmd/link/internal/ld/lib.go
src/cmd/link/internal/ld/link.go
src/cmd/link/internal/ld/macho.go
src/cmd/link/internal/ld/symtab.go
src/cmd/link/internal/x86/asm.go