MMgr v2.3.0
Zero-heap memory manager in C11. One borrowed buffer, carved by asserted offset.
Loading...
Searching...
No Matches
pow5.h File Reference

Powers of five as 128-bit significands, for the scale of a decimal mantissa into a binary one. More...

#include "mmgr.h"

Go to the source code of this file.

Data Structures

struct  MmgrPow5
 One power of five, as a 128-bit significand with a binary exponent. More...

Macros

#define MMGR_POW5_STEPS
 Expands to 9, the number of entries in each table.
#define MMGR_POW5_MAX
 Expands to ((1 << 9) - 1), which is 511, the largest decimal exponent the tables reach.

Variables

static EMBED_PASS_MEMORY const MmgrPow5 mmgr_pow5_up [MMGR_POW5_STEPS]
 Five raised to each power of two, from 5^1 at index 0 to 5^256 at index 8.
static EMBED_PASS_MEMORY const MmgrPow5 mmgr_pow5_down [MMGR_POW5_STEPS]
 The reciprocal of each mmgr_pow5_up entry, from 5^-1 at index 0 to 5^-256 at index 8.

Detailed Description

Powers of five as 128-bit significands, for the scale of a decimal mantissa into a binary one.

Author
dstroy0 (Douglas Quigg) dquig.nosp@m.g123.nosp@m.@gmai.nosp@m.l.co.nosp@m.m
Date
2026-08-29
Note
transformo walks the bits of the decimal exponent and multiplies in one entry per set bit, and so nine entries reach 511.
Declares no function. Both tables are static const data that outlive every call. A pointer into one stays good for the whole program [BORROWS].

Definition in file pow5.h.