step of work  som 4.0

1  use som31a as the initial vm that runs som3 compiler (som v 3.1) to develop som 4.0.
2  the initial som 4.0 compiler is based on som4.txt (som v 3.5) in the directory som.
3  change som4.txt to generate u-code.  Test it with small benchmarks.
4  then som4.0 vm is written based on som 3.1 vm.
5  final test for som4.obj is to compile som4.txt itself using som4.0 vm.

let som31 be the base vm, som30.obj be the base compiler, som4.txt be the new compiler (dir som).

compile and generate the new compiler som4.obj. run the new compiler to compile a test program.

>som/som31 (som30.obj) som4.txt 
>som/som31 -c som4.obj test.txt

To modify the base vm for debugging. use the directory som-v31a to generate a new som31a. To modify the base compiler for debugging, use the directory som3, with som31a (som30.obj) to compile this modified compiler, name it som30a.obj. Then you can use these modified system to compile som4.txt and then run it to compile the test program.

The project som31a generates som31a.exe to the directory som.

>som3/som31 (som30.obj) som3.txt -> som30a.obj
>som/som31 -c som30a.obj som4.txt
>som/som31a -c som4.obj test.txt

Create som 4.0 vm (on root dir som4) -> som4.exe. use it to run test.obj, once successful then use it to compile the new compiler.  Name the new compiler som40.txt.

>som4 -x test.obj  (the new vm)
>som/som31a -c som4.obj som40.txt -> som40.obj (gen new obj)
>som4 -c som40.obj test.txt  (the new compiler) 

how to measure som 4.0 performance?

compare to som v 3.1.

small benchmarks: noi, running time.
compiler: compile som3.txt, measure noi, running time.

For compiler, this is not a measure of "goodness" of som3.txt, so the execution of som3.txt is not considered. The compiler benchmark measures the "goodness" of som v 3.1 vs som v 4.0 in compiling a medium size program (i.e. som3.txt). The running times are for the different compilers, i.e. som v3.1 compiler vs som v4.0 compiler. For small benchmarks, the quality of the output code is measured. So, the claim is that for small benchmarks som 4.0 produces a faster/slower executable, for compiler benchmark, som 4.0 compiles faster/slower than som 3.1.

15 Mar 2008

