[NTLK] Geek Alert: NewtonOS

Matthias Melcher mm at matthiasm.com
Thu Sep 4 15:50:38 EDT 2014


Since there were questions about this, I try a little bit better explanation:

I have three versions of the same NewtonOS function, depending on how I compile.

If I compile the emulator, I keep the ARM code and emulate it at run-time.

- This is Einstein. It works, is compatible, and we love it

If I compile the emulator, leaving the simulated functions active, I will get Pseudo-C code that uses the emulator for register and memory access, but the Pseudo-C code itself is compiled an runs natively. This faster than emulation, but slower than true native code.

- This method is already part of Einstein and works quite well. It can double the speed of individual functions, in the best cases much much more. But each function has to be marked for translation and verified later. At 20.000 or so function in the ROM, this is a lot of work, which is why we still need the emulator.

If I compile NewtSim, I am throwing the emulator out of the equation. I still use the same Pseudo-C code as above, but it now access RAM directly, skipping all the MMU emulation. It still uses a subset of the register emulation, which makes it somewhat slower than native code, but still much faster than the cases above. 

- Now this is the experimental part. Since we are missing the emulator, we are missing 19.994 functions of the ROM that have not been converted yet. Not all issues have benn solved, but at some point, I hope to be able to automatically translate the upper layer (or even all) of the ROM, making NewtonOS as close to a native app as possible.






More information about the NewtonTalk mailing list