Skip to main content

Bittorrent on PyPy

Hi all,

Bittorrent now runs on PyPy! I tried the no-GUI BitTornado version (btdownloadheadless.py). It behaves correctly and I fixed the last few obvious places which made noticeable pauses. (However we know that there are I/O performance issues left: we make too many internal copies of the data, e.g. in a file.read() or os.read().)

We are interested in people trying out other real-world applications that, like the GUI-less Bittorrent, don't have many external dependencies to C extension modules. Please report all the issues to us!

The current magic command line for creating a pypy-c executable with as many of CPython's modules as possible is:

  cd pypy/translator/goal
  ./translate.py --thread targetpypystandalone.py --allworkingmodules --withmod-_rawffi --faassen

(This gives you a thread-aware pypy-c, which requires the Boehm gc library. The _rawffi module gives you ctypes support but is only tested for Linux at the moment.)

Comments

Panos Laganakos wrote on 2008-03-18 12:23:

Pretty kewl stuff from PyPy :)

Orangeman wrote on 2008-04-07 13:30:

I have a guide on most popular P2P technologies at https://sriraminhell.blogspot.com/2007/08/p2p-brief-introduction.html and on Bit Torrent at https://sriraminhell.blogspot.com/2007/08/peer-to-peer-ii-bit-torrent.html . Cheers!!

Unknown wrote on 2008-04-19 11:53:

What rev number did you build on? I tried with the latest source from svn, but got an error almost immediately. No module named py.