[Twisted-Python] Twisted and unladen swallow

György Vilmos vilmos.gyorgy at gmail.com
Sat Jul 11 13:16:26 EDT 2009

Hi All,

I use twisted as a flexible (authoritative) DNS server, and apart from its
speed, I'm completely pleased with it.
As you may know, Google has started a project -named unladen swallow- to
improve python's performance, so I've taken a quick look at it, compiling
the latest version (from svn trunk, which is based on python 2.6.1) on
FreeBSD and compared the numbers with plain python's (2.6.2) performance.

As this is a DNS server, the performance indicator is queries per second.

The numbers are here (in hungarian):

The first table has the stock 2.6.2 python vs unladen python performance
numbers (with an average of 3.5% speed increase), while the next table shows
relative performance between unladen's -j whenhot and -j always settings
(the first compiles code only when it's frequently executed, while the
latter compiles everything at the first occurrence).
-j always of course eats a lot of CPU power when compiling and also
maintains a big memory footprint (712 MiB resident memory) throughout the
process lifecycle.

I hope the guys will be able to squeeze more out of python...


More information about the Twisted-Python mailing list