]> Cypherpunks repositories - gostls13.git/commit
cmd/compile: inline {i,e}facethash
authorKeith Randall <khr@golang.org>
Mon, 22 Feb 2016 04:43:14 +0000 (20:43 -0800)
committerKeith Randall <khr@golang.org>
Mon, 22 Feb 2016 05:09:25 +0000 (05:09 +0000)
commitd0c11577b9c6d584959aceddf97266b9cbc336d0
tree3bf0867b7898f0cd8928d1b6e80466978009dbf4
parent5609a48931593a0ba88cab4a54ea5c426b292c3e
cmd/compile: inline {i,e}facethash

These functions are really simple, the overhead of calling
them (in both time and code size) is larger than the inlined versions.

Reorganize how the nil case in a type switch is handled, as we have
to check for nil explicitly now anyway.

Saves about 0.8% in the binary size of the go tool.

Change-Id: I8501b62d72fde43650b79f52b5f699f1fbd0e7e7
Reviewed-on: https://go-review.googlesource.com/19814
Run-TryBot: Keith Randall <khr@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
src/cmd/compile/internal/gc/builtin.go
src/cmd/compile/internal/gc/builtin/runtime.go
src/cmd/compile/internal/gc/swt.go
src/runtime/iface.go