Re: Smalltalk Interchange Format [was Xtreams : first embryonary port on Squeak]

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

Re: Smalltalk Interchange Format [was Xtreams : first embryonary port on Squeak]

Nicolas Cellier
Thanks Bill,
some of the link on this page seem dead though...

Nicolas

2010/10/10 Schwab,Wilhelm K <[hidden email]>:

> FWIW, SIF might help you:
>
>   http://www.pocketsmalltalk.com/sif/
>
> I have put a lot of code through it in the past couple of years.
>
>
> ________________________________________
> From: [hidden email] [[hidden email]] On Behalf Of Nicolas Cellier [[hidden email]]
> Sent: Saturday, October 09, 2010 6:33 PM
> To: The general-purpose Squeak developers list; Pharo Development; [hidden email]
> Subject: [Pharo-project] Xtreams : first embryonary port on Squeak
>
> So, I started a quick port of VW Xtreams to Squeak this evening.
> Only the Xtreams-Core and the trivial Xtreams-Terminals (no
> file/pipe/socket/pointer).
> You'll find code at http://www.squeaksource.com/XTream.
> My previous experimental Xtream project has been renamed SqueaXTream
> to reduce confusion, but still sits in the same project.
> Please find my report below.
>
> cheers
>
> Nicolas
>
> --------------------- REPORT  ---------------------
>
> THE CONTENTS:
>
> This first port is made of 3 packages
> - Xtreams-Core
> - Xtreams-Terminals
> - Xtreams-VWCompatible
> Plus 2 tests
> - Xtreams-CoreTests
> - Xtreams-TerminalsTests
> Please notice I removed one hyphen from test package names for MC compatibility.
>
> THE PROCEDURE:
>
> I didn't use FileOut30 not any more advanced tool, but just a simple
> copy/paste strategy.
> This gave me a chance to do a fast review of code.
> For porting the future evolutions of VW Xtreams, more advanced tools
> will be necessary, the manual approach does not scale.
>
> THE MODIFICATIONS:
>
> The changes I made are quite restricted, which indicates that Xtreams
> is not that hard to port.
> Main changes are due to lack of namespace in Squeak:
> - I added a XT prefix to every Xtreams classes (no Namespace in Squeak)
> - I added XTPools, a SharedPool for holding the single Xtreams
> namespace variable DefaultBufferSize
> - I transformed class SharedVariables into class variables and added
> proper class side initialization for these in XTWriteStream
>
> For the rest, I tried to not change Xtreams contents. but rather did
> implement VW compatible messages when possible in the
> Xtreams-VWCompatible package when they did not exist in Squeak.
> These message are a full rewrite and are also released under MIT license.
> The few exceptions are:
> - I modified originator -> self originator in XTIncomplete.
> - I changed the senders of #newInFixedSpace: to rather send an #error:
> 'not implemented in Squeak' in XTRecyclingBuffer
> - I replaced #waitIfCurtailedSignal/#signal with a #critical: section
> in XTRecyclingBuffer
> - I replaced  Core.Timer after:do: with self after:do: in Xtreams-CoreTests
>
> A DISCUSSION OF TECHNICAL DETAILS:
>
> I first attempted to replace #growToAtLeast: with #grownBy: because
> Squeak become: is notoriously inefficient.
> But obviously, this did not work, the tests rely on destination
> preserving its identity.
> This clearly is going to degrade micro benchmarks when the destination
> collection capacity is not well adjusted in advance.
> I think we should discuss this particular point. Is identity
> preservation absolutely required, or just convenient ?
>
> THE STATUS OF TESTS:
>
> Tests do not all pass. There seems to be a bug in Squeak
> #replace:from:to:with: when the replacement is the collection itself,
> moved to the right (this is with a COG VM).
>
> THE FUTURE:
>
> I will probably continue porting with reduced activity, so I invite
> any interested person to help. Right now, the project is world
> writeable, code commited here falling under MIT license.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Smalltalk Interchange Format [was Xtreams : first embryonary port on Squeak]

Schwab,Wilhelm K
Nicolas,

Can you get sifall.zip?  That's what I use.  Sadly I am not sure about the license, so while I have no worries about directing you to the source, I am not in a hurry to host it myself.  It's old, but I was impressed at how well it worked at getting code out of Dolphin.  Pharo/MC acts a little badly about some of the *xzy category names that result, but nothing so bad that you can't fix them with a text editor, the regex package, or by browsing/editing offending names.

Bill



________________________________________
From: [hidden email] [[hidden email]] On Behalf Of Nicolas Cellier [[hidden email]]
Sent: Sunday, October 10, 2010 2:48 PM
To: [hidden email]
Subject: Re: [Pharo-project] Smalltalk Interchange Format [was Xtreams : first embryonary port on Squeak]

Thanks Bill,
some of the link on this page seem dead though...

Nicolas

2010/10/10 Schwab,Wilhelm K <[hidden email]>:

> FWIW, SIF might help you:
>
>   http://www.pocketsmalltalk.com/sif/
>
> I have put a lot of code through it in the past couple of years.
>
>
> ________________________________________
> From: [hidden email] [[hidden email]] On Behalf Of Nicolas Cellier [[hidden email]]
> Sent: Saturday, October 09, 2010 6:33 PM
> To: The general-purpose Squeak developers list; Pharo Development; [hidden email]
> Subject: [Pharo-project] Xtreams : first embryonary port on Squeak
>
> So, I started a quick port of VW Xtreams to Squeak this evening.
> Only the Xtreams-Core and the trivial Xtreams-Terminals (no
> file/pipe/socket/pointer).
> You'll find code at http://www.squeaksource.com/XTream.
> My previous experimental Xtream project has been renamed SqueaXTream
> to reduce confusion, but still sits in the same project.
> Please find my report below.
>
> cheers
>
> Nicolas
>
> --------------------- REPORT  ---------------------
>
> THE CONTENTS:
>
> This first port is made of 3 packages
> - Xtreams-Core
> - Xtreams-Terminals
> - Xtreams-VWCompatible
> Plus 2 tests
> - Xtreams-CoreTests
> - Xtreams-TerminalsTests
> Please notice I removed one hyphen from test package names for MC compatibility.
>
> THE PROCEDURE:
>
> I didn't use FileOut30 not any more advanced tool, but just a simple
> copy/paste strategy.
> This gave me a chance to do a fast review of code.
> For porting the future evolutions of VW Xtreams, more advanced tools
> will be necessary, the manual approach does not scale.
>
> THE MODIFICATIONS:
>
> The changes I made are quite restricted, which indicates that Xtreams
> is not that hard to port.
> Main changes are due to lack of namespace in Squeak:
> - I added a XT prefix to every Xtreams classes (no Namespace in Squeak)
> - I added XTPools, a SharedPool for holding the single Xtreams
> namespace variable DefaultBufferSize
> - I transformed class SharedVariables into class variables and added
> proper class side initialization for these in XTWriteStream
>
> For the rest, I tried to not change Xtreams contents. but rather did
> implement VW compatible messages when possible in the
> Xtreams-VWCompatible package when they did not exist in Squeak.
> These message are a full rewrite and are also released under MIT license.
> The few exceptions are:
> - I modified originator -> self originator in XTIncomplete.
> - I changed the senders of #newInFixedSpace: to rather send an #error:
> 'not implemented in Squeak' in XTRecyclingBuffer
> - I replaced #waitIfCurtailedSignal/#signal with a #critical: section
> in XTRecyclingBuffer
> - I replaced  Core.Timer after:do: with self after:do: in Xtreams-CoreTests
>
> A DISCUSSION OF TECHNICAL DETAILS:
>
> I first attempted to replace #growToAtLeast: with #grownBy: because
> Squeak become: is notoriously inefficient.
> But obviously, this did not work, the tests rely on destination
> preserving its identity.
> This clearly is going to degrade micro benchmarks when the destination
> collection capacity is not well adjusted in advance.
> I think we should discuss this particular point. Is identity
> preservation absolutely required, or just convenient ?
>
> THE STATUS OF TESTS:
>
> Tests do not all pass. There seems to be a bug in Squeak
> #replace:from:to:with: when the replacement is the collection itself,
> moved to the right (this is with a COG VM).
>
> THE FUTURE:
>
> I will probably continue porting with reduced activity, so I invite
> any interested person to help. Right now, the project is world
> writeable, code commited here falling under MIT license.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project