News for hackers. Stuff that matters.
Re:Guido van Rossum joins Microsoft by ablekh on Thursday November 12, 2020 @10:59PM (#25078688)
I'm curious about sources for your claim of Python being 100-1000x slower than Go or Java. While the lower bound of the cited range is realistic (but only for certain problems), the majority of the range is highly unlikely. According to my sources, the difference is not that dramatic: depending on a specific type of a problem, it ranges from 1.5x to 100x. For applications using relevant Web frameworks, the composite difference is just 4-5x.

As for scientific computing domain, I would start a new project in Julia rather than Python.

Re:Guido van Rossum joins Microsoft by throwaway894345 on Friday November 13, 2020 @08:12AM (#25081778)
It’s a ballpark estimate from various real world benchmarks I’ve done over the years (I’ve spent a lot of my career optimizing Python, including rewriting things on occasion). In the case of web framework benchmarks, I’m guessing that the fastest Python web frameworks are almost pure-C, and the benchmark is probably running very little actual Python code (while the Go benchmarks are pure-Go) this doesn’t extrapolate well to real world applications where the web server is never the bottleneck and your bottleneck tends to be app code that isn’t easily rewritten in C. Mostly the 100-1000X figure is intended to compare pure-Python code with pure-Go or pure-Java.
Re:Guido van Rossum joins Microsoft by ablekh on Friday November 13, 2020 @04:53PM (#25087967)
I guess, your ballpark estimate is too rough (and/or Python 3 has improved significantly since then). The sources / benchmarks that I used to back up my claims [1-3] imply use of pure Python, not "almost pure-C". That includes Web frameworks (FastAPI that I compared to Java / Go frameworks is pure Python, which, in turn, is based on Starlette, a pure-Python implementation of an ASGI framework).

[1] https://benchmarksgame-team.pages.debian.net/benchmarksgame/...

[2] https://github.com/frol/completely-unscientific-benchmarks

[3] https://www.techempower.com/benchmarks/#section=data-r19&hw=...