Thread:Talk:Requests for comment/Magic expressions/So what's the point?/reply (2)

Your claims about "solving the problem of performance magic words" doesn't make much sense. How does your proposed extension not also "shift the problem from blame on others"?

As for actual performance, have you compared your extension with an equivalent Scribunto module using luasandbox? On my laptop (Thinkpad T430, core i5 2.60GHz, 4G RAM, PHP 5.5.9), pure PHP took about the same (0.034s) to run your "100000 loops" example while Scribunto took only 0.008s. I also increased it to 100000000 loops, and there pure PHP took 16.2 seconds compared to Scribunto's 5.8s.

MediaWiki core limits execution time and memory consumption by having a lot of smart people reviewing code before it's deployed, and by monitoring actual usage, and by not allowing random people to embed arbitrary code in wiki pages. Scribunto in luasandbox mode limits execution time and memory consumption by counting every malloc and checking the time used at each Lua instruction, and in luastandalone by setting ulimits on the external process.

I agree with MaxSem: If you're making this RFC to try to get this deployed on WMF sites, it seems unlikely to succeed. And if you're wanting to use it somewhere else, just do it.