2017.17 Interesting Times

Indeed. The past week saw the Rakudo Compiler Release 2017.04 have several point updates. Zoffix Znet explains it all in The Failure Point of a Release. The good news: if you’re waiting for a Rakudo Star Release of 2017.04, a release candidate is now available for testing. So please do!

The Perl Conference – US

The preliminary schedule for the Perl Conference - US on 19-21 June (formerly known as YAPC::NA) is now available. Please note that Damian Conway will be giving some interesting Perl 6 related tutorials!

Core Developments

  • Stefan Seifert fixed an issue with a packaged Inline::Perl5 trying to access a Proxy‘s FETCH method. A problem with the %?RESOURCES hash and NativeCall library name resolution was also fixed. He also made dependency resolution no longer depend on filesystem timestamps.
  • Zoffix Znet continued his work on the IO Grant apart from teaching his bots new tricks.
  • TimToady made user grammars work more like classes, specifically with regards to .new.
  • dogbert17 found the source of a problem with the HARNESS_TYPE=6 spectesting, which Timo Paulssen then fixed.
  • And some other smaller fixes and optimizations, apart from the ones that Zoffix Znet already mentioned.

Blog Posts

Wow, what a nice bunch of blog posts!

Meanwhile on Twitter

Meanwhile on StackOverflow

Ecosystem Additions

Winding down

Yours truly missed most of the excitement the past week on account of being on the road a lot. In a way, I’m glad I did. On the other hand, feels like I should have been around. Ah well, you can’t have it all. But if you want more, please check in again next week for more Perl 6 news!

2017.16 IO Hits The Road

Zoffiz Znet and his trusted bots just came out with the 2017.04 Rakudo Compiler Release. It contains the culmination of the IO grant work. A Rakudo Star release should be expected within the next few days, based on this compiler release. Apart from the IO work and all of the other optimization work that has been done, one thing to particularly note is the work that Samantha McVey has done on Unicode support and case-insensitive regex matching. Please have the appropriate amount of more efficient fun!

Perl Toolchain Summit

The Perl Toolchain Summit is now less than a month away. Some people actively developing on Perl 6 will also attend. There are even some Perl 6 related entries on the Project List. Hope to see more Perl 6 related items there soon. And to finally be able to make CPAN support for Perl 6 modules an actual thing!

Core Developments

  • Timo Paulssen made it possible for Grammars to precompute their NFAs during precompilation, allowing them to be stored in precompiled modules.
  • TimToady continued working on a refactor of Match objects and cursor, which hasn’t produced much improvement yet because of all scaffolding still needed.
  • Paweł Murias undid the bitrot that broke the Allocations tab in the output of --profile.
  • Stefan Seifert fixed an issue with compilation stores without write access, as well as some issues when using the Staging repo.
  • And many other bug fixes and a lot of work on the IO grant, of course!

Other blog posts

Meanwhile on Twitter

Meanwhile on StackOverflow

Meanwhile on FaceBook

Jonathan Stowe says:

If you have been experiencing difficulty accessing certain https web sites with one of the various HTTP clients, you may want to upgrade to the latest OpenSSL module – I’ve just implemented supported for the TLS server name extension which is required for an increasing number of virtual hosting arrangements. It also fixes Webservice::Soundcloud.

Ecosystem Additions

Winding Down

Unexpectedly brought to you from Copenhagen, Denmark. See you again next week for more Perl 6 news!

2017.15 Kaboom! ⁽¹⁾

Zoffix Znet did a massive amount of work on the IO Grant. Some of the highlights:

  • Clean up &open and IO::Path.open.
  • Clean up and improve all spurt routines.
  • Give $*TMPDIR a container.
  • Implement IO::Path.extension 2.0.
  • Fix ambiguity in empty extension vs no extension.
  • Implement IO::Path.concat-with.
  • Remove IO::Path.abspath.
  • Make IO::Path::* actually instantiate a subclass.
  • Make IO::Path throw when path contains NUL byte.

All in all a very good weekly result!

