]> Cypherpunks repositories - gostls13.git/commit
runtime: faster hashmap implementation.
authorKeith Randall <khr@golang.org>
Wed, 20 Mar 2013 20:51:29 +0000 (13:51 -0700)
committerKeith Randall <khr@golang.org>
Wed, 20 Mar 2013 20:51:29 +0000 (13:51 -0700)
commit00224a356a5be3c134230bfa8fe11e0af2977aaf
tree215e0ad8bd4fe89b437bf1ef572a0c4f94af489d
parent2001f0c28ef4f2b7b907d060901a6fad2f1e9eb0
runtime: faster hashmap implementation.

Hashtable is arranged as an array of
8-entry buckets with chained overflow.
Each bucket has 8 extra hash bits
per key to provide quick lookup within
a bucket.  Table is grown incrementally.

Update #3885
Go time drops from 0.51s to 0.34s.

R=r, rsc, m3b, dave, bradfitz, khr, ugorji, remyoudompheng
CC=golang-dev
https://golang.org/cl/7504044
src/cmd/gc/builtin.c
src/cmd/gc/range.c
src/cmd/gc/walk.c
src/cmd/ld/dwarf.c
src/pkg/runtime/hashmap.c
src/pkg/runtime/hashmap.h
src/pkg/runtime/hashmap_fast.c [new file with mode: 0644]
src/pkg/runtime/map_test.go [new file with mode: 0644]
src/pkg/runtime/mapspeed_test.go
src/pkg/runtime/runtime.c
src/pkg/runtime/runtime.h