Support an updated image format number for Sista

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Support an updated image format number for Sista

David T. Lewis
Hi Eliot,

This is a belated follow up on earlier private discussion during a Squeak
board meeting a few months ago, in which we agreed that identifying
"Sista in use" in the image format number would be a useful thing to do.
I previously added the documentation for this in ImageFormat-dtl.39.mcz
(as well as the updated ckformat.c program to match).

Attached here is a change set that can be loaded into a VMMaker image to
add VM support for setting and reading the updated image format numbers.
Here I used a primitive to initially set or clear the "sista bit". There
are other ways this could be done, but this at least gets us started
with a working implementation.

By way of explanation, I am copying below both the change set preamble
and the earlier ImageFormat commit notice:

===

  Change Set: VMM-Sista-bit-dtl
  Date: 12 January 2020
  Author: David T. Lewis
 
  Let the image inform the interpreter that alternate bytecodes either are
  or are not in use, and remember that setting when writing or reading the
  image format number in a shapshot file header.
 
  Provide primitiveMultipleBytecodesActive to allow the setting to be updated
  from the image. Expected usage is that the image can call this primitive
  after recompiling with Systa bytecodes, or after reverting back. Note that
  an alternative implemenation would be to use a VM parameter. The primitive
  was chosen here because it can perform parameter checking and does not
  require coordinated update the the VM parameter usage.
 
  Expected usage is that this feature will remain unused for some grace period
  (perhaps a few months) during which an updated VM can be widely circulated.
  After that period, images using Sista bytecodes may be safely saved with the
  updated image format number indicating that multiple bytecodes are in use.
 
  This change set includes helper methods in SmalltalkImage for testing or
  setting the multipleBytecodeSetsActive setting in the VM.
 
  Note the change set postscript which is necessary for initializing a class
  variable prior to code generation.

===

  Name: ImageFormat-dtl.37
  Author: dtl
  Time: 20 July 2019, 5:23:59.004 pm
  UUID: 52b464d5-0bf7-4326-bde3-4f18ad70b239
  Ancestors: ImageFormat-dtl.36
 
  Identify extended bytecodes for Sista in the image format number. Bit 10
  identifies an image that contains extended bytecodes. Thus a 32 bit Spur
  image is 6521, with Sista it is 7033, and a 64 bit Spur image is 68021,
  with Sista it is 68533.
 
  It is expected that additional bytecode sets can be identified by an
  additional field in the image header, probably 32 bits containing two
  16 bit fields,  if both zero then Sista.
 
  Per discussion with Eliot and Bert in a Squeak oversight board meeting
  2019-05-15.


Dave




VMM-Sista-Imageformat-dtl.6.cs (13K) Download Attachment