Engineering Category: Hybrid Retrieval, Ranking & Entropy
Best Use in Production: Branchless integer similarity scoring, edit-distance evaluation, and candidate ranking for high-throughput retrieval pipelines.
When to Select This Capsule: Holds the #1 Equivalence Crown across 2 functionally identical implementations (fastest verified hardware _rdtsc). Multi-step compute kernel (270845/512 cyc/op); best used at frame, block, or batch aggregation boundaries.
Snap-Circuit Wiring Role: 1-to-1 Unary Transform Stage `(u64)->u64` — snaps directly into linear pipelines or fan-out DAG branches.
.text: 66 B (17 x86_64 insns)424 B)pub fn ayeos_mt6358_sgen_crest_step_v2(semitone_state: u64) -> u64 {
let raw_div = (semitone_state >> 40) & 0x1F;
let sgen_div = if raw_div == 0 { 1 } else { raw_div };
let semi = (semitone_state >> 32) & 0x1F;
let phase_seed = semitone_state & 0xFFFF;
let crest_energy = (phase_seed + sgen_div * 125).wrapping_mul(136);
(0x5859_3080u64 << 32) | ((semi & 0xFF) << 24) | (crest_energy & 0x00FF_FFFF)
}
rustc -C opt-level=3 x86_64 Disassembly (66 B .text / 17 insns)ayeos_mt6358_sgen_crest_step_v2:
mov rax, rdi
shr rax, 40
and eax, 31
cmp rax, 1
adc rax, 0
movzx ecx, di
imul rax, rax, 125
add rax, rcx
mov rcx, rax
shl rcx, 7
lea rcx, [rcx + 8*rax]
shr rdi, 8
and edi, 520093696
movabs rax, 6366172874578853888
or rax, rdi
or rax, rcx
ret
| Global Rank | Capsule & Domain | Hardware _rdtsc | Latency | Throughput | ELF .text | Ternary Vote | Author Aye |
|---|---|---|---|---|---|---|---|
| #2046 | ayeos_mt6358_sgen_crest_step_v2 (THIS CAPSULE) domain: ayeos | id: a3475c04a630744f76fc70e301afd605 | 270845/512 cyc/op | 4386153/4096 ns/op | 4096000/4386153 ops/us | 66 B .text (17 insns) | + (1) | aye-blu-g75-mt6768 @ 432Hz |
| #2049 | ayeos_mt6358_sgen_crest_step_v1 domain: ayeos | id: e3df12a8f5b0d1b8697c17b26a3513fc | 69521/128 cyc/op | 562923/512 ns/op | 512000/562923 ops/us | 67 B .text (17 insns) | 0 (0) | aye-blu-g75-mt6768 @ 432Hz |