]> Cypherpunks repositories - gostls13.git/commit
cmd/compile/internal/noder: optimize itabs section of runtime dicts
authorMatthew Dempsky <mdempsky@google.com>
Thu, 1 Sep 2022 23:58:15 +0000 (16:58 -0700)
committerMatthew Dempsky <mdempsky@google.com>
Sat, 3 Sep 2022 06:26:16 +0000 (06:26 +0000)
commit9fc09d2ffb4384579998b5046a1d4aee32c5ca17
treec1bf8262cc7170eaade88451996eb19a0e7c12fc
parent3e11e61f3ced03d48e7d27ff6e51a3b1c0425db7
cmd/compile/internal/noder: optimize itabs section of runtime dicts

Currently, the itabs section for runtime dictionaries includes its own
redundant *runtime._type pointers for typ and iface, which were
sometimes necessary. This simplified the initial implementation, but
is a little wasteful of space when the same type or interface appeared
across multiple (typ, iface) pairs.

This CL instead reuses the pointers from the rtypes section.

Change-Id: I48448515c319c0403c1a8e7706794d443176f0a4
Reviewed-on: https://go-review.googlesource.com/c/go/+/427754
Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
Run-TryBot: Matthew Dempsky <mdempsky@google.com>
Reviewed-by: Keith Randall <khr@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
src/cmd/compile/internal/noder/reader.go
src/cmd/compile/internal/noder/writer.go