Skip to content

feat: add SIMD alignment algorithms - #22

Draft
claymcleod wants to merge 11 commits into
mainfrom
simd-algorithms
Draft

claymcleod wants to merge 11 commits into
mainfrom
simd-algorithms

Conversation

@claymcleod

Copy link
Copy Markdown
Member

omics-alignment had deterministic scalar global and local alignment but no byte-oriented SIMD path for high-throughput sequence comparison. This added adaptive i16/i32 anti-diagonal wavefronts with exact scalar parity, Apple Silicon NEON, runtime-detected Linux AVX2, compact traceback, and scalar fallback for unsupported hardware or score ranges.

Differential tests covered edge cases and fixed-seed workloads on both native backends, while benchmarks and CI added Apple Silicon and Linux coverage. Apple Silicon performance met the acceptance target; AVX2 timing remains provisional until the same benchmark runs on physical AMD64 hardware, although AVX2 correctness and generated hot-loop instructions were verified.

Before submitting this PR, please make sure:

For all contributors:

  • You have added a few sentences describing the PR here.
  • Your code builds clean without any errors or warnings.
  • You have added tests (when appropriate).
  • You have updated the README or other documentation to account for these changes (when appropriate).
  • You have added an entry to the relevant CHANGELOG.md (see "keep a changelog" for more information).
  • Your commit messages follow the conventional commit style.
  • Your PR title follows the conventional commit style.

@github-actions

github-actions Bot commented Jul 23, 2026 •

Copy link
Copy Markdown

🐰 Bencher Report

Projectomics
Branchmain
Testbedgithub-actions

⚠️ WARNING: No Threshold found!

Without a Threshold, no Alerts will ever be generated.

Click here to create a new Threshold
For more information, see the Threshold documentation.
To only post results if a Threshold exists, set the --ci-only-thresholds flag.

