som v5  step of work

1.  start with v19v.  Use queen benchmark to measure the baseline performance of the v19v-vm.
2.  to test "encoding", test the proposed format against v19v. Modify v19v interp.c to run queen object. Once the vm design is decided, write v5-vm. The first v5-vm should have some surplus code to run queen.obj (and other objects from v19v) as testers. 
3.  Write Som compiler. Use the latest som v4.2a as base code.  Also use v42a to compile som-v5.  Use small test program to check (visually) for correctness of the output object code.
4.  When the object is correct, test it with v5-vm.
5.  When v5-compiler is ready, use it to compile itself.  the output object code will be the new compiler object that run under v5-vm.

6 Oct 2009

1, 2  done  8 Oct 2009
3.  Restructuring the base code. Begin with separate "parser" from the rest.  This helps me to understand code.  Parser will also become an independent benchmark.
    The parser becomes "som5.txt" (not include code gen). I made a special version of som42a (som42b) to take command line argument to be the name of the file to parse and run the parser (som5.obj) on it.
    code generator has a difficulty concept:
    how to allocate new local for intermediate result? (genput)
    should genex always return a local? If so, at ret what local to return when there are more than one branch (such as 1 break)?

8 Oct 2009



