<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
--></style>
</head>
<body class='hmmessage'>
ThreadBase/RunThread -- something seems a little off to me here.<BR>
 <BR>
 <BR>
I merged the functions.<BR>
Stuff is supposed to work asif there is arbitrary inlining.<BR>
 At least until/unless we get a pragma to mark a function as not inlinable or a direct language feature analogous to "volatile" to preserve locals -- currently inserting try does it but that's an implementation detail I think.<BR>
 <BR>
 <BR>
However, I wonder, in taking the address of "xx", isn't ThreadBase a bit..gambling?<BR>
You know, the traced references might be before or after xx in the stack, so xx might not cover it.<BR>
 <BR>
 <BR>
The code is safe because the only traced reference is "self" which also is reachable via slots.<BR>
 <BR>
 <BR>
In particular I'm trying to link Activation<=>T and introduce allThreadsTraced analogous to allThreads -- a global list of all threads, covering their traced part.<BR>
That way AssignSlots/FreeSlots and the slots lock would go away.<BR>
Removing locks seems like a good thing in general.<BR>
Overall space consumption wouldn't be much different, I'd trade an array of pointers, one pointer per thread, for two pointers embedded in each thread plus a global pointer. But the ability to fetch Self() faster or RunThread to block on less or no locking would be good -- not that Self() is used much anymore.<BR>
 <BR>
 <BR>
I keep seeing strange failures and I wonder if taking away the slots reference leaves me with insufficient reference.<BR>
Or maybe I'm breaking it some other way.<BR>
 <BR>
I tried building up allThreadsTraced earlier, while stackbase isn't settable, and have code watch for stackbase = NIL but still no luck.<BR>
 <BR>
 <BR>
I'll try more later...<BR>
 <BR>
 <BR>
 - Jay<BR>                                     </body>
</html>