Skip to content
Preprint

Improved Tristate Multiplication With Formalization in Rocq

Sep 2026 · 0 citations · 20 references
Computer Science

TL;DR

A new multiplication algorithm for tristate numbers improving upon the state-of-the-art implementation from the Linux kernel in terms of precision and formal proofs is given, and the soundness and optimality of the newly added tnum union operation and the existing tnum addition algorithm are provided.

Abstract

We give a new multiplication algorithm for tristate numbers improving upon the state-of-the-art implementation from the Linux kernel in terms of precision and formal proofs. Our algorithm is significantly more precise as shown by experimental evaluation (at the peak, giving better results in 95.59% cases compared to the previous work for 31-bit samples). Importantly, we achieve this additional precision with performance comparable to the previous algorithm, as demonstrated by benchmarks. Finally, we formalize and prove the soundness of the algorithm in the Rocq proof assistant, adding to the trust in the resulting implementation. Our algorithm is now part of the upstream Linux kernel. Our soundness proof in Rocq for the new multiplication algorithm works for all bit widths, while the SAT/SMT-based machine-checked proof accompanying the previous algorithm was restricted to 8 bits. We also provide Rocq proofs for the soundness and optimality of the newly added tnum union operation and the existing tnum addition algorithm from the Linux kernel. Our optimality proof for tnum addition presents a simpler and straightforward lemma compared to prior work.

View source

Similar papers

Open access Sep 2026

RainHash2.0: Hardware- and Arithmetization-friendly Hash Function

Zero-knowledge (ZK) proof systems have developed rapidly in recent years, with hash functions as one of their central building blocks. Since these often dominate the prover cost, circuit-friendly hash function design has become an active research area. Most hash proposals target prime fields, although recent protocols...

Jia-Min Cui, Lorenzo Grassi, Katharina Koschatko et al. · 1 citation
Book Open access Sep 2026

Proof-Carrying-BPF Programs for the eBPF Verifier

A userspace version of the kernel verifier is developed and appended to the BPF backend to increase the class of programs accepted by the Linux eBPF verifier without increasing its complexity.

Ya-Lu Cai, Santosh Nagarakatte · 0 citations
Preprint Oct 2026

Faster PMNS Multi-precision Multiplications Using Truncated Montgomery Technique

The Polynomial Modular Number Systems (PMNS) aim to represent elements of fields or rings of large characteristics using polynomials satisfying bounds on some parameters (degree, absolute values of the coefficients). Those PMNS, while some conditions are fulfilled, using convenient parameters and implementation feature...

Laurent-Stéphane Didier, Alexy Dutois-Ruiz, Jean-Marc Robert · 0 citations
Preprint Sep 2026

A performance enhancement of the Payne-Hanek range reduction algorithm

Range reduction plays a crucial role in the accuracy and performance of evaluating trigonometric functions, and is often the primary bottleneck for large floating-point inputs. While fast algorithms such as Cody--Waite work efficiently over narrow intervals, the Payne--Hanek algorithm remains the standard technique for...

Tue Ly · 1 citation
Preprint Sep 2026

Compressed Permutation Oracles Revisited

The compressed permutation oracle has been used to analyze the quantum security of a number of cryptographic constructions which resisted prior techniques. However, these analyses were fundamentally limited by the poor soundness of the method: the technique was proven sound only up to $O(N^{1/12})$ queries to permutati...

Joseph Carolan, Christian Majenz · 1 citation

We use cookies to run the site and, with your consent, for analytics and to show ads. See our Cookie Policy.