<div dir="ltr">In the case described, when I (:y 35), and type :go (or whatever made the lisp system ignore the warning), IIRC, it all worked.&nbsp; Therrefore, IIRC, it&#39;s probably the latter, where one second isn&#39;t enough (or something new is occurring to make threads not swap in as much).<br>
<br>The thing that may be indicative that it&#39;s not an OS problem, is that this just started happening when I upgraded to the RC verson of CCL (RC 1.2?).&nbsp; I can inquire of our IT department if you would find whether there was an OS change during this period to be relevant information.&nbsp; RC 1.2 fixed another OpenMCL problem (which I was quite pleased about), so it wasn&#39;t like I could just keep using the old OpenMCL.<br>
<br>At least now our group is no longer the only group seeing and reporting this behavior.<br><br><div class="gmail_quote">On Fri, Jul 25, 2008 at 1:25 PM, Gary Byers <span dir="ltr">&lt;<a href="mailto:gb@clozure.com">gb@clozure.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">In the original bug report, the backtrace for what was thread #35 showed<br>
<br>
 &nbsp;(2AAAAD619B18) : 0 (PROCESS-ENABLE #&lt;PROCESS Worker thread(38) [Active] #x300043A1C8ED&gt; [...]) 405<br>
 &nbsp;(2AAAAD619B68) : 1 (%PROCESS-RUN-FUNCTION &#39;(:NAME &quot;Worker thread&quot;) #&lt;COMPILED-LEXICAL-CLOSURE (:INTERNAL ACL2::RUN-THREAD) #x300043A1CD7F&gt; NIL) 1373<br>
 &nbsp;(2AAAAD619C58) : 2 (PROCESS-RUN-FUNCTION &quot;Worker thread&quot; #&lt;COMPILED-LEXICAL-CLOSURE (:INTERNAL ACL2::RUN-THREAD) #x300043A1CD7F&gt; [...]) 213<br>
<br>
and :proc showed<br>
<br>
38 : &nbsp; &nbsp;Worker thread &nbsp;[Active]<br>
35 : &nbsp; &nbsp;Worker thread &nbsp;[semaphore wait] &nbsp;(Requesting terminal input)<br>
14 : &nbsp; &nbsp;Worker thread &nbsp;[semaphore wait]<br>
1 : -&gt; listener &nbsp; &nbsp; [Active]<br>
0 : &nbsp; &nbsp;Initial &nbsp; &nbsp; &nbsp;[Active]<br>
<br>
In other words, thread 35 created thread 38 and was waiting for it<br>
to signal a semaphore that would indicate that it&#39;s reset itself<br>
and is ready to be enabled (given a function to run). &nbsp;:PROC shows<br>
that thread 38 is already running, which doesn&#39;t make much sense.<br>
The Linux kernel that David Rager was running was one that allegedly<br>
had just fixed a bug which could cause the the wrong thread to be<br>
awakened via FUTEX_WAIT, and it seemed plausible that that bug hadn&#39;t<br>
really been fixed there. &nbsp;The case that failed reliably for David<br>
on the machine that David was using worked reliably for me, similar<br>
cases seemed to work for others, and blaming this on something at<br>
the OS level makes more sense than anything else that I can think<br>
of. &nbsp;(Another fuzzy explanation is that malloc() - when called<br>
from two threads at the same time - returned the same block of<br>
memory to both callers because of a locking problem, so two<br>
threads wound up sharing the same &quot;pointer to semaphore&quot;.)<br>
<br>
There&#39;s a separate issue in that PROCESS-ENABLE waits for the target<br>
thread to indicate that it&#39;s &quot;ready&quot; with a timeout of 1 second.<br>
That&#39;s usually long enough, but it&#39;s entirely arbitrary (how long<br>
it actually takes depends on the load on and the whims of the<br>
scheduler.) &nbsp;Taking longer than a second might indicate that the<br>
newly-created thread isn&#39;t getting enough CPU time to signal its<br>
readiness to run, &nbsp;The whole notion of having a timeout for<br>
something that can take an indeterminate amount of time is<br>
questionable, so it probably makes sense to not use a one-second<br>
timeout in PROCESS-ENABLE by default, at the very least.<br>
<br>
Can you tell whether it was the first case (where PROCESS-ENABLE<br>
was waiting to enable a thread that - somehow - seems to have<br>
already been enabled) or the second (the one-second timeout is<br>
too short, and quite possibly the entire idea of a timeout is<br>
misguided) or the second ?<br>
<br>
In the former case, the thread being enabled would be on the<br>
list returned by (ALL-PROCESSES) or in the output displayed<br>
by :PROC, and in the latter case it wouldn&#39;t.<br>
<div><div></div><div class="Wj3C7c"><br>
On Fri, 25 Jul 2008, Milan Jovanovic wrote:<br>
<br>
&gt; Hi, i have problems with multi-threading on linux, i think it&#39;s the same<br>
&gt; like &quot;<a href="http://trac.clozure.com/openmcl/ticket/297" target="_blank">http://trac.clozure.com/openmcl/ticket/297</a>&quot;<br>
&gt; First it was &quot;Unable to enable process #&lt;PROCESS ...have been trying for 1<br>
&gt; seconds&quot; and inferior-list segmentation fault after 2-3 hours of running<br>
&gt; (this was on SUSE LINUX 10.0 X86-64 2.6.13-15-smp)<br>
&gt;<br>
&gt; After Gary Byers suggestion &nbsp;that it is meaby linux kernel bug i tried &nbsp;on<br>
&gt; SUSE Server 10 (x86_64) - &nbsp;kernel <a href="http://2.6.24." target="_blank">2.6.24.</a> After more then day of running<br>
&gt; with no errors i saw one more &nbsp;&quot;Unable to enable process #&lt;PROCESS ...have<br>
&gt; been trying for 1 seconds&quot; but this time no segmentation fault.<br>
&gt; So I&#39;m asking is it problem/bug if this happens &nbsp;or only if it happens with<br>
&gt; segmentation fault following ?<br>
&gt;<br>
&gt; btw. i tried code on sbcl to be sure that it&#39;s not something there and it&#39;s<br>
&gt; running couple of days with no problems<br>
&gt;<br>
&gt; Thanks<br>
&gt; Best,Milan<br>
&gt;<br>
</div></div>_______________________________________________<br>
Openmcl-devel mailing list<br>
<a href="mailto:Openmcl-devel@clozure.com">Openmcl-devel@clozure.com</a><br>
<a href="http://clozure.com/mailman/listinfo/openmcl-devel" target="_blank">http://clozure.com/mailman/listinfo/openmcl-devel</a><br>
</blockquote></div><br></div>