Issues with SmartRefStream

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

Issues with SmartRefStream

Christoph Thiede

Hi all,


I was just trying to file out a complex Object graph via #saveOnFile and found two problems with the SmartRefStream:


First, uniclass instances cannot be written to the stream. In SmartRefStream >> #instVarInfo:, I get an #errorKeyNotFound because the uniclass name is looked up into the SmalltalkImage globals. Minimum example to reproduce:


Object newSubclass new saveOnFile.


Second, blocks met during the file out process cannot be filed in again. Just try [] saveOnFile to reproduce this. Filein raises newMethodViaNewError. Maybe CompiledBlock should overwrite some streaming method for creating an appropriate disk representation?


Just wanted to report these issues. Maybe someone is more experienced with the SmartRefStream architecture and would like to fix these bugs. :-)

Best,
Christoph


Carpe Squeak!
Reply | Threaded
Open this post in threaded view
|

Re: Issues with SmartRefStream

Eliot Miranda-2
Hi Christoph,

On Sep 1, 2020, at 3:14 AM, Thiede, Christoph <[hidden email]> wrote:



Hi all,


I was just trying to file out a complex Object graph via #saveOnFile and found two problems with the SmartRefStream:


First, uniclass instances cannot be written to the stream. In SmartRefStream >> #instVarInfo:, I get an #errorKeyNotFound because the uniclass name is looked up into the SmalltalkImage globals. Minimum example to reproduce:


Object newSubclass new saveOnFile.


Second, blocks met during the file out process cannot be filed in again. Just try [] saveOnFile to reproduce this. Filein raises newMethodViaNewError. Maybe CompiledBlock should overwrite some streaming method for creating an appropriate disk representation?

My guess is that class side code in CompiledMethod should be moved up to CompiledCode, the common superclass of CompiledMethod and CompiledBlock.

Just wanted to report these issues. Maybe someone is more experienced with the SmartRefStream architecture and would like to fix these bugs. :-)

Best,
Christoph



Reply | Threaded
Open this post in threaded view
|

Re: Issues with SmartRefStream

Christoph Thiede

Hi Eliot,


generalization would have been my first idea, too, but I did not yet found the relevant piece of code ...


Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Eliot Miranda <[hidden email]>
Gesendet: Dienstag, 1. September 2020 17:29:11
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] Issues with SmartRefStream
 
Hi Christoph,

On Sep 1, 2020, at 3:14 AM, Thiede, Christoph <[hidden email]> wrote:



Hi all,


I was just trying to file out a complex Object graph via #saveOnFile and found two problems with the SmartRefStream:


First, uniclass instances cannot be written to the stream. In SmartRefStream >> #instVarInfo:, I get an #errorKeyNotFound because the uniclass name is looked up into the SmalltalkImage globals. Minimum example to reproduce:


Object newSubclass new saveOnFile.


Second, blocks met during the file out process cannot be filed in again. Just try [] saveOnFile to reproduce this. Filein raises newMethodViaNewError. Maybe CompiledBlock should overwrite some streaming method for creating an appropriate disk representation?

My guess is that class side code in CompiledMethod should be moved up to CompiledCode, the common superclass of CompiledMethod and CompiledBlock.

Just wanted to report these issues. Maybe someone is more experienced with the SmartRefStream architecture and would like to fix these bugs. :-)

Best,
Christoph



Carpe Squeak!
Reply | Threaded
Open this post in threaded view
|

Re: Issues with SmartRefStream

Eliot Miranda-2
Hi Christoph, Hi Marcel (cuz you're in the timestamp)

    In NativeImageSegment>>rootsIncludingBlock[Method]s are two "anOut class == CompiledMethod" that should probably be anOut isCompiledCode.

On Tue, Sep 1, 2020 at 8:46 AM Thiede, Christoph <[hidden email]> wrote:

Hi Eliot,


generalization would have been my first idea, too, but I did not yet found the relevant piece of code ...


Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Eliot Miranda <[hidden email]>
Gesendet: Dienstag, 1. September 2020 17:29:11
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] Issues with SmartRefStream
 
Hi Christoph,

On Sep 1, 2020, at 3:14 AM, Thiede, Christoph <[hidden email]> wrote:



Hi all,


I was just trying to file out a complex Object graph via #saveOnFile and found two problems with the SmartRefStream:


First, uniclass instances cannot be written to the stream. In SmartRefStream >> #instVarInfo:, I get an #errorKeyNotFound because the uniclass name is looked up into the SmalltalkImage globals. Minimum example to reproduce:


Object newSubclass new saveOnFile.


Second, blocks met during the file out process cannot be filed in again. Just try [] saveOnFile to reproduce this. Filein raises newMethodViaNewError. Maybe CompiledBlock should overwrite some streaming method for creating an appropriate disk representation?

My guess is that class side code in CompiledMethod should be moved up to CompiledCode, the common superclass of CompiledMethod and CompiledBlock.

Just wanted to report these issues. Maybe someone is more experienced with the SmartRefStream architecture and would like to fix these bugs. :-)

Best,
Christoph




--
_,,,^..^,,,_
best, Eliot


Reply | Threaded
Open this post in threaded view
|

Re: Issues with SmartRefStream

Christoph Thiede

This does not help, unfortunately.


Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Eliot Miranda <[hidden email]>
Gesendet: Dienstag, 1. September 2020 17:53:06
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] Issues with SmartRefStream
 
Hi Christoph, Hi Marcel (cuz you're in the timestamp)

    In NativeImageSegment>>rootsIncludingBlock[Method]s are two "anOut class == CompiledMethod" that should probably be anOut isCompiledCode.

On Tue, Sep 1, 2020 at 8:46 AM Thiede, Christoph <[hidden email]> wrote:

Hi Eliot,


generalization would have been my first idea, too, but I did not yet found the relevant piece of code ...


Best,

Christoph


Von: Squeak-dev <[hidden email]> im Auftrag von Eliot Miranda <[hidden email]>
Gesendet: Dienstag, 1. September 2020 17:29:11
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] Issues with SmartRefStream
 
Hi Christoph,

On Sep 1, 2020, at 3:14 AM, Thiede, Christoph <[hidden email]> wrote:



Hi all,


I was just trying to file out a complex Object graph via #saveOnFile and found two problems with the SmartRefStream:


First, uniclass instances cannot be written to the stream. In SmartRefStream >> #instVarInfo:, I get an #errorKeyNotFound because the uniclass name is looked up into the SmalltalkImage globals. Minimum example to reproduce:


Object newSubclass new saveOnFile.


Second, blocks met during the file out process cannot be filed in again. Just try [] saveOnFile to reproduce this. Filein raises newMethodViaNewError. Maybe CompiledBlock should overwrite some streaming method for creating an appropriate disk representation?

My guess is that class side code in CompiledMethod should be moved up to CompiledCode, the common superclass of CompiledMethod and CompiledBlock.

Just wanted to report these issues. Maybe someone is more experienced with the SmartRefStream architecture and would like to fix these bugs. :-)

Best,
Christoph




--
_,,,^..^,,,_
best, Eliot


Carpe Squeak!