[M3devel] AMD64_LINUX gc/stubgen
Jay
jay.krell at cornell.edu
Mon Nov 10 09:28:18 CET 2008
@M3paranoidgc always succeeds. I see, reading the code, it only does reads. Nevertheless.
Simply programs that just allocate memory forever also succeed.
Such as this:
jay at amd64a:/dev2/cm3/t$ cat src/t.m3MODULE t EXPORTS Main;
TYPE T1 = RECORD c : ARRAY [0..10000000] OF INTEGER; END;TYPE T2 = RECORD c : ARRAY [0..4095] OF INTEGER; END;
VAR a: REFANY;
PROCEDURE F1()=VAR b: REFANY;
BEGIN WHILE TRUE DO b := NEW(REF T2); a := NEW(REF T1); END;END F1;
BEGIN F1();END t.
Darn.
- Jay
From: hosking at cs.purdue.eduTo: jay.krell at cornell.eduDate: Sun, 9 Nov 2008 18:02:41 +0000CC: m3devel at elegosoft.comSubject: Re: [M3devel] AMD64_LINUX gc/stubgen
Clearly a problem with GC. I'm guessing you have something wrong (pointer alignment?) in the configuration. I suspect if you run with @M3paranoidgc you'll trip over the problem.
On 9 Nov 2008, at 14:09, Jay wrote:
Tony, any tips on this one? :) jay at amd64a:~/dev2/cm3/m3-ui/zeus/AMD64_LINUX$ /cm3/bin/stubgen -v1 -sno RemoteView.T -T.M3IMPTAB @M3nogc always succeeds. jay at amd64a:~/dev2/cm3/m3-ui/zeus/AMD64_LINUX$ /cm3/bin/stubgen -v1 -sno RemoteView.T -T.M3IMPTAB usually fails:****** runtime error:*** NEW() was unable to allocate more memory.*** file "../src/runtime/common/RTAllocator.m3", line 285***Formatter.m3: CONST ChunkSize = 128; (* Must be a power of 2 *)PROCEDURE New(wr: Wr.T; width: CARDINAL:= 75): T RAISES {} = BEGIN WITH t = NEW(T) DO t.wr := wr; t.width := width; t.indent := 0; t.numChars := 0; (* t.stream := RefStream{NIL, ..}; *) t.buffer := NEW (ExprBuf, 4 * ChunkSize); << this is the line that fails Lowering chunk size to 64 seemed to make it succeed more often, but not always.I think I'll go back to MIPS64_OPENBSD..probably easier to track that problem down. - Jay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20081110/da2e695b/attachment-0002.html>
More information about the M3devel
mailing list