[Vm-dev] VM Maker: ImageFormat-dtl.14.mcz

David T. Lewis lewis at mail.msen.com
Thu Nov 1 11:58:03 UTC 2012


On Thu, Nov 01, 2012 at 11:52:21AM +0000, commits at source.squeak.org wrote:
>  
> David T. Lewis uploaded a new version of ImageFormat to project VM Maker:
> http://source.squeak.org/VMMaker/ImageFormat-dtl.14.mcz
> 
> ==================== Summary ====================
> 
> Name: ImageFormat-dtl.14
> Author: dtl
> Time: 1 November 2012, 7:52:14.48 am
> UUID: 76bad473-3b56-48fa-8fa7-80d8c7afc523
> Ancestors: ImageFormat-dtl.13
> 
> Add updates to ImageFormat to report #availableBits and bitAssignments.
> 
> Add ImageFileHeader and CogImageFileHeader with tests in ImageFileHeaderTest.
> 
> The purpose of ImageFileHeader is to document the current formats of Cog and interpreter image file headers, and to provide a convenient way to inspect the data values an image file header.
> 
> To explore the file header of an image file:
> 
>   | fs |
>   fs := (FileStream readOnlyFileNamed: Smalltalk imageName) binary.
>   ([CogImageFileHeader readFrom: fs] ensure: [fs close]) explore
> 

The image file header is the first 64 (or 128) bytes of an image file, which
is followed by a copy of the object memory proper. The ImageFileHeader classes
allow the header to be read from disk into an object that is easy to inspect.
This is a stand alone package that can be loaded independently of VMMaker.

Example attached.

Dave

-------------- next part --------------
A non-text attachment was scrubbed...
Name: CogImageFileHeader.png
Type: image/png
Size: 35734 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20121101/77cc148a/CogImageFileHeader-0001.png


More information about the Vm-dev mailing list