Last active
December 14, 2015 20:58
-
-
Save petdance/5147279 to your computer and use it in GitHub Desktop.
Start of an article on the state of Perl 6. At the top are questions that I think should be answered in the body of the article, because they're the questions that most readers are going to want to know. Maybe not all of 'em, but most. The real thing everyone wants to know is "When will it be done", but we can't answer "When will it be done" bec…
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Questions to answer | |
* What do I need to have to install Rakudo Star today? JVM? Mono? | |
Either? | |
* If I download and install Rakudo Star today, what installs? What | |
do I get with that? Modules? Debugger? Toolchain? I get that | |
with Perl 5 now. | |
* What's the state of the toolchain? Can I build and install Perl | |
6 modules? | |
* What's the state of CPAN support for Perl 6, or Perl 6 support | |
for the CPAN? | |
* How much of the language spec is completed? Is there an ETA on | |
that finishing? | |
* How much of the implementation is completed, perhaps as a percentage | |
of the spec? Is there an ETA on that finishing? | |
* What is the speed like? How does the speed of a Perl 6 program | |
compare to the equivalent Perl 5 program? Are there some areas | |
that are faster or slower than others? | |
* Is there a way I can play with Perl 6 without having to install Rakudo? | |
# Start of article | |
Recently, a | |
<a href="http://www.modernperlbooks.com/mt/2013/02/goodnight-parrot.html">blog post</a> | |
by chromatic predicted the death of the | |
<a href="http://www.parrot.org/">Parrot</a> | |
project. Since Parrot was conceived to be the VM that runs | |
<a href="http://perl6.org/">Perl 6</a>, | |
it's only natural for people to wonder what the death of Parrot | |
means to Perl 6. And the answer is ... "Eh, not much." | |
The first major attempt at implementing Perl 6 was the <a | |
href="https://github.com/perl6/Pugs.hs">Pugs</a> | |
project which uses Haskell as its implementation language and has | |
backends for compiling Perl 6 to Haskell, Perl 5, Javascript, and, | |
of course, Parrot. Unfortunately Pugs hasn't kept up with more | |
recent changes, but it still compiles a good bit of the language. | |
Another Perl 6 implementation, <a href="https://github.com/sorear/niecza">Neicza</a>, | |
is built upon the Common Language Runtime and uses either | |
<a href="http://en.wikipedia.org/wiki/.NET_Framework">Microsoft's proprietary .NET</a> | |
or | |
<a href="http://www.mono-project.com/Main_Page">the open source version, mono</a>. | |
There is no Parrot involved. | |
The most actively developed Perl 6 implementation is the | |
<a href="http://rakudo.org/">Rakudo</a> | |
Perl 6 compiler. Over the course of its history, Rakudo has been | |
intimately tied to Parrot. In fact, Rakudo and Parrot even shared | |
a source code repository for a little while. But for the last few | |
years, the plan has been that Rakudo would support multiple backends. | |
Rakudo is built using a small subset of Perl 6 called | |
<a href="https://github.com/perl6/nqp">Not Quite Perl</a> | |
(NQP). NQP parses and compiles Perl 6 code into Parrot instructions. | |
Currently, the way for Rakudo to support multiple underlying VMs | |
is to port NQP to the target VM. Interestingly, NQP is mostly written | |
in NQP. It's only the low-level primitives that talk to the VM | |
directly that need to be re-implemented to target a different VM. | |
Currently, the version of NQP that uses Parrot is the only fully | |
functional implementation, but there is a nearly-there | |
<a href="https://github.com/jnthn/nqp-jvm-prep">port to the JVM</a> | |
people are working on | |
<a href="https://github.com/swarley/nqp-go">a port for Go</a> | |
and | |
<a href="https://github.com/pmurias/rakudo-js">another for Javascript</a> | |
as well. | |
So ... all of the Perl 6 implementations have plans or code for | |
running on a VM other than Parrot. Whether Parrot lives or dies | |
won't really affect Perl 6 one way or another. | |
Why spend the time and energy making Rakudo run on multiple backends? | |
Patrick Michaud explains: | |
<blockquote> | |
At YAPC::NA 2009 in Pittsburgh, Jesse Vincent and I were both riding | |
on the bus to the airport, and naturally we were discussing Perl 5 | |
and Perl 6 and integration. In the course of the discussion, Jesse | |
noted that just about every major scripting language except Perl | |
had been implemented on the JVM and/or .NET platforms. He also noted | |
that if Perl 5 was ever going to appear on those platforms, it would | |
almost have to be through Perl 6. At that point I knew we absolutely | |
needed a plan for making Rakudo available on other backends. | |
</blockquote> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment