Conversation
Documents which code runs under Miri and why, the measured runtime that drove the exclusion list, and the known parallel+simd coverage gap. Also records four factual corrections to issue #81: structural.rs has no unsafe block, data_ptr/data_ptr_mut live in matrix.rs and contain no unsafe, excluding the simd feature would audit zero production unsafe, and --workspace contradicts the stated wasm exclusion. .agents/* is gitignored, so the plan is un-ignored by exception in the same style as instructions.md and workflows/. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Two matrix legs against `-p purecv --lib`: a required baseline on `std`, and an advisory leg on `std,simd` that reaches the unsafe slice reinterpretations in arithm.rs and derivatives.rs. Kept in its own workflow file because GitHub badges are per-workflow, not per-job, and to keep nightly flakiness out of the main CI badge. MIRIFLAGS uses -Zmiri-deterministic-floats, not the -Zmiri-strict-provenance the issue proposed: strict provenance is now Miri's default and that flag is deprecated, while Miri's float error injection breaks the Box-Muller determinism test in rng.rs. --lib skips doc-tests, where two ORB examples cost 767s under interpretation while duplicating unit-test coverage. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Nine tests exceed 30s under Miri interpretation and together account for 94% of the suite's runtime; the remaining 293 tests finish in 139s. The annotations take a full run from 41 minutes to roughly 4. Excluded for runtime only — none of the nine contains or reaches unsafe, and nothing in the suite proved Miri-incompatible. Each carries a reason comment so the exclusion list stays derivable by grep. test_build_pyramid_with_derivatives was the one borderline case: it exercises the Sobel unsafe fast path, but that coverage is retained by imgproc::tests::test_sobel, which hits the same f32/ksize-3 trigger in 0.8s under Miri. The attributes vanish under normal cargo test — all tests still run there. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The Portable SIMD bullet claimed "Zero unsafe, zero #[cfg(target_arch)]". The second half is true; the first is not — arithm.rs and derivatives.rs use from_raw_parts to feed pulp. Reworded to state that those reinterpretations are Miri-checked in CI, turning a claim Miri would contradict into one it actively backs. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The simd leg was introduced advisory in case Miri's target-dependent intrinsic support differed between the local Windows host and CI. It ran green on ubuntu-latest with counts identical to local — 355 passed, 0 failed, 9 ignored on both — so the hedge has served its purpose. Leaving it advisory would mean the only leg that reaches production unsafe could not actually block a bad merge. Plan document updated to match: leg 2 is now documented as required, and the header records the verification result and links to the follow-up issue for the parallel+simd coverage gap. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Section 8 was written before the spike and its commands no longer worked. Copy-pasting them hit three walls in sequence: --report-time is rejected without -Zunstable-options, the missing MIRIFLAGS made test_randn_determinism fail on a last-ULP float difference, and the missing --lib pulled in ~13 minutes of ORB doc-tests. Replaced with the exact commands CI runs, plus a table of what each omitted flag does so a failure is recognisable as configuration rather than a real regression. Also reframes the section as a record of what shipped rather than a pending checklist, and corrects commit 3's title to the one actually used. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Both Miri legs are required checks on PRs and dev pushes, but release.yml only waited on Build and Test, WASM Dual Build, and Benchmarks — so a UB regression could still reach crates.io. Adds wait-on-check steps for both legs, and the tag trigger to miri.yml that makes them possible: ci.yml already ran on `v*` tags but miri.yml did not, so waiting on a Miri check would have hung the release indefinitely. Job names are matched exactly against miri.yml's matrix output. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Bumps package and workspace versions in Cargo.toml, the root package.json, and the generated crates/wasm/pkg/package.json, and prepends the git-cliff changelog entry. The wasm pkg manifest was still at 0.6.1 — it was not refreshed during the v0.7.0 release, even though 0.7.0 was published to npm from a locally built pkg. Running `npm run build` resyncs it, so this also clears that drift. No library code changed since v0.7.0 — the release carries the Miri UB verification work: CI workflow, plan document, README badge and safety-claim correction, and cfg_attr(miri, ignore) annotations on nine slow tests. The published crate differs from v0.7.0 only in its README. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Release v0.7.1. Merge, then tag
v0.7.1onmainto triggerrelease.yml(GitHub release + crates.io publish).What's in it
Entirely the Miri UB verification work from #81 / #93, plus the release plumbing.
No library code changed since v0.7.0. The only
src/diff is 28 lines of#[cfg_attr(miri, ignore)]and comments in test modules — the published crate differs from 0.7.0 only in its README.Result
Miri finds no undefined behaviour in any
unsafeblock it reaches. Both legs pass onubuntu-latestand locally, under strict provenance and Stacked Borrows:std)std,simd)All six production
unsafeblocks reachable withoutparallelare verified. Theparallel+simdchunked path remains uncovered — tracked in #94.Release plumbing in this PR
release.ymlgated on Build and Test, WASM Dual Build, and Benchmarks, but not Miri — so a UB regression was still publishable to crates.io. Both legs are now wait-on-check steps, andmiri.ymlgained atags: ["v*"]trigger without which those waits would hang the release forever. Job names were cross-checked against the matrix output.Version bumps
Cargo.toml(package + workspace), rootpackage.json, andcrates/wasm/pkg/package.json.Note the wasm pkg manifest was still at 0.6.1 — it was never refreshed during the v0.7.0 release, even though 0.7.0 shipped to npm from a locally built pkg.
npm run buildresyncs it, so this clears a release behind of drift.Changelog
Generated with
git-cliff --tag v0.7.1 --unreleased --prepend. One manual fix:--prependomitted the blank line before the previous## [0.7.0]heading, which is inconsistent with the rest of the file.Refs #81, #93