It would be better for Python to support AOT compile officially

I’m the author of this thread: AOT instead of JIT
Here are some points to consider based on the experience with the last discussion:

  • AOT vs JIT is not purely a technical decision. It also has a lot to do with what users perceive as programming style and deployment practices.

  • The AOT world may not be familiar to many Python users, especially those active in this community, since many have backgrounds in statistics and other scientific fields, not software engineering or computer systems.

  • Many users are unaware that modern AOT technologies have advanced significantly , to the point where they can provide the same advantages of dynamic typing with a REPL (Read-Eval-Print Loop).

  • There’s nothing wrong with CPython for its intended historical purposes. It’s a simple VM for translating Python scripts, and recent improvements have made it even better at that. However, any real changes would require a completely different implementation.

  • Python is maintained by volunteers who may not have the time and resources for radical changes. You might encounter responses like “Go write one” or “Submit an official PEP” when trying to discuss the topic, which can be frustrating, but that’s how things are currently handled.

  • Many with serious backgrounds in computing use Python for lightweight tasks or as a prototyping language. Once the idea is clear enough, the production implementation gets done in other languages like C++ or Rust.

  • For heavy workloads, consider Rust. It integrates well with Python, has a high-level syntax and functions (very functional by design), and a rapidly growing ecosystem of libraries with significant investments, especially for massive data processing (Polars, Apache DataFusion, etc.).

  • There are attempts like Mojo to create a language similar to Python with interop with CPython. It incorporates features from Rust and Swift to combine usability with performance and type safety, but it’s still under development.

I hope these points are helpful regarding this ‘duplicate’ discussion.

3 Likes