[Tarantool-patches] [PATCH v2 luajit 17/41] perf: adjust nbody in LuaJIT-benches

Sergey Bronnikov sergeyb at tarantool.org
Fri Jan 2 13:55:13 MSK 2026


Hi, Sergey!

thanks for the patch! LGTM with a minor below.

Sergey

On 12/26/25 12:17, Sergey Kaplun wrote:


<snipped>

> +
> +    assert(energy(bodies, nbody) == -0.16907516382852447179,
> +             "Correct start energy")
seems broken indentation
> +    for _ = 1, N do advance(bodies, nbody, 0.01) end
> +  end,
> +  checker = function()
> +    if N == DEFAULT_N then
> +      assert(energy(bodies, nbody) == -0.16908313397890917251,
> +             "Correct result energy")
> +    end
> +    return true
> +  end,
> +  items = N,
> +})
>   
> -offsetMomentum(bodies, nbody)
> -io.write( string.format("%0.9f",energy(bodies, nbody)), "\n")
> -for i=1,N do advance(bodies, nbody, 0.01) end
> -io.write( string.format("%0.9f",energy(bodies, nbody)), "\n")
> +bench:run_and_report()
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.tarantool.org/pipermail/tarantool-patches/attachments/20260102/510bec38/attachment.htm>


More information about the Tarantool-patches mailing list