From b9debec106f2ac6e15d6dff88260f133d9eafcb2 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Thu, 3 Mar 2016 13:59:54 +0100 Subject: Optimised zdivmod MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/zsetup.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/zsetup.c') diff --git a/src/zsetup.c b/src/zsetup.c index f7c1912..78cfa3b 100644 --- a/src/zsetup.c +++ b/src/zsetup.c @@ -8,6 +8,7 @@ LIST_TEMPS LIST_CONSTS #undef X +z_t libzahl_tmp_divmod_ds[BITS_PER_CHAR]; jmp_buf libzahl_jmp_buf; int libzahl_set_up = 0; @@ -15,6 +16,7 @@ int libzahl_set_up = 0; void zsetup(jmp_buf env) { + size_t i; libzahl_jmp_buf = jmp_buf; if (!libzahl_set_up) { @@ -27,5 +29,7 @@ zsetup(jmp_buf env) zinit(x), f(x, v); LIST_CONSTS; #undef X + for (i = BITS_PER_CHAR; i--;) + zinit(libzahl_tmp_divmod_ds[i]); } } -- cgit v1.2.3-70-g09d2