Re: [TCLCORE] Tcl through X rays
by Alexandre Ferrieux other posts by this author
May 25 2007 6:53AM messages near this date
Re: [TCLCORE] Tcl through X rays
|
Re: [TCLCORE] Tcl through X rays
On 5/25/07, Donal K. Fellows <donal.k.fellows@[...].uk> wrote:
>
> Alexandre Ferrieux wrote:
> > Now even for upvar, there are possibilities. Since in Tcl [upvar]ed vars
> > are accessed at runtime, it suffices to maintain enough data for a name
> > lookup in each stack frame.
>
> You are aware that this is very close to what we actually do? :-)
:-)
No, I'm not really aware since I have not read the thorough documentation of
the bytecode VM...
| The main difference is that variables aren't on the stack anyway, [for
deep reasons]
OK. Then remove the vars-on-stack of my proposal, yielding:
proc foo {x} {bar $x; ...}
-->
.1 .checkargceq CALL
.x .set CALL
MARK MARK .x .set CALL .bar CALL
Then, you're saying that *this* is roughly equivalent to the current
bytecode VM ?
Sorry for reinventing that wheel...
So the bottom line is: how to isolate cases where locals (and proc
parameters as a special case) are handled in a completely traditional way
(like in C), and hence can be moved to the stack, right ?
-Alex
Thread:
Alexandre Ferrieux
Donal K. Fellows
Alexandre Ferrieux
Mo DeJong
Alexandre Ferrieux
Mo DeJong
Jeff Hobbs
Andreas Leitgeb
Donal K. Fellows
Alexandre Ferrieux
Larry McVoy
Donal K. Fellows
Donal K. Fellows
Alexandre Ferrieux
Miguel Sofer
Rna020
Donal K. Fellows
Donal K. Fellows
Gerald W. Lester
Donal K. Fellows
|