Pyston 0.2 Python Compiler
Written by Alex Denham   
Friday, 19 September 2014

There’s a new release of Pyston, the high-performance Python implementation developed by cloud storage provider Dropbox.

python3

Pyston was made available in an initial open-source version earlier in the year, consisting of a JIT-based Python implementation built on the LLVM compiler stack.

While the original 0.1 release was fast, it lacked a number of language features. Many of these have been added to the new version.

Discussing the new release in a post on the Pyston blog, the developers say that while Pyston 0.2 is still very much a work in progress, it has much-improved language compatibility, and is able to run many of the standard libraries — and some standard extension modules — without modifications.

One of the main improvements is the addition of a native C API. This is described as still a work in progress, but it does natively provide a subset of the CPython API and run existing extension modules with a recompile.

Multi-threading support has also been added. The blog post says the developers currently use a GIL to protect threaded code. While inelegant, it is simple and efficient when there is only a single thread.

"We have an experimental configuration option to use a read-write-lock variant, which removes the GIL and allows multiple threads to use multiple cores, but the potential parallelism is highly limited by the semantics of the C API."

Other improvements include support for exceptions, inheritance and meta-classes, but there are also many features missing (such as finalizers, unicode, and C API exceptions).

Going forward, the goal for the next version is to improve performance. While the 0.1 release showed the ability to produce high performance code using LLVM, running real benchmarks has shown that the performance is being held back by the product’s simple garbage collector and naive SSA-transform implementation. These are areas that will be improved, along with the addition of a new tiering framework. This will enable more advanced type speculation, and will also support Python’s advanced frame introspection features.

The new version should still be considered in early alpha, according to the developers. More details are available on the blog post.

Dropbox and Pyston are part of the trend for service providers like Facebook to implement their own language subsystems in an effort to improve performance.

 python3

More Information

Pyston 0.2: better than Pyston 0.1

Pyston on GitHub

Related Articles

Micro Python - The Latest Python

Python Tools for Visual Studio 2.1 Beta

 

To be informed about new articles on I Programmer, install the I Programmer Toolbar, subscribe to the RSS feed, follow us on, Twitter, FacebookGoogle+ or Linkedin,  or sign up for our weekly newsletter.

Banner


IBM's Call For Code 2020 Winner - Agrolly
16/10/2020

IBM this week awarded the 2020 Call for Code grand prize of $200,000 to the creators of an app that helps small farmers threatened by climate change decide what to plant and w [ ... ]



Android Studio 4.1 - No Relief In Sight
21/10/2020

A new version of any IDE is always an event, but Android Studio's state reflects the current mess that Android developement is in. I look forward to each new release in the hope that something has bee [ ... ]


More News

 

square

 



 

Comments




or email your comment to: comments@i-programmer.info

Last Updated ( Friday, 19 September 2014 )