]> Cypherpunks repositories - gostls13.git/commit
runtime: use indexes for select lock order
authorAustin Clements <austin@google.com>
Tue, 16 Feb 2016 04:50:58 +0000 (23:50 -0500)
committerAustin Clements <austin@google.com>
Wed, 16 Mar 2016 20:13:05 +0000 (20:13 +0000)
commit26594c3dfd67f1fccb328c02de680bfea7eef013
treea3801be3e18f1d2b3c23f641f762fed2ba1c0de7
parente4a95b63433cc95c81782713b917b2941e48cb39
runtime: use indexes for select lock order

Currently the select lock order is a []*hchan. We're going to need to
refer to things other than the channel itself in lock order shortly,
so switch this to a []uint16 of indexes into the select cases. This
parallels the existing representation for the poll order.

Change-Id: I89262223fe20b4ddf5321592655ba9eac489cda1
Reviewed-on: https://go-review.googlesource.com/20036
Reviewed-by: Rick Hudson <rlh@golang.org>
Reviewed-by: Keith Randall <khr@golang.org>
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
src/cmd/compile/internal/gc/select.go
src/runtime/select.go