rustc -C opt-level=3): 2049 (203973 B .text / 53737 insns)22/9 Hz): 248869 B / 5979051 B (ratio 248869/5979051, saved 5730182/5979051, 11695 ″ dittos)| Rank & Crown | Function Name & Domain | Best Use & Snap-Circuit Role | Pin Signature & 64-Vec Hash | Hardware _rdtsc (p/q) | Details & Quick Peek |
|---|---|---|---|---|---|
| #525 SOLE CROWN #1 <10 CYC | tanh_q8 domain: smart-tree | id: 594ccc7050c2Aye: aye::Hue+Gemini(0+1)::x86_64 @ 432Hz | Lossless Wire & Structural Compression Zero-allocation integer bit-packing, variable-length encoding, and stream framing for sovereign wire protocols. Specialized Multi-Pin Stage `(i32)->i16` — wire matching input pins via `snap_dag` or `snap_pipeline`. | (i32)->i1664-vec BLAKE3: 009b6fbe7535C64 RAM: 445/65536 (445 B src) | 1301907/200000 cyc/op 620129/200000 ns/op | 200000000/620129 ops/us 83 B .text (22 insns) | Trit + (1) | Inspect Details & ASM →Quick Peek Rust (445 B)pub const fn tanh_q8(x_q8: i32) -> i16 {
let x = if x_q8 < -768 {
-768
} else if x_q8 > 768 {
768
} else {
x_q8
};
let x2_q8 = (x * x) >> 8;
let num = x * ((27 << 8) + x2_q8);
let den_raw = (27 << 8) + 9 * x2_q8;
let den = if den_raw > 1 { den_raw } else { 1 };
let q = num / den;
if q < -256 {
-256
} else if q > 256 {
256
} else {
q as i16
}
} |