[dev.garbage] create new branch

This branch is for Rick Hudson's work on concurrent collection,
targeted to land at the beginning of the 1.5 cycle.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/138510043
[dev.garbage] remove dev.garbage placeholder

The file was created just to have something to check in
to create the new branch. No longer needed.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/140670043
[dev.garbage] lib/codereview: allow hg submit to commit new branch if CL description says so

This means I won't have to edit the plugin when I create
the next dev branch.

LGTM=r, adg
R=r, adg
CC=golang-codereviews
https://codereview.appspot.com/148950045
[dev.garbage] cmd/gc: never generate BitsMultiWord

LGTM=rlh
R=rlh, minux
CC=golang-codereviews
https://codereview.appspot.com/151940043
[dev.garbage] runtime: remove another BitsMultiWord

Not found because it was not used by name.
Add name in comments for what's left behind.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/148430043
[dev.garbage] runtime: make sure G.param and SudoG.elem do not hold stale pointers

In old conservative Go, this could cause memory leaks.
A new pickier collector might reasonably crash when it saw one of these.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/147480043
[dev.garbage] runtime: scan and mark phase refactoring

Refactoring of the scan and mark phase so that concurrent GC,
in particular the write barrier, can share a common infrastructure.
Now that the scan and mark phases have been separated
we will be able to scan stacks without blackening any objects.
This in turn will allow us to delay installing expensive write barrier code.

LGTM=rsc
R=rsc, khr, dvyukov
CC=golang-codereviews
https://codereview.appspot.com/145640044

Committer: Russ Cox <rsc@golang.org>
[dev.garbage] merge default into dev.garbage
[dev.garbage] all: merge default into dev.garbage

This picks up the selectdone dangling pointer fix, among others.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/153070045
[dev.garbage] all: merge default into dev.garbage

This picks up the TestDualStackUDPListener fix.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/147660044
[dev.garbage] runtime: Write barrier code.
Comments lay out the concurrent GC algorithms.
This CL implements parts of the algorithm.
The acknowledgement code has been removed from this CL

LGTM=rsc, dvyukov
R=dvyukov, rsc
CC=golang-codereviews
https://codereview.appspot.com/151540043
all: merge default branch into dev.garbage

hg was unable to create a CL on the code review server for this,
so I am submitting the merge by hand.
The only manual edits are in mgc0.c, to reapply the
removal of cached/ncached to the new code.
[dev.garbage] runtime: simplifiy lfstack.c due to undiagnosed buffer corruption.
The changes got rid of the problems we were seeing.
We suspect the pushcnt field has a race.

LGTM=rsc
R=dvyukov, rsc
CC=golang-codereviews
https://codereview.appspot.com/159330043

Committer: Russ Cox <rsc@golang.org>
[dev.garbage] runtime: Concurrent scan code
Routines and logic to preform a concurrent stack scan of go-routines.
This CL excersizes most of the functionality needed. The
major exception being that it does not scan running goroutines.
After doing the scans it relies on a STW to finish the GC, including
rescanning the stacks. It is intended to achieve correctness,
performance will follow.

LGTM=rsc
R=golang-codereviews, rsc
CC=dvyukov, golang-codereviews
https://codereview.appspot.com/156580043
[dev.garbage] runtime: Linear map test give false negative due to GC.
This test gives a false negative at an observed rate of 1 in a 1000
due to the fact that it runs for < 100 ms. allowing GC pauses to
warp the results. Changed the test so that it triggers only if it
remains non-linear for much larger problem sizes.

LGTM=rsc
R=rsc
CC=golang-codereviews
https://codereview.appspot.com/164010043
[dev.garbage] runtime: fix TestLFStack on 386

LGTM=rlh
R=rlh, dvyukov
CC=golang-codereviews
https://codereview.appspot.com/157430044
[dev.garbage] runtime: Fix 386 compiler warnings.

LGTM=rsc
R=rsc
CC=golang-codereviews
https://codereview.appspot.com/163390043
[dev.garbage] all: merge default (dd5014ed9b01) into dev.garbage

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/170730043
[dev.garbage] all: merge dev.power64 (5ad5e85cfb99) into dev.garbage

The goal here is to get the big-endian fixes so that
in some upcoming code movement for write barriers
I don't make them unmergeable.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/166890043
[dev.garbage] cmd/gc, runtime: implement write barriers in terms of writebarrierptr

This CL implements the many multiword write barriers by calling
writebarrierptr, so that only writebarrierptr needs the actual barrier.
In lieu of an actual barrier, writebarrierptr checks that the value
being copied is not a small non-zero integer. This is enough to
shake out bugs where the barrier is being called when it should not
(for non-pointer values). It also found a few tests in sync/atomic
that were being too clever.

This CL adds a write barrier for the memory moved during the
builtin copy function, which I forgot when inserting barriers for Go 1.4.

This CL re-enables some write barriers that were disabled for Go 1.4.
Those were disabled because it is possible to change the generated
code so that they are unnecessary most of the time, but we have not
changed the generated code yet. For safety they must be enabled.

None of this is terribly efficient. We are aiming for correct first.

LGTM=rlh
R=rlh
CC=golang-codereviews
https://codereview.appspot.com/168770043