SqueakJS-Etoys-20140704

From Bert Freudenberg:

Hi all,

my SqueakJS VM has reached a major milestone. It is now sufficiently complete to run a full Etoys image (and possibly other non-closure images, too). It has support for most BitBlt modes, WarpBlt, even some Balloon2D rendering (for TTF fonts), a virtual file system, image saving etc.

Try it: http://bertfreudenberg.github.io/SqueakJS/etoys/
(Safari and IE are significantly faster than Firefox and Chrome, best is Safari Webkit nightly, works on iPad too, hopefully Android)

For more details, see my blogpost:

http://croquetweak.blogspot.de/2014/07/squeakjs-runs-etoys-now.html

Feedback and contributions welcome :)

- Bert -

First steps

 

(baby steps and giant leaps!)

From Eliot Miranda:

Hi All,

it gives me great pleasure to let you know that a spur-format trunk
Squeak image is finally available at
http://www.mirandabanda.org/files/Cog/SpurImages/. Spur VMs are available
at http://www.mirandabanda.org/files/Cog/VM/VM.r2987/.

Spur is a new object representation and garbage collector for
Squeak/Pharo/Croquet/Newspeak.

Features
The object representation is significantly simpler than the existing one,
and hence permits a lot of JIT optimizations, in particular allocating
objects in machine code. This speeds up new, new: et al, but also speeds
up blocks because contexts and closures are now allocated in machine code.
It also provides immediate characters, so for example accessing wide
strings is much faster in Spur, since characters do not have to be
instantiated to represent characters with codes greater than 255.

The garbage collector has a scavenger and a global scan-mark-compact
collector. The scavenger is significantly faster than the existing
pointer-reversal scan-mark-compact, hence GC performance is much improved.

The memory manager manages old space as a sequence of segments, as opposed
to the single contiguous space provided by the existing memory manager.
The memory manager grows the heap a segment at a time, and can and will
release empty segments back to the host OS after a full GC. Hence Spur is
able to grow the heap to the limit of available memory without one having
to specify the VM’s memory size at start-up.

The object representation uses “lazy forwarding” to implement become:,
creating copies of objects that are becommed, and forwarding the existing
objects to the copies. While Spur still scans the stack zone on become to
ensure no forwarding pointers to the receiver exist in stack frames (for
check-free push and store instance variable operations), it does not scan
the entire heap, catching sends to forwarded objects as part of the normal
message send class checks, hence following forwarding pointers lazily, and
eliminating forwarders during GC. The existing memory manager does a full
memory sweep and compact to implement become. Hence Spur provides the
performance advantages of direct pointers while providing a significantly
faster become.

While Spur uses moving GC (scavenging and compaction on full GC), just like
the existing memory manager, Spur supports pinning, the ability to stop an
object from moving. Old space objects will not be moved if pinned.
Attempting to pin a new space object causes a become, forwarding the new
space object to a pinned copy in old space. This allows simpler
interfacing with foreign code through the FFI, since one can hand out
references to pinned objects in the knowledge that they will not be moved
by the GC.

Finally Spur supports ephemerons in a simple and direct way, providing
pre-mortem per-instance finalization. Although the image-level support
needs to be written, it should soon be possible to improve the finalization
of entities such as buffered files (ensuring they are flushed before being
GCed), etc.

Future Work
Spur is as yet a work in progress. The 32-bit implementation is usable and
appears stable. The major missing component is an incremental scan-mark GC
that should eliminate long pauses due to the global scan-mark-compact GC
(which is still invoked at snapshot time). I hope to start on this soon.
But another key facet of Spur is that the object header format and the
sizes of objects are common between 32- and 64-bits. In 32-bit and 64-bit
Spur, object bodies are multiples of 8 bytes, so there may be an unused
slot at the end of a 32-bit object with an odd number of slots. Hence Spur
is close to providing a “true” 64-bit system, one with 61-bit
SmallIntegers, and 61-bit SmallFloats (objects with the same precision, but
less range that 64-bit Float, done by stealing bits from the exponent
field). I look forward to collaborating with Esteban Lorenzano on 64-bit
Spur and hope that it will be available early next year.

Experience
I am of course interested in reports of performance effects. Under
certain, hopefully rare circumstances, Spur may actually be slower (one is
when the number of processes involved in process switching exceeds the
number of stack pages in the stack zone). But my limited experience is
that Spur is significantly faster than the existing VM. Please post
experiences, both positive and negative.

Finally, caveat emptor! This is alpha code. Bugs may result in image
corruption. If you do use Spur, please try and back up your work just in
case. And if anything does go wrong please let me know, preferrably
providing a reproducible case.

Enjoy!
Eliot Miranda

AlicesRest

Howdy!

 

If you want to know some cool history of Smalltalk, and perhaps this is a strong argument in actually *being* a Smalltalk and not trying to distance yourself from that rich and lovely heritage…. anyway, here goes:

 

On 04/28/2014 08:14 PM, Alain Busser wrote:

