This page describes possible Summer of Code projects related to the Python 3 JIT, developed originally under the name "Unladen Swallow".
Contact: Collin Winter <collinwinter@google.com>
Develop a JIT-accelerated regex engine: pick up, extend existing work if applicable; make necessary improvements to the common benchmark suite; make necessary improvements to Python's correctness tests; implement JIT acceleration for 50% of regexes in benchmark suite; zero correctness regressions; zero performance regressions; demonstrate 25% performance improvement in regex benchmarks.
Convert JIT output from stack machine to register machine (reference, reference); demonstrate improvement in generated LLVM IR; demonstrate improvement in performance across relevant benchmarks; make necessary improvements to benchmark suite.
- Optimize looping constructs; expose Python-level loops to LLVM's loop optimization passes; avoid allocating objects on the heap in the fast path; be able to bail back to the interpreter seamlessly; make necessary improvements to Python's correctness tests; demonstrate performance improvements across relevant benchmarks.
- Develop tools for exposing JIT data to developers for performance debugging; annotate source code with gathered types; annotate source code with bail sites; enable developers to answer the questions, "how do I make this application faster?", "why did my application slow down?"; integrate with existing tools like cProfile, or develop new tools as appropriate.
Develop a comprehensive suite of fuzz testing tools for Python. Fuzz testing is an important tool for stressing a compiler. With the addition of a JIT compiler to Python 3, fuzz testing is more important than ever. The student will evaluate the existing Python fuzz testing tools and extend them when needed: pyfuzz for source-level fuzzing, fusil for API fuzzing. The student will develop a new fuzzer for CPython bytecode to stress-test the bytecode->x86 JIT compiler (reference). The student will set up an automated system for continuously fuzzing a given CPython binary, along the lines of the current CPython buildbot system, including some kind of dashboard to display the results. The student will fix any bugs discovered by the fuzzing tools.