Closed ochaton closed 2 years ago
tarantool -l clock -l metrics -l fun -l jit -e 'counter = metrics.counter("fast_counter")' -i
Tarantool 2.10.0-beta2-368-gfea8c8e40
tarantool> clock.bench(function() return fun.range(1, 1e7):map(function(t) counter:inc(1) return t end):length() end)
---
- - 3.367997
- 10000000
...
tarantool> clock.bench(function() return fun.range(1, 1e7):map(function(t) counter:inc(1) return t end):length() end)
---
- - 0.028591
- 10000000
...
jitable counter:inc and counter:set if no labels used
I didn't following: