4 ms·
I wonder if python could possibly be as fast as js if enough money was spent on it.
by jokoon 4y ago
I wonder if python could possibly be as fast as js if enough money was spent on it.
- _joel 4y agoIt's not a case of money imho, it's a case of it's a juggernaut of a userbase and ecosystem that moves very slowly and implementing improvements to execution times (generally) are intremental changes, not paradigm shifts as they make backwards compatability a nightmare/impossible. I mean 2.x is still in the wild and some companies provide support for it, still!
- mindwok 4y agoI think the other issue if we compare it to JS is the unfortunate reliance on C that python has. When Chrome came around, JavaScript was already standardised and there were many competing implementations which had to conform to ECMAScript and give users a relatively consistent experience. So when Google made V8 they could kind of go crazy with optimisations as long as they conformed to the spec. Python on the other hand has one real implementation, and the ecosystem has become extremely intertwined with that implementation. Implementing a new Python interpreter is great, but it rarely gains traction because most of the ecosystem is so reliant on CPython specific modules that don’t work in the new interpreter so they never really get off the ground.
- IshKebab 4y agoUnlikely. Python has lots of features that were added without any thought to how to make them run fast - it simply wasn't a goal. As a result Python includes a ton of dynamic features that make it really hard to optimise.
- ahrzb 4y agoI don’t think so, there are some design choices that make the two quite different. This „dictionaries all the way down“ approach has a cost.
- miohtama 4y agoThis is possible, but it would need some backwards incompatible in the object model. We still are likely to see Python 4 on one day. People are still remembering the pain Python 3 transition caused.