Differences between revisions 2 and 12 (spanning 10 versions)
Revision 2 as of 2008-11-15 03:00:40
Size: 646
Editor: PhilipJenvey
Comment:
Revision 12 as of 2009-01-26 05:40:07
Size: 1472
Editor: c-98-212-140-18
Comment: The plots are fixed. Sorry about that.
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:
==================================
Line 7: Line 8:
Benchmark plots (currently broken): http://freya.cs.uiuc.edu/~njriley/plots.html Plots of microbenchmarks (also from PyPy): http://freya.cs.uiuc.edu/~njriley/plots.html
Line 12: Line 13:
GC Expense
----------
jbaker & thobe's JavaOne '08 talk: `Jython Implementing Dynamic Language Features For The Java Ecosystem`_

Allocation/GC Expense
---------------------
Line 16: Line 19:
Frame creation
--------------
* dicts/stringmap

PyStringMap/PyDictionary pay a penalty on allocation now that they're backed by ConcurrentHashMap. We could probably tweak the ConcurrentHashMap initialCapacity, concurrentLevel to reduce this cost


* Frames
Line 19: Line 27:

Advanced Compiler
-----------------

Modules to rewrite in Java
--------------------------
* _heapq
* select
* socket
* unicodedata

iterlen support
---------------
Adds a length hint to various objects, mainly for smarter allocation during map and list. See test_iterlen

.. _`Jython Implementing Dynamic Language Features For The Java Ecosystem`: http://developers.sun.com/learning/javaoneonline/2008/pdf/TS-6039.pdf?cid=925321

Performance Enhancements Resources

Jython benchmarks (from PyPy's suite): http://freya.cs.uiuc.edu/~njriley/benchmark.html

Plots of microbenchmarks (also from PyPy): http://freya.cs.uiuc.edu/~njriley/plots.html

Ideas

jbaker & thobe's JavaOne '08 talk: Jython Implementing Dynamic Language Features For The Java Ecosystem

Allocation/GC Expense

Our algorithms are not always the problem, sometimes it's memory {de}allocations that slow you down

  • dicts/stringmap

PyStringMap/PyDictionary pay a penalty on allocation now that they're backed by ConcurrentHashMap. We could probably tweak the ConcurrentHashMap initialCapacity, concurrentLevel to reduce this cost

  • Frames

Frames are allocated for every Python method call, which is a GC expense. CPython (and JRuby?) recycle frame objects. Reducing the number of fields on the frame can also help (but this likely isn't possible)

Advanced Compiler

Modules to rewrite in Java

  • _heapq
  • select
  • socket
  • unicodedata

iterlen support

Adds a length hint to various objects, mainly for smarter allocation during map and list. See test_iterlen

PerformanceEnhancements (last edited 2009-01-26 05:40:07 by c-98-212-140-18)