> Also, Ruby is famous for these methods:

> *select

> *reject

> *collect

> do these names not remind you something ;-) ?

 

There is a funny story about these verbs. Martin McClure told me at ESUG in Brest to ask Dan Ingalls about it, hinting that they are “inspired”

by a famous song.

 

And thus I did ask Dan in my interview with him I did a few years back over Skype (it is an interesting interview, for example – was there an inspiration from biology when Smalltalk was created?):

 

http://files.krampe.se/interview.mp3

 

…the song in question is by Arlo Guthrie:

 

http://en.wikipedia.org/wiki/Alice%27s_Restaurant_Massacree

 

…and here is a URL to the lyrics of it:

 

http://www.lyricsty.com/arlo-guthrie-alices-restaurant-lyrics.html

 

(search down to “injected”!) …or just let me quote:

 

“They got a building down New York City, it’s called Whitehall Street, Where you walk in, you get injected, inspected, detected, infected, Neglected and selected. I went down to get my physical examination one Day, and I walked in, I sat down, got good and drunk the night before, so I looked and felt my best when I went in that morning.”

 

…now… where do we stuff in #neglect:? :)

 

regards, Göran

Squeak 4.5 Released!

21 March, 2014

squeak4.5

From Chris Muller:

So!  Let it be known!  Squeak 4.5 is released!

Home page is here:  http://www.squeak.org

4.5 release notes are here:  http://wiki.squeak.org/squeak/6193

Excellent Job Everyone!!  Can you tell we are excited!

OLPC-logo

OLPC-4.0
Check out OLPC XO-4.

I would hate to add to the speculation that OLPC is dead because it’s not.  Wayan Wota has been calling OLPC dead for 5 years. This is not news. He has not been involved with the project in a long time. His article is about the XO-1, apparently he doesn’t even know the XO-4 was officially introduced at this year’s CES, alongside the tablet.

If you really want to know what’s going on with current OLPC community projects see Adam Holt’s http://www.unleashkids.org/

Full OLPC Statement (from: http://gizmodo.com/one-laptop-per-child-isnt-quite-dead-yet-1541430670):

OLPC’s mission to empower the world’s children through education is far from over. OLPC is thriving and making more inroads at bringing education to those who can’t easily access it. OLPC recently formed a strategic alliance with the Zamora Teran family through many of their enterprises and their philanthropic foundation, the “Fundación Zamora Teran to deliver XO laptops not only to Central and South America, but also to Africa.

Aside from distributing more laptops in several schools in Costa Rica, Uruguay is receiving its first 50k units of the XO-4 Touch (running Android) in a few weeks’ time. In addition, the XO Tablet is currently available directly through governments and NGOs, as well as in Europe and Canada and through all major retail outlets in the United States including Walmart, Amazon, Toys ‘R Us among the others.

OLPC also has outsourced many of the software and development units because the organization is becoming more hardware and OS agnostic, concentrating on its core values – education. As an example, we’ve partnered with the Smithsonian Museum to bring feature-rich, interactive and more targeted content to our young learners.

We have more exciting things planned in the horizon including the implementation of very large scale projects in several regions of the world, so be sure to stay tuned.

OLPC is a concept, it is a movement, it is a community and it is about helping children.  Sure the grand vision may be delayed, but the benefits of education and technology, of improving the human condition is not dead.  We all knew that it’s not profitable to teach third world children.  Still,  no one thought that companies would compete against OLPC.  Countries opted for different technologies for hardware but never matched the promise or the vision of the software.  Had the world united around this platform children would have benefited and the world today would be a better place as we develop together and stamp out ignorance.  There is nothing like education to improve the world and that mission is not dead.  OLPC is evolving, finding new ways to reach more children, making more with less, and finding ways to make a real difference in the world.

Support OLPC!  Long Live the vision.

cogs

From Clément’s post to the pharo community:

Hello pharoers,

The new Cog memory manager, Spur, is simply *amazing*. I saw at FOSDEM that some of you were interested in it, but unfortunately you were lacking information about it.

I wrote a one page article that sums up Spur’s new features so every one can know what will be better. There’s no VM technical details here, it’s just about what will change for a regular pharo user.

http://clementbera.wordpress.com/2014/02/06/7-points-summary-of-the-spur-memory-manager/

Let me know if you think I forgot yet another feature.

If you have questions, I’ll try to answer, but ask Eliot, he implemented Spur so he can answer your questions much better than I can :-).

Regards,

Clément

squeakiscool

From: Chris Muller:

It’s ready for your final testing and scrutiny!

http://ftp.squeak.org/4.5alpha/Squeak4.5-13663.zip

Please bang on this!  Test it with your apps.  Test it in Windows, iOS, Linux.  Interpreter and Cog.

Unless we hit any show-stoppers, this will be the one we can call “done.”

Thanks to this great community of brilliant developers for making 4.5 a superb release.

Follow

Get every new post delivered to your Inbox.

Join 47 other followers