Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1429)

Issue 9136045: runtime: preemptive scheduler

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 6 months ago by dvyukov
Modified:
11 years, 5 months ago
Reviewers:
Tw
Visibility:
Public.

Description

runtime: preemptive scheduler

Patch Set 1 #

Patch Set 2 : diff -r ce5b441d2fc6 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 3 : diff -r ce5b441d2fc6 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 4 : diff -r ce5b441d2fc6 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 5 : diff -r ce5b441d2fc6 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 6 : diff -r 30c566874b83 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 7 : diff -r 30c566874b83 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 8 : diff -r 1a042de45e20 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 9 : diff -r 673dec3ec845 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 10 : diff -r 673dec3ec845 https://dvyukov%40google.com@code.google.com/p/go/ #

Patch Set 11 : diff -r 673dec3ec845 https://dvyukov%40google.com@code.google.com/p/go/ #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+250 lines, -46 lines) Patch
M src/pkg/runtime/asm_386.s View 1 2 3 4 5 6 7 3 chunks +18 lines, -0 lines 0 comments Download
M src/pkg/runtime/asm_amd64.s View 1 2 3 4 5 6 3 chunks +18 lines, -0 lines 0 comments Download
M src/pkg/runtime/asm_arm.s View 1 2 3 4 2 chunks +4 lines, -0 lines 0 comments Download
M src/pkg/runtime/chan.c View 1 2 3 4 5 4 chunks +0 lines, -11 lines 0 comments Download
M src/pkg/runtime/hashmap.c View 1 2 3 4 5 6 7 3 chunks +0 lines, -8 lines 0 comments Download
M src/pkg/runtime/panic.c View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M src/pkg/runtime/proc.c View 1 2 3 4 5 6 7 8 22 chunks +110 lines, -23 lines 0 comments Download
M src/pkg/runtime/proc_test.go View 1 2 3 1 chunk +47 lines, -0 lines 0 comments Download
M src/pkg/runtime/runtime.h View 1 2 3 4 5 6 7 8 5 chunks +8 lines, -1 line 0 comments Download
M src/pkg/runtime/stack.h View 1 2 3 1 chunk +5 lines, -0 lines 0 comments Download
M src/pkg/runtime/stack.c View 1 2 3 4 5 6 7 7 chunks +39 lines, -3 lines 3 comments Download

Messages

Total messages: 5
Tw
https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c File src/pkg/runtime/stack.c (right): https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c#newcode279 src/pkg/runtime/stack.c:279: if(gp->stackguard1 != StackPreempt || preempt) here maybe: if(gp->stackguard1 != ...
11 years, 6 months ago (2013-05-29 15:46:54 UTC) #1
dvyukov
https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c File src/pkg/runtime/stack.c (right): https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c#newcode279 src/pkg/runtime/stack.c:279: if(gp->stackguard1 != StackPreempt || preempt) On 2013/05/29 15:46:54, tw19881113 ...
11 years, 6 months ago (2013-05-29 15:53:37 UTC) #2
Tw
https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c File src/pkg/runtime/stack.c (right): https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c#newcode279 src/pkg/runtime/stack.c:279: if(gp->stackguard1 != StackPreempt || preempt) On 2013/05/29 15:53:37, dvyukov ...
11 years, 6 months ago (2013-05-29 16:04:34 UTC) #3
dvyukov
On Wed, May 29, 2013 at 8:04 PM, <tw19881113@gmail.com> wrote: > > https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c > File ...
11 years, 6 months ago (2013-05-29 16:08:42 UTC) #4
Tw
11 years, 6 months ago (2013-05-30 00:28:46 UTC) #5
On 2013/05/29 16:08:42, dvyukov wrote:
> On Wed, May 29, 2013 at 8:04 PM,  <mailto:tw19881113@gmail.com> wrote:
> >
> > https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c
> > File src/pkg/runtime/stack.c (right):
> >
> >
>
https://codereview.appspot.com/9136045/diff/28002/src/pkg/runtime/stack.c#new...
> > src/pkg/runtime/stack.c:279: if(gp->stackguard1 != StackPreempt ||
> > preempt)
> > On 2013/05/29 15:53:37, dvyukov wrote:
> >>
> >> On 2013/05/29 15:46:54, tw19881113 wrote:
> >> > here maybe:
> >> > if(gp->stackguard1 != StackPreempt || !preempt) ??
> >
> >
> >> I think the current condition is correct.
> >
> > Here is what I think:
> > If preempt == true and arrived here, it says the preemption was
> > requested but can't preempt right now, so we must let gp->stackguard1 =
> > StackPreempt, and let it try to preempt next time.
> 
> No, if preempt == true, we will preempt now.

Yeah, you are right, I thought it the wrong way.
Sorry for asking the stupid questions.
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b