why push self bytecode?
Jecel Mattos de Assumpcao Jr. kofuji
jecel%lsi.usp.br at Forsythe.Stanford.EDU
Wed Sep 1 20:20:42 UTC 1993
Just a silly thought:
Why is there a "push self" bytecode instead of "self send X" with
literal X="self"? I can see it would make programs a little larger
to have the extra literals, but would there be any other problems?
The compiler would take care of the "self send X" with the rest
of the argument slots, right?
Another thing - I can see that the omission of "POP" bytecodes at
the end of a statement ( at the "." ) will make code smaller and
the instruction set simpler. The lost information is generated again
by the compiler at data flow analysis time. It does make a Self
interpreter or very simple compiler work harder.
Actually, I really like the bytecodes the way they now. It's just
that it is interesting to know why things were designed the way
- Jecel Assumpcao Jr
University of Sao Paulo - Brazil
More information about the Self-interest