]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: remove rtype *uncommonType field
authorDavid Crawshaw <crawshaw@golang.org>
Sun, 21 Feb 2016 03:54:15 +0000 (22:54 -0500)
committerDavid Crawshaw <crawshaw@golang.org>
Tue, 8 Mar 2016 23:23:13 +0000 (23:23 +0000)
commita24b3ed7538dd2eb013005fb1e153468f486857a
tree1984c416b16989a003a8adbdd2356fde7cffb7f2
parent0321cabdfacc5472d2bc650de3e36ca10131b60a
cmd/compile: remove rtype *uncommonType field

Instead of a pointer on every rtype, use a bit flag to indicate that
the contents of uncommonType directly follows the rtype value when it
is needed.

This requires a bit of juggling in the compiler's rtype encoder. The
backing arrays for fields in the rtype are presently encoded directly
after the slice header. This packing requires separating the encoding
of the uncommonType slice headers from their backing arrays.

Reduces binary size of godoc by ~180KB (1.5%).
No measurable change in all.bash time.
For #6853.

Change-Id: I60205948ceb5c0abba76fdf619652da9c465a597
Reviewed-on: https://go-review.googlesource.com/19790
Reviewed-by: Russ Cox <rsc@golang.org>
Run-TryBot: David Crawshaw <crawshaw@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/cmd/compile/internal/gc/reflect.go
src/cmd/link/internal/ld/decodesym.go
src/reflect/type.go
src/runtime/heapdump.go
src/runtime/iface.go
src/runtime/mfinal.go
src/runtime/type.go