by now it's clear that adaptive optimization is a universal technique that can make *any* program fast; enough speculative inlining at run-time (and dollars thrown at VM engineers) will burn away all abstractions. but there is more AOT compilation of dynamic languages than there used to be: Swift, Dart, JS via Hermes et al; and for AOT there is no one universal technique
Conversation
Notices
-
Embed this notice
Andy Wingo (wingo@mastodon.social)'s status on Tuesday, 27-Jun-2023 20:05:29 JST Andy Wingo -
Embed this notice
iain ireland (iainireland@mstdn.ca)'s status on Wednesday, 28-Jun-2023 12:58:14 JST iain ireland @wingo
As a VM engineer, I'm not sure I agree. SpiderMonkey inlines fairly conservatively. Old benchmarks like Octane (Raytracing! GameBoy emulation! Physics simulations!) benefit from inlining, but more realistic benchmarks like Speedometer mostly don't. When I wrote the initial implementation of the current inliner, I tuned the heuristics by looking for a sweet spot where it improved Octane and didn't actively hurt Speedometer. -
Embed this notice
iain ireland (iainireland@mstdn.ca)'s status on Wednesday, 28-Jun-2023 12:58:14 JST iain ireland I believe JSC and V8 also see minimal slowdowns on Speedometer if you turn off inlining.
The dilemma of optimizing at runtime is that you have plenty of dynamic information, but not enough time to make ideal use of it.
Roy Tam likes this.
-
Embed this notice