From 317c0644ccf108aa23ef3fd8358bd66c2840bfc0 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 14 Apr 2024 15:40:54 +0200 Subject: Adding upstream version 5:7.2.4. Signed-off-by: Daniel Baumann --- deps/jemalloc/src/ticker.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100755 deps/jemalloc/src/ticker.py (limited to 'deps/jemalloc/src/ticker.py') diff --git a/deps/jemalloc/src/ticker.py b/deps/jemalloc/src/ticker.py new file mode 100755 index 0000000..3807740 --- /dev/null +++ b/deps/jemalloc/src/ticker.py @@ -0,0 +1,15 @@ +#!/usr/bin/env python3 + +import math + +# Must match TICKER_GEOM_NBITS +lg_table_size = 6 +table_size = 2**lg_table_size +byte_max = 255 +mul = math.floor(-byte_max/math.log(1 / table_size)) +values = [round(-mul * math.log(i / table_size)) + for i in range(1, table_size+1)] +print("mul =", mul) +print("values:") +for i in range(table_size // 8): + print(", ".join((str(x) for x in values[i*8 : i*8 + 8]))) -- cgit v1.2.3