[Vm-beginners] MicroSqueak's Interpreter

Chris Cunnington smalltalktelevision at gmail.com
Sat Jan 8 21:21:12 UTC 2011


MicroSqueak comes with an Interpreter class. InterpreterSupportCode 
writeMacSourceFiles spits out:

msq.h
msqFilePrims.c
msqMain.c
msqMiscPrims.c
projectArchive.sit (which opens up into MicroSqueak VM.proj)

The README mentions an interp.c, which doesn't appear anywhere.

These files are from 1999 and PPC, so I'd imagine compiling from these 
is not feasible.
But they point to an interesting direction for learning how to make a 
vm: a tiny set of files.

sq.h and interp.c are clearly required. The README gives the impression 
the .c files are where the options are. Connecting to to stdio.h is 
important, of course.

A good approach would be to have somebody list equivalent files produced 
by the current VM.
Maybe /platforms/Cross/vm:

sq.h
sqMemoryAccess.h
sqNamedPrims.c
sqVirtualMachine.c
sqVirtualMachine.h
and,
/platforms/unix/src/interp.c

If somebody could point to a subset of what the VMBuilderTool produces, 
I think it could go a long way to making vm hacking more approachable. I 
understand that any file set would need some doctoring, but even so, 
looking at five files is something that wouldn't make a beginner balk.

Any suggestions as to a tight subset for me to explore and compile on my 
Mac using the process described in Adrian's blog would be greatly 
appreciated.

Then I could see the relationship to MicroSqueak's 56k image. :)
Actually, I guess you have to see what the image does and then work back 
to the capabilities available in the vm. Anyway...you get the idea.


Chris








More information about the VM-beginners mailing list