\begin{lemma}
For every signed decimal exponent $q$, unsigned word $w$, and biased pair $b$,
if the concrete binary64 invocation of \texttt{compute\_float} on $(q,w)$
returns $b$, then
\[
                         b.m.\mathit{val}\leq 2^{52}.
\]
\end{lemma}
\begin{proof}
Write $U=2^{52}$.  By \noderef{ParserExponentConstants}, the concrete
binary64 instance has \texttt{SIG\_BITS}$=52$, infinite power $2047$,
smallest and largest supported decimal powers $-342$ and $308$, exponent
minimum $-1022$, and round-to-even cutoffs $-4$ and $23$.  Substitute these
equalities while unfolding \noderef{num_imp_dec2flt_lemire_compute_float}.
The zero, infinity, and error pairs constructed by
\noderef{num_imp_dec2flt_common_BiasedFp_zero_pow2} all have mantissa zero.
Consequently the $w=0$, $q<-342$, $q>308$, unsafe-approximation, severe
underflow, and final exponent-saturation exits satisfy the claimed bound.
Every checked operation mentioned below occurs before the corresponding
return in the result monad, so failure of a cast, arithmetic operation, or
shift is incompatible with the assumed successful result.

It remains to treat the two product blocks.  They are syntactically
identical after the approximation guard, and the Lean proof checks both
copies.  Let $(lo,hi)$ be the successful result of
\noderef{num_imp_dec2flt_lemire_compute_product_approx}.  The preliminary
normalization shift has succeeded.  The high-word shift by $63$ is legal and
returns its top bit $u\in\{0,1\}$; its cast to \texttt{i32} is exact.  The
checked calculation of the next shift count is
\[
                         u+64-52-3=u+9.
\]
If $u=0$, then $hi<2^{63}$ and $hi\mathbin{\mathtt{>>}}9<2^{54}$.
If $u=1$, the universal 64-bit bound gives
$hi\mathbin{\mathtt{>>}}10<2^{54}$.  Thus the local pre-rounding mantissa
$x$ is always strictly below $2^{54}$.  This argument applies both when the
all-ones low word passes its safe-exponent test and when the low word is not
all ones.

Suppose first that the calculated binary power is nonpositive.  Successful
negation and addition form the shift count $k=-\texttt{power2}+1$.  If
$k\geq64$, the result is the zero pair.  Otherwise $1\leq k<64$.  By the
exact right-shift semantics of \noderef{ModelU64Shr},
$x_1=x\mathbin{\mathtt{>>}}k<2^{53}$.  By
\noderef{ModelU64BitAnd}, $e=x_1\mathbin{\mathtt{\&}}1$ is at most one.
The successful checked addition therefore has value at most $2^{53}$, and
the subsequent right shift by one returns a mantissa at most $2^{52}=U$.
The comparison against the legally formed word $1\mathbin{\mathtt{<<}}52$
only chooses the returned exponent and does not alter this mantissa.

Now suppose the calculated power is positive.  The nested round-to-even
probe either preserves $x$ or clears its low bit, so its output $x_1$ is at
most $x$ by \noderef{ModelU64BitAnd}.  Its low bit is again at most one.
The successful addition and right shift by one therefore produce
$x_3\leq2^{53}$.  The threshold
$2\mathbin{\mathtt{<<}}52=2^{53}$ and the replacement
$1\mathbin{\mathtt{<<}}52=U$ are legal by \noderef{ModelU64Shl}.  In the
carrying branch, $x_3\geq2^{53}$ combines with the preceding upper bound to
give equality and the code replaces it by $U$.  In the noncarrying branch,
$x_3<2^{53}$.  Hence the value immediately before the final mask is always
strictly below $2^{53}$.

The final mask is the 64-bit complement of $U$, namely
$2^{64}-1-U$.  Conjunction with it clears bit $52$.  A value below
$2^{53}$ has no higher set bit, so the masked value is below $U$; the Lean
proof establishes this bitwise by comparing bit $52$ and all higher bits.
The following saturation test either returns the already-treated zero
mantissa infinity pair or this masked record.  This exhausts every successful
return in both duplicated product blocks and proves the stated uniform
bound.
\end{proof}
