1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//! # SIMD support and indicator dispatch
//!
//! This module exposes the existing standalone reduction APIs and contains the
//! architecture dispatch used by integrated Indicator batch kernels.
//!
//! [`crate::price_transform::TYPPRICEConfig`] is the first integrated Indicator
//! path. With `std`, AArch64 uses explicit NEON, x86_64 selects AVX-512F,
//! AVX2, or scalar at runtime, and wasm32 uses SIMD128 when the module is
//! compiled with `target_feature=+simd128`. Scalar WASM modules, `no_std`
//! builds, and unsupported CPUs use the scalar fallback. Streaming execution
//! remains scalar because it processes one tick at a time.
//!
//! ## Standalone API
//!
//! The existing [`sum`] and [`dot_product`] functions retain their unified
//! dispatch API:
//!
//! ```rust
//! use fast_ta::{simd, Float};
//!
//! let data: Vec<Float> = vec![1.0 as Float, 2.0 as Float, 3.0 as Float, 4.0 as Float];
//! let result = simd::sum(&data);
//! assert_eq!(result, 10.0 as Float);
//! ```
//!
//! Architecture-specific implementation modules remain private; callers use
//! Indicator configurations or these architecture-neutral standalone APIs.
use crateFloat;
use wide;
// Include arch module for all platforms with std support
use mem;
use mem;
pub use ;
/// wide f32 Float
pub type FastFloat = f32x16;
/// wide f64 Float
pub type FastFloat = f64x8;
/// Number of lanes in a SIMD vector
pub const LANES: usize = / ;