Click to view all benchmark results
BenchmarkLatencynanoseconds (ns)
algorithms/global/asymmetric/scalar/1024📈 view plot
⚠️ NO THRESHOLD
20,412,000.00 ns
algorithms/global/asymmetric/scalar/16📈 view plot
⚠️ NO THRESHOLD
5,357.20 ns
algorithms/global/asymmetric/scalar/256📈 view plot
⚠️ NO THRESHOLD
1,177,200.00 ns
algorithms/global/asymmetric/scalar/64📈 view plot
⚠️ NO THRESHOLD
74,430.00 ns
algorithms/global/asymmetric/simd/1024📈 view plot
⚠️ NO THRESHOLD
1,582,600.00 ns
algorithms/global/asymmetric/simd/16📈 view plot
⚠️ NO THRESHOLD
4,375.20 ns
algorithms/global/asymmetric/simd/256📈 view plot
⚠️ NO THRESHOLD
139,390.00 ns
algorithms/global/asymmetric/simd/64📈 view plot
⚠️ NO THRESHOLD
19,518.00 ns
algorithms/global/balanced/scalar/1024📈 view plot
⚠️ NO THRESHOLD
40,624,000.00 ns
algorithms/global/balanced/scalar/16📈 view plot
⚠️ NO THRESHOLD
9,792.20 ns
algorithms/global/balanced/scalar/256📈 view plot
⚠️ NO THRESHOLD
2,343,100.00 ns
algorithms/global/balanced/scalar/64📈 view plot
⚠️ NO THRESHOLD
148,820.00 ns
algorithms/global/balanced/simd/1024📈 view plot
⚠️ NO THRESHOLD
3,223,600.00 ns
algorithms/global/balanced/simd/16📈 view plot
⚠️ NO THRESHOLD
7,519.40 ns
algorithms/global/balanced/simd/256📈 view plot
⚠️ NO THRESHOLD
276,370.00 ns
algorithms/global/balanced/simd/64📈 view plot
⚠️ NO THRESHOLD
36,720.00 ns
algorithms/global/gap-heavy/scalar/1024📈 view plot
⚠️ NO THRESHOLD
47,873,000.00 ns
algorithms/global/gap-heavy/scalar/16📈 view plot
⚠️ NO THRESHOLD
12,023.00 ns
algorithms/global/gap-heavy/scalar/256📈 view plot
⚠️ NO THRESHOLD
2,737,000.00 ns
algorithms/global/gap-heavy/scalar/64📈 view plot
⚠️ NO THRESHOLD
176,600.00 ns
algorithms/global/gap-heavy/simd/1024📈 view plot
⚠️ NO THRESHOLD
3,763,900.00 ns
algorithms/global/gap-heavy/simd/16📈 view plot
⚠️ NO THRESHOLD
7,860.60 ns
algorithms/global/gap-heavy/simd/256📈 view plot
⚠️ NO THRESHOLD
309,550.00 ns
algorithms/global/gap-heavy/simd/64📈 view plot
⚠️ NO THRESHOLD
38,903.00 ns
algorithms/local/asymmetric/scalar/1024📈 view plot
⚠️ NO THRESHOLD
22,405,000.00 ns
algorithms/local/asymmetric/scalar/16📈 view plot
⚠️ NO THRESHOLD
5,234.00 ns
algorithms/local/asymmetric/scalar/256📈 view plot
⚠️ NO THRESHOLD
1,268,200.00 ns
algorithms/local/asymmetric/scalar/64📈 view plot
⚠️ NO THRESHOLD
79,591.00 ns
algorithms/local/asymmetric/simd/1024📈 view plot
⚠️ NO THRESHOLD
2,336,600.00 ns
algorithms/local/asymmetric/simd/16📈 view plot
⚠️ NO THRESHOLD
4,573.00 ns
algorithms/local/asymmetric/simd/256📈 view plot
⚠️ NO THRESHOLD
189,580.00 ns
algorithms/local/asymmetric/simd/64📈 view plot
⚠️ NO THRESHOLD
22,315.00 ns
algorithms/local/balanced/scalar/1024📈 view plot
⚠️ NO THRESHOLD
44,677,000.00 ns
algorithms/local/balanced/scalar/16📈 view plot
⚠️ NO THRESHOLD
10,252.00 ns
algorithms/local/balanced/scalar/256📈 view plot
⚠️ NO THRESHOLD
2,544,000.00 ns
algorithms/local/balanced/scalar/64📈 view plot
⚠️ NO THRESHOLD
159,620.00 ns
algorithms/local/balanced/simd/1024📈 view plot
⚠️ NO THRESHOLD
4,733,400.00 ns
algorithms/local/balanced/simd/16📈 view plot
⚠️ NO THRESHOLD
8,086.60 ns
algorithms/local/balanced/simd/256📈 view plot
⚠️ NO THRESHOLD
378,160.00 ns
algorithms/local/balanced/simd/64📈 view plot
⚠️ NO THRESHOLD
42,740.00 ns
algorithms/local/gap-heavy/scalar/1024📈 view plot
⚠️ NO THRESHOLD
52,153,000.00 ns
algorithms/local/gap-heavy/scalar/16📈 view plot
⚠️ NO THRESHOLD
12,637.00 ns
algorithms/local/gap-heavy/scalar/256📈 view plot
⚠️ NO THRESHOLD
2,980,300.00 ns
algorithms/local/gap-heavy/scalar/64📈 view plot
⚠️ NO THRESHOLD
189,370.00 ns
algorithms/local/gap-heavy/simd/1024📈 view plot
⚠️ NO THRESHOLD
5,457,300.00 ns
algorithms/local/gap-heavy/simd/16📈 view plot
⚠️ NO THRESHOLD
8,253.20 ns
algorithms/local/gap-heavy/simd/256📈 view plot
⚠️ NO THRESHOLD
422,250.00 ns
algorithms/local/gap-heavy/simd/64📈 view plot
⚠️ NO THRESHOLD
46,104.00 ns
contig::new📈 view plot
⚠️ NO THRESHOLD
19.18 ns
coordinates::interbase::try_new📈 view plot
⚠️ NO THRESHOLD
27.27 ns
intervals::interbase::from_raw_coordinates📈 view plot
⚠️ NO THRESHOLD
60.07 ns
intervals::interbase::try_new_prepared📈 view plot
⚠️ NO THRESHOLD
16.37 ns
positions::base::checked_add📈 view plot
⚠️ NO THRESHOLD
1.76 ns
positions::base::checked_sub📈 view plot
⚠️ NO THRESHOLD
2.11 ns
positions::base::try_new📈 view plot
⚠️ NO THRESHOLD
0.35 ns
positions::interbase::checked_add📈 view plot
⚠️ NO THRESHOLD
0.71 ns
positions::interbase::checked_sub📈 view plot
⚠️ NO THRESHOLD
0.70 ns
positions::interbase::new📈 view plot
⚠️ NO THRESHOLD
0.35 ns
structural::classify::deletion📈 view plot
⚠️ NO THRESHOLD
6.69 ns
structural::classify::insertion📈 view plot
⚠️ NO THRESHOLD
6.68 ns
structural::classify::interchromosomal_translocation📈 view plot
⚠️ NO THRESHOLD
5.99 ns
structural::classify::intrachromosomal_translocation📈 view plot
⚠️ NO THRESHOLD
67.64 ns
structural::classify::inversion📈 view plot
⚠️ NO THRESHOLD
12.62 ns
structural::classify::tandem_duplication📈 view plot
⚠️ NO THRESHOLD
5.63 ns
structural::parse::deletion📈 view plot
⚠️ NO THRESHOLD
444.98 ns
structural::parse::insertion📈 view plot
⚠️ NO THRESHOLD
858.82 ns
structural::parse::interchromosomal_translocation📈 view plot
⚠️ NO THRESHOLD
443.60 ns
structural::parse::intrachromosomal_translocation📈 view plot
⚠️ NO THRESHOLD
1,451.40 ns
structural::parse::inversion📈 view plot
⚠️ NO THRESHOLD
966.38 ns
structural::parse::tandem_duplication📈 view plot
⚠️ NO THRESHOLD
561.04 ns
variants::display::insertion_interbase_qualified📈 view plot
⚠️ NO THRESHOLD
236.00 ns
variants::display::snv_base_qualified📈 view plot
⚠️ NO THRESHOLD
222.17 ns
variants::intervals::alternate_deletion📈 view plot
⚠️ NO THRESHOLD
28.25 ns
variants::intervals::alternate_delins📈 view plot
⚠️ NO THRESHOLD
23.10 ns
variants::intervals::alternate_insertion📈 view plot
⚠️ NO THRESHOLD
39.89 ns
variants::intervals::reference_deletion📈 view plot
⚠️ NO THRESHOLD
23.75 ns
variants::intervals::reference_insertion📈 view plot
⚠️ NO THRESHOLD
10.71 ns
variants::normalize::collapse_to_insertion📈 view plot
⚠️ NO THRESHOLD
78.62 ns
variants::normalize::trim_to_snv📈 view plot
⚠️ NO THRESHOLD
83.26 ns
variants::parse::deletion_base_qualified📈 view plot
⚠️ NO THRESHOLD
391.47 ns
variants::parse::delins_base_qualified📈 view plot
⚠️ NO THRESHOLD
430.74 ns
variants::parse::insertion_interbase_qualified📈 view plot
⚠️ NO THRESHOLD
366.83 ns
variants::parse::mnv_base_qualified📈 view plot
⚠️ NO THRESHOLD
470.30 ns
variants::parse::reject_mismatched_qualifier📈 view plot
⚠️ NO THRESHOLD
300.49 ns
variants::parse::reject_missing_qualifier📈 view plot
⚠️ NO THRESHOLD
161.40 ns
variants::parse::snv_base_qualified📈 view plot
⚠️ NO THRESHOLD
402.86 ns
🐰 View full continuous benchmarking report in Bencher

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant