runtime: poor man's heap type info checker
It's not trivial to make a comprehensive check
due to inferior pointers, reflect, gob, etc.
But this is essentially what I've used to debug
the GC issues.
Update issue 5193.

R=golang-dev, iant, 0xe2.0x9a.0x9b, r
CC=golang-dev
https://codereview.appspot.com/8455043
sync, sync/atomic: do not corrupt race detector after a nil dereference.

The race detector uses a global lock to analyze atomic
operations. A panic in the middle of the code leaves the
lock acquired.

Similarly, the sync package may leave the race detectro
inconsistent when methods are called on nil pointers.

R=golang-dev, r, minux.ma, dvyukov, rsc, adg
CC=golang-dev
https://codereview.appspot.com/7981043
cmd/cgo: record CGO_LDFLAGS env var in _cgo_flags

cgo stores cgo LDFLAGS in _cgo_flags and _cgo_defun.c.
The _cgo_defun.c records the flags via
"#pragma cgo_ldflag <flag>", which external linking
relies upon for passing libraries (and search paths)
to the host linker.

The go command will allow LDFLAGS for cgo to be passed
through the environment (CGO_LDFLAGS); cgo ignores
this environment variable, and so its value doesn't
make it into the above mentioned files. This CL changes
cgo to record CGO_LDFLAGS also.

Fixes issue 5205.

R=iant, minux.ma
CC=golang-dev
https://codereview.appspot.com/8465043

Committer: Shenghou Ma <minux.ma@gmail.com>
net: add test for runtime.PollDesc leak

See 8318044

R=bradfitz
CC=golang-dev
https://codereview.appspot.com/8547043
runtime: fix integer overflow in hashmap
The test is problematic, because it requires 8GB+ of RAM.
Fixes issue 5239.

R=golang-dev, bradfitz
CC=golang-dev
https://codereview.appspot.com/8550043
misc/dashboard/builder: add -race builder support

If the build key contains -race, the builder will invoke to the race.{bat,bash} build command. This allows {darwin,linux,windows}-amd64 builders to do race and non race builds in sequence.

R=adg, dvyukov, fullung
CC=golang-dev
https://codereview.appspot.com/8266046
run.bat: make windows runtime test timeout same as other os

R=golang-dev, dave
CC=golang-dev
https://codereview.appspot.com/8551043
A+C: Nicholas Presta (individual CLA)

Generated by addca.

R=gobot
CC=golang-dev
https://codereview.appspot.com/8556044
net: fix possible runtime.PollDesc leak when connect or listen fails

Makes it possible to return the spent runtime.PollDesc to
runtime.pollcache descriptor pool when netFD.connect or
syscall.Listen fails.

Fixes issue 5219.

R=dvyukov, dave, bradfitz, adg
CC=golang-dev
https://codereview.appspot.com/8318044
dist: include js directory in misc/tour in binary distros

R=campoy, dsymonds
CC=golang-dev
https://codereview.appspot.com/8564043
dist: add .exe extension to tour.exe

Fixes issue 5246.

R=golang-dev, dsymonds
CC=golang-dev
https://codereview.appspot.com/8558044
lib9: add newline to exec error message

R=golang-dev, bradfitz, r
CC=golang-dev
https://codereview.appspot.com/8573043
io: document non-guarantees of io.Closer

R=r, golang-dev
CC=golang-dev
https://codereview.appspot.com/8575043
encoding/json: fix handling of anonymous fields
The old code was incorrect and also broken. It passed the tests by accident.
The new algorithm is:
        1) Sort the fields in order of names.
        2) For all fields with the same name, sort in increasing depth.
        3) Choose the single field with shortest depth.
If any of the fields of a given name has a tag, do the above using
tagged fields of that name only.
Fixes issue 5245.

R=iant
CC=golang-dev
https://codereview.appspot.com/8583044
cmd/ld: fix inconsistency in internal linking of common symbols.

Some variables declared in C could end up as undefined symbols
in the final binary and have null address.

Fixes issue 5114.
Fixes issue 5227.

R=golang-dev, iant, ajstarks, dave, r
CC=golang-dev
https://codereview.appspot.com/8602044
cmd/ld: fix argument passing in doc.go

R=golang-dev, r
CC=golang-dev
https://codereview.appspot.com/8622043
encoding/json: different decision on tags and shadowing
If there are no tags, the rules are the same as before.
If there is a tagged field, choose it if there is exactly one
at the top level of all fields.
More tests. The old tests were clearly inadequate, since
they all pass as is. The new tests only work with the new code.

R=golang-dev, iant
CC=golang-dev
https://codereview.appspot.com/8617044