3 ms·
Lua is an interesting one. while true do io.write "1" end PUC-Rio 5.1: 25 MiB/s PUC-Rio 5.4: 25 MiB/s LuaJIT 2.1.0-beta3: 550 MiB/s <--- WOW
by VWWHFSfQ 4y ago
Lua is an interesting one.
while true do
io.write "1"
end
PUC-Rio 5.1: 25 MiB/s
PUC-Rio 5.4: 25 MiB/s
LuaJIT 2.1.0-beta3: 550 MiB/s <--- WOW
They all go slightly faster if you localize the reference to `io.write`
local write = io.write
while true do
write "1"
end
- yakubin 4y ago> They all go slightly faster if you localize the reference to `io.write` No noticeable difference for LuaJIT, which makes sense, since JIT should figure it out without help.