softfp

Crates.iosoftfp
lib.rssoftfp
version0.1.0
sourcesrc
created_at2021-10-10 01:30:26.588446
updated_at2021-10-10 01:30:26.588446
descriptionSoftware floating point operation library
homepage
repositoryhttps://github.com/nbdd0121/softfp
max_upload_size
id462972
size68,016
Gary Guo (nbdd0121)

documentation

README

softfp

Software floating point operation library.

Many floating operations require a rounding mode and can set a few exception flags. This library therefore expects two callbacks, softfp_get_rounding_mode and softfp_set_exception_flags. You can define them with #[no_mangle]. The calling convention is Rust, so there is no need for extern "C".

If you prefer not to define these callbacks with #[no_mangle], you can use the enabled-by-default "register" feature which allow you to register the function via register_get_rounding_mode and register_set_exception_flags instead. You must register them before using the library for any floating point operations. The simplest way would be track them using thread_local! variables.

Commit count: 13

cargo fmt