Other Core Developments

  • Samantha McVey made literal string matching (aka nqp::index) 2x faster, by either using the Knuth-Morris-Pratt algorithm on Linux, or the Crochemore-Perrin algorithm on Windows and MacOS.
  • Jonathan Worthington added support for serialization/deserialization of native hashes, and wondered how we could have done so long without.
  • Elizabeth Mattijsen implemented support for (*-N) for .head and .tail. @a.head(*-5) will now produce all values of @a except the last 5. @a.tail(*-5) will now produce all values of @a except the first 5. And this is all lazy on Sequences.
  • Zoffix Znet also awesomified the unhandled Failure in DESTROY message, as well as implemented a skip-all option to Test‘s plan.
  • Lloyd Fournier fixed an issue with Code.ACCEPTS.
  • TimToady made sure that for $x() will no longer be a Perl 5 confusion type error. Instead, it will now only die if there is a space before the ().
  • Elizabeth Mattijsen also continued her work on set operators and coercions to / from Sets, Bags and Mixes. Some improvements are like 250x faster, others just a few % (but those were generally done to really hot code paths and/or to reduce memory pressure).
  • And many more improvements and smaller bug fixes.

Blog Posts

Meanwhile on Twitter

Meanwhile on StackOverflow

Ecosystem Additions

Winding Down

Apart from these visible results, a lot of work is being done by TimToady, Bart Wiegmans and Paweł Murias that hasn’t come to full fruition just yet. Yours truly is very anxious to tell about them in the (near) future! So check in again next week!

⁽¹⁾ With apologies to Jonathan Stowe.

2017.14 The IO Front Advances

Zoffix Znet really hit the ground running this week! After announcing his IO plan, publishing his progress report for the month of March and waiting for the end of the comment period, he published the IO Upgrade Information, and after some late insights, IO Upgrade Information, Part 2, which contain an up-to-date account how things are progressing. And there’s of course the list of IO issues he’s working on. If you’re interested in these developments, please check these out. And contact Zoffix with any feedback, the sooner the better!

Improving the Robustness of Unicode Support

Samantha McVey put up a grant proposal covering the following deliverables:

  • Programmatic determination of Unicode names.
  • Implement Unicode collation algorithm.
  • Properly support grapheme breaking in Unicode 9.0 and beyond.
  • Improvements on Unicode database generation.
  • Documentation of deficits in the support.

Check it out and give her your opinion!

Camelia in the Wild

A new section in the Perl 6 weekly where spottings of Camelia in the wild can be reported. This week’s spotting was at a concert of ARW in Brussels.

Try out Perl 6 online

If you would like to try out some Perl 6 code without wanting to install Rakudo, you can now also go to https://tio.run/nexus/perl6! Just type in your code, click the play button and see the result! Too bad it currently runs the 2017.01 release, which is now over 2 months old! Still, if you just want to test some code, that is pretty recent and beats many packages provided by some distributions.

NativeCall Introduction

Naoum Hankache‘s excellent Perl 6 Introduction now has a chapter introducing the NativeCall interface (explaining how you can easily call code from external libraries from your Perl 6 source code). For now that chapter is available in English only, but I have no doubt the other languages (Bulgarian, Chinese, Dutch, French, German, Japanese, Portuguese and Spanish) will follow soon!

Coverage reports

The Rakudo Perl 6 core has up-to-date coverage reports again. And now we also have coverage reports for Moar, thanks to Samantha McVey. So if you’re looking to add some tests to get better coverage, that’s where you can find which parts of the system are not tested yet!

