Hi:<br>LINUXLIBC6 32 bits, ubuntu dapper<br><br>>Hmm. showheap works fine for me on my I386_DARWIN box. What <br>>platform are you on?<br><br>On Oct 30, 2007, at 2:24 AM, Daniel Alejandro Benavides D. wrote:<br><br>> Hi:<br>> About this last changes, the runtime can not properly<br>> feed shownew, with a @M3shownew=shownew.<br>> The program 'a' is just not started as it seems here,<br>> altough the window (shownew) does appear, start<br>> doesn't respond, and it stays there until aborted.<br>><br>> Thanks<br>><br>> --- "Daniel Alejandro Benavides D."<br>> escribió:<br>><br>>> Hi:<br>>> Yes it's working very well. I'm sorry for the delay.<br>>> Thanks.<br>>> --- Tony Hosking escribió:<br>>><br>>>> Please try the latest CVS head.<br>>>><br>>>> On Oct 21, 2007, at 6:03 PM, Daniel Alejandro<br>>>> Benavides D. wrote:<br>>>><br>>>>>
Hi:<br>>>>> Im trying to execute the following program with<br>>>> the Pthread cvs<br>>>>> head implementation and I got this when<br>>> executing<br>>>> the program:<br>>>>><br>>>>> danielb@danielb-desktop:~/as207/code/m3gdb$<br>>>> LINUXLIBC6/Main<br>>>>> Entre dos enteros6 7<br>>>>> Estadisticas del Heap<br>>>>> HEAP: 0xb73d2000 .. 0xb7412000 => 0.2 Mbytes<br>>>>><br>>>>><br>>>>> ***<br>>>>> *** runtime error:<br>>>>> *** <*ASSERT*> failed.<br>>>>> *** file<br>>>> "../src/thread/PTHREAD/ThreadPThread.m3", line 992<br>>>>> ***<br>>>>><br>>>>> Aborted<br>>>>> danielb@danielb-desktop:~/as207/code/m3gdb$<br>>>>><br>>>>> The assert violated in<br>>>>
m3core/thread/PTHREAD/ThreadPthread.m3 is this:<br>>>>> PROCEDURE ProcessOther (act: Activation; p:<br>>>> PROCEDURE (start,<br>>>>> stop: ADDRESS)) =<br>>>>> (* LL=activeMu *)<br>>>>> VAR<br>>>>> sp: ADDRESS;<br>>>>> state: RTMachine.ThreadState;<br>>>>> BEGIN<br>>>>> <*ASSERT act.state = ActState.Stopped*><br>>>>><br>>>>><br>>>>> The source code of the little program is this:<br>>>>><br>>>>> MODULE Main;<br>>>>><br>>>>> IMPORT SIO;<br>>>>> IMPORT RTHeapStats;<br>>>>> IMPORT RTutils;<br>>>>> IMPORT RTHeapDebug;<br>>>>> VAR<br>>>>> varA, varB, varC: INTEGER;<br>>>>><br>>>>><br>>>>> PROCEDURE multiplicar(a,b: INTEGER): INTEGER=<br>>>>>
VAR<br>>>>> varC: INTEGER;<br>>>>> BEGIN<br>>>>> varC:=a*b;<br>>>>> RETURN varC;<br>>>>> END multiplicar;<br>>>>><br>>>>><br>>>>> BEGIN<br>>>>><br>>>>> SIO.PutText("Entre dos enteros");<br>>>>> varA:=SIO.GetInt();<br>>>>> varB:=SIO.GetInt();<br>>>>> varC:=multiplicar(varA,varB);<br>>>>> SIO.PutText("Estadisticas del Heap");<br>>>>> RTHeapDebug.CheckHeap();<br>>>>> RTHeapStats.ReportReachable();<br>>>>> (* RTutils.Heap<br>>>>><br>>>><br>>><br>> (FALSE,RTutils.HeapPresentation.ByTypecode,TRUE,LAST(CARDINAL));*)<br>>>>> SIO.PutInt(varC);<br>>>>><br>>>>> END Main.<br>>>>><br>>>>> According to the
draft book of Michael Dagenais<br>>>> Building<br>>>>> Distributed OO Applications: Modula-3 Objects<br>>> at<br>>>> Work,<br>>>>> RTHeapStats.ReportReachable()<br>>>>> " ... is called to determine the number<br>>>>> of active, reachable, objects (i.e. those which<br>>>> would not be<br>>>>> garbage collected). Of the 1980 objects on the<br>>>> heap, only slightly<br>>>>> more than half are still alive."<br>>>>><br>>>>> According to the interface documentation:<br>>>>> "reports the number of reachable objects and<br>>>> bytes from each<br>>>>> compilation unit, thread stack, and the<br>>> individual<br>>>> roots that reach<br>>>>> the most bytes. The report is written to stderr.<br>>>> The Modula-3<br>>>>> process is frozen during the scanning
and<br>>>> reporting."<br>>>>><br>>>>> Obviously with the previous version of pthread<br>>> the<br>>>> things were<br>>>>> working fine, also with user level<br>>> implementation<br>>>>><br>>>>> Thanks,<br>>>>><br>>>>> Daniel Benavides<br><div> </div><hr size="1"><p>
<hr size=1><br><font face="Verdana" size="-2">¡Descubre una nueva forma de obtener respuestas a tus preguntas!<br><a href="http://us.rd.yahoo.com/mail/es/tagline/answers/*http://es.answers.yahoo.com/;_ylc=X3oDMTEzNWwxbTZtBF9TAzIxMTQ3MTQxOTAEc2VjA01haWwEc2xrA3RhZ2xpbmVz">Entra en Yahoo! Respuestas</a>.<br></font>