]> Cypherpunks repositories - gostls13.git/commit
runtime: add more specialized type algorithms
authorDmitriy Vyukov <dvyukov@google.com>
Mon, 8 Aug 2011 13:35:32 +0000 (09:35 -0400)
committerRuss Cox <rsc@golang.org>
Mon, 8 Aug 2011 13:35:32 +0000 (09:35 -0400)
commit54e9406ffbabadb2eaf2cf1f3b2297f8a3998157
tree3a2aca3f912cf58300ca26d55e881ac43ed09740
parenta09ba8b6387d938df871d545baa5cbf792459aec
runtime: add more specialized type algorithms
The change adds specialized type algorithms
for slices and types of size 8/16/32/64/128.
It significantly accelerates chan and map operations
for most builtin types as well as user structs.

benchmark                   old,ns/op   new,ns/op
BenchmarkChanUncontended          226          94
(on Intel Xeon E5620, 2.4GHz, Linux 64 bit)

R=golang-dev, rsc
CC=golang-dev
https://golang.org/cl/4815087
src/cmd/gc/go.h
src/cmd/gc/subr.c
src/pkg/runtime/runtime.c
src/pkg/runtime/runtime.h