help-smalltalk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-smalltalk] [bug] Intermittent DNU using Delay


From: Tony Garnock-Jones
Subject: [Help-smalltalk] [bug] Intermittent DNU using Delay
Date: Sun, 06 Jan 2008 05:30:45 -0700

Issue status update for http://smalltalk.gnu.org/node/153 Post a follow up: http://smalltalk.gnu.org/project/comments/add/153

Project:      GNU Smalltalk
Version:      <none>
Component:    VM
Category:     bug reports
Priority:     normal
Assigned to:  Unassigned
Reported by:  tonyg
Updated by:   tonyg
Status:       active

The following test program will, in roughly 50% of its runs on my
machine, generate the following backtrace immediately after the first
"Global garbage collection... done" message. In the other runs, the
global collection message prints and the program continues running
without the backtrace. I'm not sure if the backtrace has caused any of
the three Processes to exit.


Backtrace:



~$ gst threading-preemption.st
"Global garbage collection... done"
Object: nil error: did not understand #goodness:
MessageNotUnderstood(Exception)>>signal
UndefinedObject(Object)>>doesNotUnderstand: #goodness:
optimized [] in BlockClosure class>>exceptionHandlerSearchBlock
[] in Kernel.CoreException>>instantiateNextHandler:
MethodContext(ContextPart)>>scanBacktraceForAttribute:do:
Kernel.CoreException>>instantiateNextHandler:
MessageNotUnderstood(Exception)>>signal
UndefinedObject(Object)>>doesNotUnderstand: #key
Delay class>>unscheduleDelay:
Delay class>>handleDelayEvent
optimized [] in Delay class>>runDelayProcess
[] in BlockClosure>>ifCurtailed:
BlockClosure>>ensure:
BlockClosure>>ifCurtailed:
Delay class>>runDelayProcess
optimized [] in Delay class>>startDelayLoop
[] in Process>>onBlock:at:suspend:
BlockClosure>>on:do:
[] in Process>>onBlock:at:suspend:
BlockClosure>>ensure:
[] in Process>>onBlock:at:suspend:
[] in BlockClosure>>asContext:
BlockContext class>>fromClosure:parent:

Code:



"Attempt to use a high-priority process to preempt lower-priority
processes. Doesn't work."

[
 | d |
 d := Delay forMilliseconds: 10.
 [
   d wait.
 ] repeat.
] forkAt: Processor highestPriority.

[
 [
   Transcript show: 'one'.
   (Delay forMilliseconds: 10) wait.
 ] repeat.
] fork.

[
 [
   Transcript show: 'two'.
   (Delay forMilliseconds: 10) wait.
 ] repeat.
] value.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]