help-smalltalk
[Top][All Lists]
Advanced

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

Re: [Help-smalltalk] Single stepping issue in the JIT


From: Holger Hans Peter Freyther
Subject: Re: [Help-smalltalk] Single stepping issue in the JIT
Date: Sat, 4 Jan 2014 08:54:46 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Fri, Jan 03, 2014 at 09:21:01PM +0100, Paolo Bonzini wrote:

> > So is it possible that the suspended process is also the get_active_process
> > at that time? And then it gets re-inserted into the waiting list?
> 
> Doesn't sound impossible.  I'll take a look next week (full week of free
> time hacking!)

Yeah! We have plenty of fun stuff waiting. :)

diff --git a/libgst/prims.def b/libgst/prims.def
index 72add2b..65d4eb3 100644
--- a/libgst/prims.def
+++ b/libgst/prims.def
@@ -2873,6 +2873,8 @@ primitive VMpr_Process_suspend [succeed,check_interrupt]
 
   oop1 = STACKTOP ();
   suspend_process (oop1);
+  if (oop1 == switch_to_process)
+       printf("Suspended is switched to process.\n");
   PRIM_SUCCEEDED;
 }


 st> a := nil. p := [a := 3 ] newProcess
 nil
 Process(nil at userSchedulingPriority, suspended)
 st> p singleStep; suspend
 Suspended is switched to process.
 Semaphore(nil: held, 0 waiting processes)


So we suspend the process but it is still the process we want to switch
to. I don't know the semantics here too well. E.g. why doesn't this happen
with the interpreter and what is the right way a suspended process should
become ready-to-run again?

holger



reply via email to

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