[Vm-dev] [squeak-dev] Image Segment semantics and weakness

Bert Freudenberg bert at freudenbergs.de
Wed Oct 22 05:05:15 UTC 2014

On 20.10.2014, at 18:55, Mariano Martinez Peck <marianopeck at gmail.com> wrote:

> The few users I found, were NOT using the real purpose of ImageSegment, that is, object swapping. It was used instead as an object serializer. For that, they use #writeForExportOn: which ended up using SmartRefStream for the rest of the objects.   

Well, if you look closer, you will see that projects use image segments in two completely different ways. One is, as you say, for serialization, which is not the best use of image segments, agreed, especially with all the other logic wrapped around it.

But if you enable projectsSentToDisk then entering a project will swap the previous project to disk as an image segment, allowing you to have images with very large projects without having to hold all in main memory at the same time. 

This uses a completely different code path and file format than regular project export. The same technique could be used to swap out arbitrary chunks of an image.

- Bert -

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4142 bytes
Desc: not available
Url : http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20141021/d2afed45/smime.bin

More information about the Vm-dev mailing list