Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .claude/PROGRESS.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,4 +152,5 @@ reports, inbound C ports) is tracked in HPCBio/wfa2lib-rs#19.
Null steps no longer end a corrected search while a candidate is pending
(FIXED_BUGS 14c, with `BandedStatic`).
Also HPCBio/wfa2lib-rs#41: empty pattern + text no longer panics in debug
(FIXED_BUGS 15).
(FIXED_BUGS 15). CI now also runs the tests in a debug build (Linux and
macOS), so overflows like it fail CI.
23 changes: 23 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,29 @@ jobs:
- name: Stock C unit tests
run: bash tests/wfa_utest.sh

# Debug build: overflow checks and debug_assert!s are on, catching what
# release builds silently wrap past (HPCBio/wfa2lib-rs#41). A separate job
# so it runs alongside the release tests; both architectures, since the
# x86 and ARM SIMD paths differ.
test-debug:
name: Test debug (${{ matrix.os }})
runs-on: ${{ matrix.os }}
timeout-minutes: 30
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2
- name: Fetch C WFA2-lib
run: |
git clone --quiet https://github.com/smarco/WFA2-lib WFA2-lib
git -C WFA2-lib checkout --quiet "$(cat tests/differential/C_COMMIT)"
- name: Tests (debug)
run: cargo test

# Suites run as parallel jobs; span is the longest (~15 min on Linux).
# Linux runs Rust's x86 AVX2 kernels, macOS (arm64) its NEON ones, so
# together they check that Rust gives the same output on both. macOS
Expand Down
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,13 +82,15 @@ For broader parity checks, `tests/differential/run.sh` builds C's
1300 configurations (metrics, spans, heuristics, memory modes); see
[`tests/differential/README.md`](tests/differential/README.md).

CI (`.github/workflows/ci.yml`) runs clippy, the tests, a library-only build,
CI (`.github/workflows/ci.yml`) runs clippy, the tests (release, and debug
with overflow checks and debug assertions), a library-only build,
`wfa_utest.sh` and the differential harness on Linux (x86-64) and macOS
(arm64) for every pull request and push to `main`. Running the harness on both
checks that Rust's x86 and ARM SIMD paths give the same output. Linux also
runs everything with `RUSTFLAGS="-C target-cpu=x86-64-v3"`, so the AVX2
kernels are tested both when selected at run time and when enabled at compile
time (as in `target-cpu=native` builds).
runs the release tests and the harness with
`RUSTFLAGS="-C target-cpu=x86-64-v3"`, so the AVX2 kernels are tested both
when selected at run time and when enabled at compile time (as in
`target-cpu=native` builds).

## Usage

Expand Down
Loading