Arithmetic computations written for Lua 5.1 appear to be 1.25 times slower in Lua 5.4 (compared to Lua 5.1)
(Probably, this happened because of heavy mixing of floats with integers in arithmetic expressions.)
Maybe one of reason is that `Integer modulus` is slower than `Float modulus`, See function `luaV_mod` in lvm.c .