stringtranslate.com

Psyco

Psyco is an unmaintained specializing just-in-time compiler for pre-2.7 Python originally developed by Armin Rigo and further maintained and developed by Christian Tismer. Development ceased in December, 2011.[1]

Psyco ran on BSD-derived operating systems, Linux, Mac OS X and Microsoft Windows using 32-bit Intel-compatible processors. Psyco was written in C and generated only 32-bit x86-based code.

Although Tismer announced on 17 July 2009 that work was being done on a second version of Psyco,[2] a further announcement declared the project "unmaintained and dead" on 12 March 2012 and pointed visitors to PyPy instead.[3] Unlike Psyco, PyPy incorporates an interpreter and a compiler that can generate C, improving its cross-platform compatibility over Psyco.

Speed enhancement

Psyco can noticeably speed up CPU-bound applications. The actual performance depends greatly on the application and varies from a slight slowdown to a 100x speedup.[4][5][6][7]The average speed improvement is typically in the 1.5-4x range, making Python performance close to languages such as Smalltalk and Scheme, but still slower than compiled languages such as Fortran, C or some other JIT languages like C# and Java.[8]

Psyco also advertises its ease of use: the simplest Psyco optimization involves adding only two lines to the top of a script:[9]

import psycopsyco.full()

These commands will import the psyco module, and have Psyco optimize the entire script. This approach is best suited to shorter scripts, but demonstrates the minimal amount of work needed to begin applying Psyco optimizations to an existing program.

See also

References

  1. ^ "psyco / Commits". Bitbucket. Armin Rigo.
  2. ^ Tismer, Christian (17 de julio de 2009). "[pypy-dev] ANN: psyco V2". Lista de correo de pypy-dev .
  3. ^ "Página de inicio de Psico".
  4. ^ "Parámetros de referencia de Python Psyco". Archivado desde el original el 6 de junio de 2008 . Consultado el 24 de abril de 2008 .
  5. ^ "Página de inicio de Python Psyco en sourceforge" . Consultado el 4 de marzo de 2009 .
  6. ^ "Una guía para principiantes sobre el uso de Python para la informática de rendimiento en scipy.org". Archivado desde el original el 11 de marzo de 2009 . Consultado el 4 de marzo de 2009 .
  7. ^ "Charming Python: haga que Python se ejecute tan rápido como C con Psyco". IBM . Consultado el 4 de marzo de 2009 .
  8. ^ "Resumen del diagrama de caja". Archivado desde el original el 3 de junio de 2011 . Consultado el 16 de octubre de 2009 .
  9. ^ Rigo, Armín. "Ejemplos rápidos". La guía psicológica definitiva . Consultado el 3 de junio de 2011 .

enlaces externos