Skip to main content

Crate ta_lib_dispatch

Crate ta_lib_dispatch 

Source
Expand description

Runtime CPU-feature dispatch for the ta-lib crate (issue #156).

Support crate: it exists so the library crate can stay #![forbid(unsafe_code)] while selecting hardware-FMA clones at runtime — the single unsafe in the ta-lib workspace lives here, adjacent to the CPU-feature check that justifies it. This is the Rust analogue of the C library’s __attribute__((target_clones("default","fma"))) ifunc dispatch. Internal contract; no semver promises outside the ta-lib workspace.

Macros§

dispatch_fma
Dispatch one indicator call to its hardware-FMA clone when the CPU supports FMA, else to the portable implementation.