Pyconsg2014 pyston

Post on 19-Aug-2014

340 views 0 download

Tags:

description

pyston

Transcript of Pyconsg2014 pyston

Nightly Pyston and Performance

Nakamura Masato(@Masahito) from Japan version #pyconsg

Who are you?(お前、誰よ by Ian Lewis)

• @Masahito from Japan

• P2P File Transfer Engineer at Skeed .inc

• I work with Scala & JVM(Sorry!)

• We use Python for Implementation the CLI, and, to deploy the P2P client(fabric etc)

 Attention I do not have the implementation of

Pyston. The only explanation this time ;-)

What is Pyston?

What is Pyston?• develop : Dropbox(https://tech.dropbox.com/2014/04/introducing-pyston-an-upcoming-jit-based-python-implementation/)

• JIT(Just in Time)-based implementation of the Python 2.7 language.

• Python implementation built using LLVM and modern JIT techniques

• only runs on x86_64 platforms, and only has been tested on Ubuntu.

Python Code to LLVM IR The IR is then run through the LLVM optimizer and passed off to the LLVM JIT engine,

Run Mechanism

How to install• Binary is not provided

• build required(https://github.com/dropbox/pyston/blob/master/docs/INSTALLING.md)It's written carefully, it works roughly.(It does not work? Let's do our best!)

!

Current state

• It does not correspond to the input of the line breaks in the REPL

• It does not correspond to the basic grammar other than the Python(not generator , list comprehension etc)lambda is coming!

• Library is not implemented almost it's current status. You can not use only about ”time.time” far

 Benchmark!

precondition• compared in the following environments.(on Ubuntu12.04 and vagrant (VirtualBox 2CPU)

• Python v2.7.X

• PyPy v2.2.1

• Pyston v0.1(2014/04/15)

Recursion

Recursion(Second) Recursion

Second

Loop

Loop (Second)

loopSecond

Summary: There is an effect in the recursion of LLVM JIT.

Effect is difficult to come out in the loop of LLVM JIT.

planned for 0.2

Missing large parts of the language !

Exceptions (planned for 0.2) Class inheritance (planned for 0.2) Default arguments, keywords, starargs, kwargs (planned for 0.2) Generators (planned for 0.2) Integer promotion (planned for 0.2) Threads

Information Source• [Introducing Pyston: an upcoming, JIT-based Python implementation] https://tech.dropbox.com/2014/04/introducing-pyston-an-upcoming-jit-based-python-implementation/

• https://github.com/dropbox/pyston/blob/master/README.md

• [LLVM overview 20110122] http://www.slideshare.net/nothingcosmos/llvm-overview-20110122

Thank you! !

ありがとう!

See you again in PyconJP 2014! Deadline for talk proposals is

20th June.