Other Core Developments

  • Jan-Olof Hendig fixed a problem with the total number of tests run using the harness6 (aka the Perl 6 version of prove) while doing a spectest or stresstest. Which brings us one step closer to running spectest using Perl 6 by default (instead of Perl 5).
  • Fernando Correa fixed a problem with multi-dimensional hash slices (such as %h{"foo","bar"; "baz"}.
  • Daniel Green and Timo Paulssen fixed a problem with unsigned native ints that at some VM level, were not marked as unsigned.
  • Samantha McVey improved the speed m:i/ / regex matching between 1.8x and 3.3x (depending on not finding a match / finding a match at the beginning).
  • Jonathan Worthington improved error reporting on Parameter binding, allowing for a slightly better error message that includes the non-matching value and, where the constraint is a named subset type, that type name.
  • Apart from all of the work on IO, Zoffix also fixed a problem with matching in loops and $/ that affected ~~ as well as .subst, .subst-mutate, Grammar.parse and Grammar.parsefile.
  • Elizabeth Mattijsen made a lot of set operators, as well as coercions to Set(Hash), Bag(Hash) or Mix(Hash) from 30% to 25x faster, mostly by avoiding (where possible) potentially expensive calls to .WHICH. She also made sure that set(), bag() and mix() (aka the empty immutable Set, Bag and Mix) only exist in memory once. Finally, she also improved TAI / epoch conversions, e.g. making now about 20% faster.
  • And as usual many other smaller fixes and improvements.

Blog Posts

Meanwhile on Twitter

Meanwhile on StackOverflow

Meanwhile on FaceBook

  • Paul Bennett mentioned STOKE, an interesting approach to optimisation:

    The ACM has a paper on a new compiler optimization called STOKE. It calls itself “stochastic”, but they seem to mean something other than “random” … more like “capable of working outside the explicit order of operations as given”. It beats gcc -O3 by a significant margin.

  • Ecosystem Additions

    Winding Down

    Wow, what a busy week again. Please check in again next week for more Perl 6 news!

    2017.13 IO’s not the same

    Zoffix Znet has published the IO action plan as part of the IO grant work. Please read it and if you have any comments, let Zoffix know! Alternately / Additionally, you might want to check out the February Grant Report. In the past week, several IO related parts of Rakudo have already become significantly faster!

    Hyper / Race Semantics

    Jonathan Worthington thought a lot on the issues surrounding hyper and race and produced a plan, inviting comments. Please have a look at it and come up with a better name for Seqqy. 🙂

    Fernando Correa Welcome!

    Fernando Correa has joined the ranks of the Rakudo Perl 6 Core Developers! As SmokeMachine he already has quite a few merged Pull Requests under his belt. We’re all looking forward to seeing more of his excellent work. A hearty welcome on behalf of everybody interested in Rakudo Perl 6!

    Other Core Developments

    • Samantha McVey increased the speed of concatenating strings on MoarVM up to 30%, while fixing some issues with concatenating strings with control characters at either end.
    • Stefan Seifert improved a confusing error message when trying to load a non-existing module that matches a distribution name.
    • Jonathan Worthington fixed a race condition issue with generating a unique ID for EVAL blocks.
    • Elizabeth Mattijsen made .invert about 10x faster.
    • Zoffix Znet made many of the path manipulation methods (such as IO::Path.child and IO::Spec::Unix.catpath) up to an order of magnitude faster.
    • Jonathan Stowe fixed an issue with the introspection of attributes of Associatives with explicitly typed keys.
    • And as usual, many other smaller improvements and bugfixes.

    Blog Posts

    Meanwhile on Twitter

    Meanwhile on StackOverflow

    Ecosystem Additions

    Only one addition this week…

    Winding Down

    Posted a little later than usual, all because yours truly was pleasantly detained at a concert in Brussels. Please check in again next week for more Perl 6 news!

    2017.12 How To Race A Hyper

    Jonathan Worthington has focused his attention on race and hyper, two ways of making your code run in parallel more or less automatically. In his most recent blog post he describes the history behind hyper and race, and how he is (re-) considering the exact semantics for the coming 6.d version of Perl 6. Please check out this spreadsheet and let him know what you think about it.

    And Yet Another Compiler Release

    It was that time of the month again. Zoffix Znet and his trusty bots released Rakudo Perl 6 compiler, Release #109 (aka 2017.03). It’s getting almost as normal as landing a first stage rocket in your back garden. Anyways, this release has fixed the lexical module loading bug, which changes the way symbols exposed by a module are visible in your code. This was announced last December. Should you not have changed your code yet to take this bug fix into account, you can take a look at the Lexical require upgrade info, posted by Zoffix Znet.

    Core Developments

    • Samantha McVey made case-insensitive regex matching better and 20%-30% faster by using foldcase internally in a smarter way.
    • AlexDaniel noticed that was not properly set up for handling lambda’s, and knew how to fix that as well.
    • After much discussion, Zoffix Znet removed support for the special ⁇ ‼ Unicode ternary operator. No worries, ?? !! are still there!
    • Zoffix Znet also fixed an issue with map with blocks that are guaranteed not to return a Slip. And also made IO::Pipe.lines 3x faster by removing code as part of the work on the IO grant.
    • Timo Paulssen fixed an issue with nqp::p6bool which wasn’t aware of the existence of native variables, causing unnecessary boxing/unboxing.
    • Elizabeth Mattijsen made the .WHICH on Cool types about 1.8x faster, which should cause an improvement when using Cool values with .unique, Sets, Bags and object hashes. She also fixed an issue with rotor.
    • Fernando Correa fixed an issue with flattening in a triangular reduce using infix: and some Cool / Str infinilooping in multiple dispatch.
    • Daniel Green fixed an issue with the ~^ operator on Bufs.
    • And of course many other smaller improvements and bug fixes!

    Blog Posts

    Meanwhile on Twitter

    Meanwhile on StackOverflow

    Ecosystem Additions

    An interesting addition for packaging up your applications, an easier way to do an HTTP client, and an interface to ftplib!

    Winding Down

    Still very busy. Even though it apparently is spring now, it feels more like autumn. Let the sunshine in! See you next week, for more Perl 6 news.

    2017.11 Tidy Da Tags

    Jeffrey Goff made the first version of Perl6::Tidy available for general usage. As he announced in his tweet, only very few lines were needed to perform this feat (so far). But that’s because all of the hard work he already put into Perl6::Parser! In any case, something that people coming from Perl 5 have frequently asked for in Perl 6 is (a step closer to) reality now.

    Tag Your Distributions

    Zoffix Znet started a project to make it easier to find Perl 6 distributions in the ecosystem. By adding tags to your distribution, these tags can be used as targets for search queries. He explains it all in a blog post.

    Perl Developers Survey 2017

    The people at Built In Perl have announced their yearly Perl Developers Survey, and they would like you to participate in it. It will only take a few minutes!

    So You’re Experienced in Python

    The nice folks of the Perl 6 documentation project have created a page to help programmers coming from Python. It discusses the equivalent syntax in Perl 6 for a number of Python constructs and idioms. There have been similar pages for Perl 5, Ruby and Haskell, in case you were wondering why Python was being advantaged here 🙂 .

    VIP ¿Que?

    There’s something hovering in the air!

    Core Developments

    • Samantha McVey fixed some issues with case-insensitive matching, specifically for those unicode characters that have a lower/upper case version that is longer/shorter than the original character: now the fold-case functionality is used internally. And as a bonus, it is also 30% faster!
    • TimToady has been working on some useless use warnings, further support for slangs and meta-operator issues with the xx operator.
    • Jonathan Worthington fixed some issues related to Proc::Async, specifically if the process could not be spawned.
    • Lloyd Fournier fixed some issues with multiple requires & require clobbering pre-existing packages, building on the extensive work by Stefan Seifert getting require to work correctly in the lexical module loading world.
    • Elizabeth Mattijsen made the xx operator to always return a Seq: before a List would be returned in some cases.
    • Zoffix Znet made sure that code resulting from function combinator () retains the parameter count and arity of the original code.
    • Daniel Green added specialized candidates for infix min and max, making them about 3x faster.
    • And of course many other smaller fixes, improvements and speedups!

    Other Blog Posts

    Meanwhile on Twitter

    More than 250 followers now! 🙂

    Meanwhile on StackOverflow

    Ecosystem Additions

    A modest catch this week:

    Winding Down

    It has been a busy week for yours truly. And the following weeks will also be very busy. But that’s all irrelevant for you readers 🙂 . So please check again next week for more Perl 6 news!