[Vm-dev] Cuis Spur preview

Juan Vuletich JuanVuletich at zoho.com
Sat Jul 30 21:05:14 UTC 2016


Hi Eliot, Folks,

Eliot and I have been been working a bit, over some time, to make Cuis 
compatible with the Spur VMs. We prepared together the changes required 
to make the Cuis image ready for the Spur bootstrap process (also used 
for Newspeak, Squeak and Pharo). Eliot made any necessary changes to the 
Spur bootstrap to also handle Cuis. (Eliot, you might want to give 
additional details on what was required here?).

The result of the Spur bootstrap was a Cuis image that could start, but 
could do little else. Compiler and Decompiler were broken, so fixing was 
hard.

Then I came with the idea of doing the same I did when converting Cuis 
to Closures: Have two Compilers loaded, and switch between them easily. 
So, I added the necessary changesets to the "PreSpurBootstrap" stage, 
adding a verbatim copy of Squeak's Compiler, and making it active. The 
result of the Spur bootstrap was now a Cuis image that could not only 
start, but also browse and modify code. There were still many rough 
edges, but now they can be fixed from within the image, as we usually 
do. I fixed the most obvious ones, as part of "PostSpurBootstrap".

The resulting image is available at 
https://www.dropbox.com/sh/45vub8hnq1riq10/AADDKBWsIvPfUNqjuz91PW7Ra/CuisSpurPreview?dl=0 
. The "PreSpurBootstrap" and "PostSpurBootstrap" changesets are there 
too, meaning that anybody can reproduce the procedure, and suggest fixes 
and enhancements.

This is not yet good enough to be added to the Cuis update stream. These 
are some of the things that are missing:

- Merge both Compilers into just one, that handles Cuis specific details 
correctly, but also includes any updates required for Spur.

- Check Decompiler. Decompile and recompile the code for all the system.

- Make the very same source code for the whole system work both for V3 
and Spur images. To build the Spur Cuis image, at the correct update 
number, the image is converted to Spur, and then run with a Spur VM, and 
the following updates are applied. To build a V3 image, the image is 
never converted to spur, and the very same updates are applied, always 
running with a non-Spur VM. This is not currently working, but I think 
it is possible, and allows both Spur and non-Spur Cuis images without 
forking.

- Check that optional packages work.

- Enable SmallFloat64, both as result of arithmetic, but also as 
literals in methods.

- Many details I'm not remembering right now, or I'm not aware of.

Eliot, let me than you for your wonderful work on Cog, Spur and Sista, 
for supporting Cuis along with the other OpenSmalltalk systems, and for 
guiding and encouraging me to keep Cuis up to date with latest VM 
technology.

Cheers,

-- 
Juan Vuletich
www.cuis-smalltalk.org
https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev
@JuanVuletich




More information about the Vm-dev mailing list