Classic Round-Up Variant of Fast Unsigned Division by Constants: Algorithm and Full Proof
Data Structures and Algorithms
2024-12-06 v1
Abstract
Integer division instruction is generally expensive in most architectures. If the divisor is constant, the division can be transformed into combinations of several inexpensive integer instructions. This article discusses the classic round-up variant of the fast unsigned division by constants algorithm, and provides full proof of its correctness and feasibility. Additionally, a simpler variant for bounded dividends is presented.
Cite
@article{arxiv.2412.03680,
title = {Classic Round-Up Variant of Fast Unsigned Division by Constants: Algorithm and Full Proof},
author = {Yifei Li},
journal= {arXiv preprint arXiv:2412.03680},
year = {2024}
}
Comments
9 pages