Saturate and gate all llvm-cov coverage metrics
Require 100% region, function, instantiation, line, branch, and MC/DC coverage in run-coverage.sh. Enable MC/DC instrumentation and rewrite the two decisions that Clang could not instrument cleanly: the crossed-room ternary, and the nested boolean under negation in crossedCompleteEndLeOne.
This commit is contained in:
1 parent
f23d8a28d3
commit
bf149c26b5
4 files changed
+46
-27
No files matched your search
+8
-7
@@ -25,7 +25,7 @@ The Lean build is untouched.
|
||||
| `tests/fuzz_raw.cpp` | libFuzzer safety test on arbitrary instances under ASan/UBSan. |
|
||||
| `tests/bench.cpp` | nanobench literal-vs-fast benchmark. |
|
||||
| `run-fuzz.sh` | Rebuilds and runs both fuzzers for a fixed time. |
|
||||
| `run-coverage.sh` | Builds with Clang source-based coverage and requires 100% line and branch coverage of `src/fast.cpp`. |
|
||||
| `run-coverage.sh` | Builds with Clang source-based coverage and requires 100% region, function, instantiation, line, branch, and MC/DC coverage of `src/fast.cpp`. |
|
||||
| `third_party/nanobench.h` | Vendored nanobench (commit `7252da9d96bd0d71f508e9b2813ab1f57fdfaec1`). |
|
||||
|
||||
## Data model
|
||||
@@ -126,12 +126,13 @@ written, it is not a proof of equivalence with `literal.cpp`.
|
||||
./cpp/run-coverage.sh
|
||||
```
|
||||
|
||||
The script configures a Clang source-based-coverage build, runs
|
||||
`sweep_test`, and fails unless `src/fast.cpp` has 100% line and branch
|
||||
coverage. `sweep_test` alone covers every region, function, line, and
|
||||
branch side of the summarised implementation. The region, line, and branch
|
||||
totals are not recorded here: they change with the implementation, and the
|
||||
coverage run reports the current ones.
|
||||
The script configures a Clang source-based-coverage build with MC/DC
|
||||
instrumentation, runs `sweep_test`, and fails unless `src/fast.cpp` has 100%
|
||||
region, function, instantiation, line, branch, and MC/DC coverage. `sweep_test`
|
||||
alone covers every region, function, instantiation, line, branch side, and
|
||||
MC/DC condition of the summarised implementation. MC/DC instrumentation requires
|
||||
Clang 18 or newer. The totals are not recorded here: they change with the
|
||||
implementation, and the coverage run reports the current ones.
|
||||
|
||||
Because equivalence is only promised on readable inputs, `src/fast.cpp` deletes
|
||||
both unreachable control-flow branches and predicate operands that an enclosing
|
||||
|
||||
Reference in new issue
Block a user