r/ProgrammerHumor • • 8d ago • Bravo 2 Popcorn 1

Meme pythonSlow

Post image
12k Upvotes

419 comments sorted by

View all comments

-1

u/slaymaker1907 7d ago

I'm going to push back on this and say that high-performance Python is totally possible. There's Cython which is super fast and if it's numerical code, you can use numba.

And obviously Python has very good C-interop. Rust has interop too, but it doesn't place nicely with the the borrow checker.

1

u/anzu3278 7d ago

So python is fast as long as you don't use python?

1

u/lmcinnes 7d ago

I have written pure python libraries that use numba for JIT compilation that have been performance comparable to C++ and Rust libraries for the same task. It is certainly quite possible. Sure one might be able to wring out a little extra performance with a compiled language, but not very much, and likely with quite a lot of effort.

0

u/slaymaker1907 7d ago

What part of Cython did you not read?

2

u/anzu3278 7d ago

The part after it says compiles python into something else.