Skip to content

make bcore-mutation suitable for secp256k1 🥷#43

Merged
brunoerg merged 5 commits into
mainfrom
2026-06-secp256k1
Jun 8, 2026
Merged

make bcore-mutation suitable for secp256k1 🥷#43
brunoerg merged 5 commits into
mainfrom
2026-06-secp256k1

Conversation

@brunoerg

@brunoerg brunoerg commented Jun 3, 2026

Copy link
Copy Markdown
Owner

No description provided.

brunoerg and others added 5 commits June 3, 2026 10:54
Add an optional --min-score flag to the analyze command: when the final
mutation score (killed / total, aggregated across all analyzed folders)
falls below it, analyze returns an error and exits non-zero, failing CI.
When unset, the score is not enforced. Backed by a dedicated
ScoreBelowThreshold error variant; the value is validated to be in [0,1].

Also hoist the one-time clean build out of analyze_folder into
run_analysis so it runs once per invocation instead of once per mutant
folder. Per-mutant incremental rebuilds still happen inside each test
command. Guarded so it is skipped when --command is given or there are
no folders to analyze.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Move the hardcoded non-source file skip list out of run_mutation and
into Project::should_skip_file, backed by per-project substring and
suffix tables. Bitcoin Core behavior is unchanged; secp256k1 now skips
its own docs, tooling, examples, benchmarks and test/bench impl files.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Field normalization functions (secp256k1_fe_normalize and its _weak,
_var, _to_zero, _to_zero_var variants) only canonicalize the internal
limb representation without changing the represented value. Deleting a
call to them almost always yields an equivalent, non-useful mutant, so
add the secp256k1_fe_normalize substring to the skip list.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@brunoerg brunoerg merged commit 33857be into main Jun 8, 2026
1 check passed
@brunoerg brunoerg deleted the 2026-06-secp256k1 branch June 8, 2026 18:31
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