model-checking / kani

Kani Rust Verifier
https://model-checking.github.io/kani
Apache License 2.0
2.06k stars 85 forks source link

Build cache should consider changes to the compiler #2229

Open celinval opened 1 year ago

celinval commented 1 year ago

Proposed change: For internal development, we should include information about the current compiler version (e.g.: the commit hash or a hash of the kani-compiler binary. We should also include the toolchain version that's being used.

Motivation: This will alleviate the development pain of remembering to do a cargo clean whenever making changes to the compiler. Not doing so can manifest in weird / inconsistent results that end up taking time to debug.

celinval commented 1 year ago

Some context: https://github.com/rust-lang/cargo/pull/8073

celinval commented 1 year ago

For Kani developers, if you make any change to kani-compiler or the rust toolchain, you might need to clean the build cache. For the regression, remove the build/ folder in the repo root, for one off test, delete the target directly. Another option is to pass the --force-rebuild flag to cargo kani