1
0
mirror of https://github.com/golang/go synced 2024-10-05 10:31:22 -06:00
go/src/cmd/5l
Russ Cox 196b663075 gc: implement == on structs and arrays
To allow these types as map keys, we must fill in
equal and hash functions in their algorithm tables.
Structs or arrays that are "just memory", like [2]int,
can and do continue to use the AMEM algorithm.
Structs or arrays that contain special values like
strings or interface values use generated functions
for both equal and hash.

The runtime helper func runtime.equal(t, x, y) bool handles
the general equality case for x == y and calls out to
the equal implementation in the algorithm table.

For short values (<= 4 struct fields or array elements),
the sequence of elementwise comparisons is inlined
instead of calling runtime.equal.

R=ken, mpimenov
CC=golang-dev
https://golang.org/cl/5451105
2011-12-12 22:22:09 -05:00
..
5.out.h 5l: delete dead code 2011-06-09 18:07:56 -04:00
asm.c 5l, 6l, 8l: correct ELFRESERVE diagnostic 2011-10-18 16:05:38 -04:00
doc.go 5l/6l/8l: use enums for header type and symbolic strings for -H option values 2011-02-23 14:30:40 +11:00
l.h ld: align ELF data sections 2011-11-30 13:24:16 -08:00
list.c 5l: delete dead code 2011-06-09 18:07:56 -04:00
Makefile cmd/5l/Makefile: directory prefix nit, "../5l/" is not needed. 2011-07-18 08:46:47 +10:00
mkenam 5l, 6l, 8l: drop use of ed during build 2011-06-27 12:03:19 -04:00
noop.c 5g, 5l: fix more set but not used warnings 2011-06-20 14:18:04 -04:00
obj.c gc: implement == on structs and arrays 2011-12-12 22:22:09 -05:00
optab.c 5l: delete dead code 2011-06-09 18:07:56 -04:00
pass.c 5a, 5c, 5l: fix for Plan 9 build 2011-07-15 11:58:28 -04:00
prof.c 5a, 5c, 5l: fix for Plan 9 build 2011-07-15 11:58:28 -04:00
softfloat.c build: avoid redundant bss declarations 2011-08-23 22:39:14 -04:00
span.c ld: remove overlap of ELF sections on dynamic binaries 2011-07-20 12:47:02 -03:00