[Vm-dev] VM Maker: VMMaker.oscog-eem.2347.mcz

tim Rowledge tim at rowledge.org
Sat Mar 10 18:24:40 UTC 2018



> On 10-03-2018, at 4:27 AM, Clément Bera <bera.clement at gmail.com> wrote:
> 
> Another thing you can do is to simulate the simulator itself, so you can look at the code, the execution from the outside and from the inside at the same time. See picture below
> 
> | cos |
> cos := StackInterpreterSimulator newWithOptions: #(ObjectMemory Spur32BitMemoryManager).
> cos desiredNumStackPages: 8.
> cos openOn: 'SpurVMMaker.image'.
> cos systemAttributes
> 		at: 2 put: '-doit';
> 		at: 3 put:	'| cos |
> cos := StackInterpreterSimulator newWithOptions: #(ObjectMemory Spur32BitMemoryManager).
> cos desiredNumStackPages: 8.
> cos openOn: ''SpurVMMaker.image''.
> cos openAsMorph; run'.
> 
> cos openAsMorph; run

That is rather more than a little bit cool. Even more fun - make one of the simulators be using the ARM cpu sim so you can simulate the simulation of simulating a different cpu whilst debugging the debugger debugger simulation. Or something like that; easy to get lost in the mirrors.

tim
--
tim Rowledge; tim at rowledge.org; http://www.rowledge.org/tim
Strange OpCodes: PBT: Prune Binary Tree




More information about the Vm-dev mailing list