Pyston is a faster and highly-compatible fork of CPython, aiming at CPython 3.8.8 compatibility at the time of writing.
Quick tests show that Pyston can speed up Falcon up to 2x, and interestingly, its JIT is faster than our cythonization of pure Python code, so if Pyston is detected, we should not do that. However, most of falcon.cyutil.* is still worth compiling, e.g., the C-based parse_query_string is still 2x faster than our Python implementation run in Pyston. Not to complicate the matters too much, we could opt to only cythonize cyutil if Pyston is detected.
Pyston is a faster and highly-compatible fork of CPython, aiming at CPython 3.8.8 compatibility at the time of writing.
Quick tests show that Pyston can speed up Falcon up to 2x, and interestingly, its JIT is faster than our cythonization of pure Python code, so if Pyston is detected, we should not do that. However, most of
falcon.cyutil.*
is still worth compiling, e.g., the C-basedparse_query_string
is still 2x faster than our Python implementation run in Pyston. Not to complicate the matters too much, we could opt to only cythonizecyutil
if Pyston is detected.Detecting Pyston: use
hasattr(sys, "pyston_version_info")
as per its maintainers' suggestions in https://github.com/pyston/pyston/issues/36.