[Q][VM][ENH][RFH][COMP] Request For Help : CompilerPlugin

Tim Rowledge tim at sumeru.stanford.edu
Wed Apr 3 03:35:43 UTC 2002


"PhiHo Hoang" <phiho.hoang at rogers.com> is claimed by the authorities to have written:


> 	I think the best solution is a backend to the Squeak compiler to
> generate C/C++.
You're going to have to help me a bit here; why? So you change the compiler to
produce C instead of bytecodes - ok I could just about imagine that. Ugly, but
I wouldn't claim that reading bytecodes is much better. Now what? You spawn off
a process (OS proces, heavy weight, takes ages to get moving, not possible on
all machines) to run gcc on your generated code. It will need a bunch of
background info to make sense of your little converted method; globals,
instvars, class vars, etc. Obviously it can be done - Claus did it for ST/X
some time ago. I'm not sure it has a particularly obvious payoff though.
Remember that you're not going to get any enormous speedup for general
Smalltalk code; messages still have to be sent, bounds have to be checked etc.

> 	My gut feeling is that, a CompilerPlugin would help quite a bit
> to attain the goal of a really modular Squeak. I think the proof is in
> 'gst', SmallScript (?).
An execution engine that is modularized is certainly a useful possibility as
I've said many times before. I do have trouble seeing C generation (beyond what
we have for vm code) as being much of a benefit though. Personally I'd rather
not even have C involved there either :-)

tim
-- 
Tim Rowledge, tim at sumeru.stanford.edu, http://sumeru.stanford.edu/tim
Fractured Idiom:- POSH MORTEM - Death styles of the rich and famous




More information about the Squeak-dev mailing list