Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
PyPy: More Compact Lists with List Strategies (morepypy.blogspot.com)
7 points by DasIch on Oct 11, 2011 | hide | past | favorite | 1 comment


I have been more and more amazed at how powerful PyPy turns out to be. In order to eke out a small space-and-time improvement on lists they implemented multiple versions of lists: general-lists, integer-lists, string-lists, empty-lists, and range-of-integer-lists. This is invisible to the programmer, who can create a list of 3 integers and then append a string and the data structure will silently change itself behind the scenes. They have even done things like changing the sorting algorithm (eg: integer comparisons are super-fast so a different sorting algorithm is optimal). That is deeply powerful magic, and I shudder to think how difficult it would be to implement the same features in an interpreter or compiler written in C. And all this with just a handful of nearly-full-time programmers!




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: