mirror of
https://github.com/golang/go
synced 2024-10-05 05:11:25 -06:00
8b4deb448e
The size calculation has been wrong since this code was first committed in https://golang.org/cl/3120. The effect was that the compiler always allocated a temporary buffer on the stack for a non-escaping string concatenation. This turns out to make no practical difference, as the compiler always allocates a buffer of the same size (32 bytes) and the runtime only uses the temporary buffer if the concatenated strings fit (check is in rawstringtmp in runtime/string.go). The effect of this change is to avoid generating a temporary buffer on the stack that will not be used. Change-Id: Id632bfe3d6c113c9934c018a2dd4bcbf1784a63d Reviewed-on: https://go-review.googlesource.com/20112 Run-TryBot: Ian Lance Taylor <iant@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> |
||
---|---|---|
.. | ||
addr2line | ||
api | ||
asm | ||
cgo | ||
compile | ||
cover | ||
dist | ||
doc | ||
fix | ||
go | ||
gofmt | ||
internal | ||
link | ||
newlink | ||
nm | ||
objdump | ||
pack | ||
pprof | ||
trace | ||
vet | ||
yacc |