A Rust port of Fabrice Bellard's arbitrary-precision floating-point library, named Beeg Float, has been released. It offers full IEEE 754 compliance, various transcendental functions, and is fully compatible with no_std in Rust, providing a pure Rust implementation with no dependencies.
Beeg Float is a Rust translation of the libbf library, authored by Fabrice Bellard, that provides arbitrary-precision floating-point capabilities. It incorporates complete IEEE 754 semantics, including features like signed zeros, NaN, infinities, subnormals, and all rounding modes.
The library supports various transcendental functions such as exponential, logarithmic, and trigonometric calculations. Additionally, it offers independent base-10 arithmetic through its BigDecimal type, making it adaptable for different numerical applications.
Beeg Float is designed to maintain optimal performance similar to its C counterpart, particularly in operations like multiplication and transcendentals. Comparative benchmarks indicate that it achieves throughput comparable to libbf with minimal overhead from Rust's checks.
As a pure Rust library, Beeg Float avoids the complexities of external dependencies and system-wide installations. It can be easily integrated into projects via the cargo package manager, functioning across various targets including WASM and embedded systems.
β¨ This summary was generated by AI from the outlets' reporting listed below. It is not independently verified and may contain errors β check the original sources. How BrevFeed works β
A Rust port of Fabrice Bellard's arbitrary-precision floating-point library, named Beeg Float, has been released. It offers full IEEE 754 compliance, various transcendental functions, and is fully compatible with no_std in Rust, providing a pure Rust implementation with no dependencies.