Sign In/My Account | View Cart  
advertisement


Listen Print

This week on Perl 6, week ending 2003-03-23

by Piers Cawley
March 23, 2003

Assuming I can tear myself away from stroking the cat who has just magically appeared on my chest and is even now trying to wipe his dags on my nose, welcome one and all to another Perl 6 summary, which should go a lot quicker now that Sully has moved off and let me see the screen. He'll be back though. But before that happens we'll start with perl6-internals.

Speed question: save/restore vs push/pop

Benjamin Goldberg wondered about how many saves it takes to be slower than one pushx. Steve Fink pointed out that save and pushx are not interchangeable as they push things onto totally different stacks (save pushes onto the generic user stack, pushx push onto type specific register frame stacks). Leo Tötsch ignored this difference (which Ben was apparently aware of) and did some tests which showed that, on his local architecture and core, 2 saves were slower than one push. On Dan's machine, it took 3 saves to be slower than one push. Dan also pointed out that, on some architectures, there's a subtle win with saves because a push would dirty the L1 and L2 caches while the save wouldn't. (On SPARC at least, apparently).

http://groups.google.com/groups

Baby Steps in porting IO to the PIO architecture

Last week, Leon Brocard posted his implementation of the uniq(1) Unix utility to PASM. This week, Jürgen Bömmels' ongoing project of moving Parrot's IO operators from the STDIO library to Parrot's own PIO library (which is asynchronous and a combination of lovely and scary by all reports.) broke this because PIO didn't have any read buffering capabilities, which means that the readline op didn't work.

On Monday, Jürgen had write buffering working, which Dan applied with alacrity while making noises about needing to finish up the documentation for Parrot's asynchronous IO system. There was some debate on whether a PIO flush should force a write to the disk, or simply ensure that all the buffers were flushed to the OS. Nicholas Clark discussed some issues he'd had with Perl 5.8's PerlIO system, and the need for two different kinds of flush, or more succinctly, the need to distinguish 'flush' from 'sync'. Dan was convinced by this argument and Steve Fink seconded the decision.

Then, on Sunday, Jürgen released a patch which got read buffering working. Dan had a few problems with it and the patch hadn't been applied by the end of the week. I'm sure it'll go in like a greased weasel once that's been fixed though.

http://groups.google.com/groups -- Jürgen adds write buffering

http://groups.google.com/groups -- Nicholas discusses different types of flush

http://groups.google.com/groups -- Jürgen adds read buffering

PBC Object Files

Michael Collins wondered if it might be a good idea to come up with a parrot 'object file' specification. I liked Michael's description of an object file as 'a file that contains compiled instructions plus a section with a table that maps subroutine/constant labels to their corresponding byte offsets within the file.' Leo Tötsch's answer was 'not yet'. Apparently the basic functionality is there but there are some cleanups and a couple of opcodes needed.

http://groups.google.com/groups

Parrot binaries

Ask Bjørn Hansen posted to say that he'd been trying to make an RPM .spec file for parrot and had noted the lack of a make install target. He also wondered about the permissions of various files in the distribution, which seem somewhat cockeyed. Steve Fink posted a patch which covered some of this (or at least the make install and RPM issues) with tools which would generate RPMs and asked for comments on his work. Leo Tötsch liked it and offered a couple of suggestions

http://groups.google.com/groups

http://groups.google.com/groups -- Steve's working patch

Some comments on PDD 14 Big Numbers

Mark Biggar, who implemented the original Big* packages for Perl had some suggestions about Parrot's big number handling based on PDD 14. Benjamin Goldberg wondered if it would be a good idea to design our BigInt type so that we could replace the maths engine with a different engine so that users could pick which ever engine they prefer as configuration option, and so that new maths engines could be added without having to make wholesale changes.

http://groups.google.com/groups

99 bottles of beer on the wall

Douglas Hunter appears to have noticed that, up until now, Parrot had lacked a vital program -- one which would output the lyrics to that well known song, 99 Bottles of Beer on the Wall. So, being a community spirited kind of chap, he implemented just that and posted it to the list. A few people quibbled about his style (unnecessary labels, that sort of thing). Leo Tötsch pointed out, with the aid of some IMCC output that the optimizer caught those issues anyway, and added the code to the Parrot distribution's examples/ directory. Well done Douglas, it's good to see Parrot being used for essential applications like this. I'm just surprised nobody has yet benchmarked the Parrot implementation against Perl and Python. This may just be the test application we need for the Parrot/Python speed challenge.

http://groups.google.com/groups

BASIC, IMCC and Windows

Clinton A Pierce has been having a hard time making good on his offer to produce a milestone Windows binary for distribution. He's having a hard time building IMCC because it seems to want headers that MSVC++ isn't happy with. Dan noted that this needs to be fixed before the next release of Parrot (which will be either 0.1.0 or 0.0.11) because he wants to get rid of the IMCC/parrot difference and just have a single binary. Leo Tötsch and Nicholas Clark offered a few suggestions about workarounds, but it looks like there's still no Windows distribution for Parrot.

http://groups.google.com/groups

Iterator Proof of Concept

Following the deafening response to his Iterator proposal of last week, Leo Tötsch agreed with me that that must mean that everyone liked the idea and posted a proof of concept patch and invited comments. Nobody has yet done so.

http://groups.google.com/groups

vtable_1 - accessor macros

Leo Tötsch has started work on hiding vtable functions and posted his first patch. He commented that the new accessor macros seem to make for more readable source files. He asked if people were okay with the macro, as the next step would be to start using the macros all over the parrot source. Nicholas Clark liked the basic idea, but worried about documentation, and about the possibility of scary macro layering a la Perl 5. He also wondered if it would be possible to conditionally write them as inline functions, which would make debugging easier. Leo didn't see much point in making this particular set of macros into inline functions as they were simple translations with no complex functionality.

http://groups.google.com/groups

Parrot 0.0.10 released

Parrot version 0.0.10, codename 'Juice' was released on Wednesday. Steve Fink rounded up the usual list of improvements and generally did a good job of letting the world know about the new Parrot release. If you want the details, follow the link.

http://groups.google.com/groups

Pages: 1, 2

Next Pagearrow