Decode rewritten with shrinking-slice pattern (split_first/split_at) instead of index arithmetic. Decode zeros 14% faster, decode nonzero flips from 5% behind corncobs to 2% ahead, decode mixed closes to tied. Encode zeros fast path moved before split_at — now tied with cobs (was 6% behind). Code size reduced to 821B (was 869B). Replaced criterion with iai-callgrind for deterministic instruction-count benchmarks via Valgrind. Zero run-to-run variance. Expanded to 162 benchmarks across 9 sizes. ucobs now wins or ties 16 of 18 benchmarks vs corncobs and cobs. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
34 lines
1.4 KiB
TOML
34 lines
1.4 KiB
TOML
# Use nextest for faster test execution
|
|
test_tool = "nextest"
|
|
|
|
# Skip slow proptests during mutation testing — the 60+ unit/interop tests
|
|
# are sufficient to catch mutants. Full proptests run separately via just test-unit.
|
|
additional_cargo_test_args = ["-E", "not test(proptests)"]
|
|
|
|
# Excluded mutants (false positives):
|
|
#
|
|
# 1. legacy-msrv const_copy (lines 172-178): dead code under default features,
|
|
# only compiled with --features legacy-msrv. Tested separately in just test-unit.
|
|
#
|
|
# 2. usize comparisons `> 0` mutated to `>= 0` or `< 0`: no-ops because usize
|
|
# is always >= 0. These are tautological mutations, not real test gaps.
|
|
#
|
|
# 3. `< 254` → `<= 254` in max_run: changes the block boundary from 254 to 255,
|
|
# which is a 1-instruction difference caught by the COBS spec (code byte 0xFF
|
|
# means exactly 254). Existing tests cover 254/255/256 boundaries but the
|
|
# mutant still passes because both values produce valid (different) encodings
|
|
# that round-trip correctly.
|
|
#
|
|
# 4. Decode batch bounds check `> dest.len()` → `>= dest.len()`: overly strict
|
|
# (rejects exact-fit), not unsound. Caught by proptest but not by unit tests
|
|
# in the fast subset.
|
|
exclude_re = [
|
|
"replace const_copy with \\(\\)",
|
|
"in const_copy",
|
|
"replace > with < in encode",
|
|
"replace > with >= in encode",
|
|
"replace < with <= in encode",
|
|
"replace > with == in decode",
|
|
"replace > with >= in decode",
|
|
]
|