Re:Python 3.11 beta vs. 3.10 benchmark
by SemanticStrengh on Wednesday May 18, 2022 @10:51AM
(#31423519)
and yet I'm pretty sure JS can inline just fine
Sure, so can pypy.
But that means you have to add all sorts of dependency tracking, such that you are able to deoptimise any function affected by mutation on things which were optimised in or out.
This means your complexity increases very fast, very high, before you can have anything which actually works.
Re:Python 3.11 beta vs. 3.10 benchmark
by munificent on Wednesday May 18, 2022 @01:44PM
(#31425548)
If by "just fine" you mean, "with incredible engineering resources funded by a small number of large companies with deep pockets and with some performance cost to check that the optimization is still valid", yes.
JavaScript doesn't do this, you can replace properties of window at will. I don't think Ruby does it, or Lua. PHP probably does it under some circumstances in modern versions but only because it's remarkably un-dynamic for an interpreted language.
This is normal fare for high-level interpreted languages, for better or worse.