[M3devel] another reminder -- jmpbuf size independence?
Jay K
jay.krell at cornell.edu
Thu Oct 4 18:17:37 CEST 2012
Agreed.
TRY
FOR i := 1 TO 100 DO TRY FOR j := 1 TO 100 DO END; FINALLYENDFINALLY
should have two variables, allocate 2 * sizeof(jmpbuf), call alloca twice (most likely -- obviously it could be optimized), not 200 times.
- Jay
CC: m3devel at elegosoft.com
From: antony.hosking at gmail.com
Subject: Re: [M3devel] another reminder -- jmpbuf size independence?
Date: Thu, 4 Oct 2012 09:25:14 -0400
To: jay.krell at cornell.edu
Don't you need separate jmpbuf per exception scope?
Sent from my iPad
On Oct 4, 2012, at 1:45 AM, Jay K <jay.krell at cornell.edu> wrote:
Along with cooperative suspend, it'd be great if jmpbuf size was not known to cm3.We know roughly how to fix this -- use alloca(Csetjmp_jmpbuf_size).At function entry. Not in any loop.Or possibly in loop, but with a null check.VAR jmpbuf: ADDRESS := NIL;LOOP IF jmpbuf = NIL THEN jmpbuf := alloca(Csetjmp_jmpbuf_size); END;
:)
Granted, I want all layout optionally out of the frontend, and this is only part of the problem.
Thanks, - Jay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://m3lists.elegosoft.com/pipermail/m3devel/attachments/20121004/e7a4cebb/attachment-0002.html>
More information about the M3devel
mailing list