code review 5991047: runtime: minor refactoring in preparation for parallel GC (issue 5991047)

387 views
Skip to first unread message

dvy...@google.com

unread,
Apr 5, 2012, 12:19:50 PM4/5/12
to golan...@googlegroups.com, re...@codereview-hr.appspotmail.com
Reviewers: golang-dev_googlegroups.com,

Message:
Hello golan...@googlegroups.com,

I'd like you to review this change to
https://go.googlecode.com/hg/


Description:
runtime: minor refactoring in preparation for parallel GC
factor sweepspan() out of sweep(), no logical changes

Please review this at http://codereview.appspot.com/5991047/

Affected files:
M src/pkg/runtime/mgc0.c


Russ Cox

unread,
Apr 5, 2012, 12:38:21 PM4/5/12
to dvy...@google.com, golan...@googlegroups.com, re...@codereview-hr.appspotmail.com
Please put sweepspan after sweep instead of before it,
so that the code continues to read from top-to-bottom.
It will require a forward declaration, but that's just the way
C is. It should also make the diffs much smaller.

Thanks.

dvy...@google.com

unread,
Apr 5, 2012, 12:43:45 PM4/5/12
to golan...@googlegroups.com, r...@golang.org, golan...@googlegroups.com, re...@codereview-hr.appspotmail.com

dvy...@google.com

unread,
Apr 5, 2012, 12:44:33 PM4/5/12
to golan...@googlegroups.com, r...@golang.org, golan...@googlegroups.com, re...@codereview-hr.appspotmail.com

Done. PTAL.
Unfortunately the diff have not become smaller, I guess it's because of
changed indentation level.

http://codereview.appspot.com/5991047/

r...@golang.org

unread,
Apr 5, 2012, 12:53:38 PM4/5/12
to dvy...@google.com, golan...@googlegroups.com, golan...@googlegroups.com, re...@codereview-hr.appspotmail.com

dvy...@google.com

unread,
Apr 5, 2012, 1:02:42 PM4/5/12
to dvy...@google.com, golan...@googlegroups.com, r...@golang.org, re...@codereview-hr.appspotmail.com
*** Submitted as
http://code.google.com/p/go/source/detail?r=0b2d96522c1f ***

runtime: minor refactoring in preparation for parallel GC
factor sweepspan() out of sweep(), no logical changes

R=golang-dev, rsc
CC=golang-dev
http://codereview.appspot.com/5991047


http://codereview.appspot.com/5991047/

Dmitry Vyukov

unread,
Apr 5, 2012, 3:10:17 PM4/5/12
to r...@golang.org, re...@codereview-hr.appspotmail.com, golang-dev


On Apr 5, 2012 8:38 PM, "Russ Cox" <r...@golang.org> wrote:
>
> Please put sweepspan after sweep instead of before it,
> so that the code continues to read from top-to-bottom.

I like the top-to-bottom feature of Go

Reply all
Reply to author
Forward
0 new messages