Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions kani-dependencies
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
CBMC_MAJOR="6"
CBMC_MINOR="6"
CBMC_VERSION="6.6.0"
CBMC_MINOR="7"
CBMC_VERSION="6.7.1"

KISSAT_VERSION="4.0.1"
6 changes: 1 addition & 5 deletions tests/expected/loop-contract/struct_projection.expected
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
struct_projection.loop_invariant_step.1\
- Status: SUCCESS\
- Description: "Check invariant after step for loop struct_projection.0"

struct_projection.loop_invariant_step.2\
struct_projection.loop_invariant_step.\
- Status: SUCCESS\
- Description: "Check invariant after step for loop struct_projection.0"

Expand Down
19 changes: 12 additions & 7 deletions tests/expected/shadow/unsupported_num_objects/test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,22 @@ static mut SM: kani::shadow::ShadowMem<bool> = kani::shadow::ShadowMem::new(fals
fn check_max_objects<const N: usize>() {
let mut i = 0;
// A dummy loop that creates `N`` objects.
// After the loop, CBMC's object ID counter should be at `N` + 2:
// After the loop, CBMC's object ID counter should be at `N` + 3:
// - `N` created in the loop +
// - the NULL pointer whose object ID is 0, and
// - the object ID for `i`
// - objects for i, have_42
let mut have_42 = false;
while i < N {
let x: Box<usize> = Box::new(i);
let x: Box<usize> = Box::new(kani::any());
if *x == 42 {
have_42 = true;
}
i += 1;
}

// create a new object whose ID is `N` + 2
let x = 42;
// create a new object whose ID is `N` + 4
let x: i32 = have_42 as i32;
assert_eq!(x, have_42 as i32);
// the following call to `set` would fail if the object ID for `x` exceeds
// the maximum allowed by Kani's shadow memory model
unsafe {
Expand All @@ -30,10 +35,10 @@ fn check_max_objects<const N: usize>() {

#[kani::proof]
fn check_max_objects_pass() {
check_max_objects::<510>();
check_max_objects::<1019>();
}

#[kani::proof]
fn check_max_objects_fail() {
check_max_objects::<511>();
check_max_objects::<1020>();
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
// SPDX-License-Identifier: Apache-2.0 OR MIT
// kani-flags: -Z quantifiers

//! FIXME: <https://github.com/model-checking/kani/issues/4020>

use std::mem;

#[kani::proof]
Expand Down
24 changes: 13 additions & 11 deletions tests/kani/ThreadLocalRef/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,14 +29,16 @@ fn test_i32() {
});
}

#[kani::proof]
#[kani::unwind(7)]
fn test_complex_data() {
COMPLEX_DATA.with(|c| {
assert_eq!(*c.borrow(), "before");
*c.borrow_mut() = "after"
});
COMPLEX_DATA.with(|c| {
assert_eq!(*c.borrow(), "after");
});
}
// TODO: This test exposes a bug in CBMC 6.7.1. It should be re-enabled once a version of CBMC that
// includes https://github.com/diffblue/cbmc/pull/8678 has been released.
// #[kani::proof]
// #[kani::unwind(7)]
// fn test_complex_data() {
// COMPLEX_DATA.with(|c| {
// assert_eq!(*c.borrow(), "before");
// *c.borrow_mut() = "after"
// });
// COMPLEX_DATA.with(|c| {
// assert_eq!(*c.borrow(), "after");
// });
// }
2 changes: 1 addition & 1 deletion tests/perf/hashset/expected
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3 successfully verified harnesses, 0 failures, 3 total
2 successfully verified harnesses, 0 failures, 2 total
18 changes: 10 additions & 8 deletions tests/perf/hashset/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,16 @@ fn check_contains() {
assert!(set.contains(&first));
}

#[kani::proof]
#[kani::stub(RandomState::new, concrete_state)]
#[kani::unwind(5)]
#[kani::solver(kissat)]
fn check_contains_str() {
let set = HashSet::from(["s"]);
assert!(set.contains(&"s"));
}
// TODO: This test exposes a bug in CBMC 6.7.1. It should be re-enabled once a version of CBMC that
// includes https://github.com/diffblue/cbmc/pull/8678 has been released.
// #[kani::proof]
// #[kani::stub(RandomState::new, concrete_state)]
// #[kani::unwind(5)]
// #[kani::solver(kissat)]
// fn check_contains_str() {
// let set = HashSet::from(["s"]);
// assert!(set.contains(&"s"));
// }

// too slow so don't run in the regression for now
#[cfg(slow)]
Expand Down
2 changes: 1 addition & 1 deletion tests/perf/s2n-quic
Submodule s2n-quic updated 57 files
+1 −1 common/s2n-codec/Cargo.toml
+5 −4 dc/s2n-quic-dc/Cargo.toml
+0 −8 dc/s2n-quic-dc/src/event/generated/metrics.rs
+3 −5 dc/s2n-quic-dc/src/path/secret/map.rs
+0 −8 dc/s2n-quic-dc/src/path/secret/map/entry.rs
+14 −65 dc/s2n-quic-dc/src/path/secret/map/handshake.rs
+1 −6 dc/s2n-quic-dc/src/path/secret/map/peer.rs
+4 −6 dc/s2n-quic-dc/src/path/secret/map/state.rs
+2 −2 dc/s2n-quic-dc/src/path/secret/map/state/tests.rs
+3 −3 dc/s2n-quic-dc/src/path/secret/map/store.rs
+2 −2 dc/s2n-quic-dc/src/stream/client/rpc.rs
+1 −14 dc/s2n-quic-dc/src/stream/recv/buffer/local.rs
+0 −44 dc/s2n-quic-dc/src/stream/recv/buffer/local/test.rs
+1 −1 dc/s2n-quic-dc/src/stream/send/flow/blocking.rs
+1 −1 dc/s2n-quic-dc/src/stream/send/flow/non_blocking.rs
+2 −2 dc/s2n-quic-dc/src/stream/tests/request_response.rs
+1 −2 dc/s2n-quic-dc/src/task/waker/set.rs
+70 −29 dc/s2n-quic-dc/src/task/waker/worker.rs
+2 −2 quic/s2n-quic-core/Cargo.toml
+4 −2 quic/s2n-quic-core/src/buffer/reassembler/tests.rs
+2 −2 quic/s2n-quic-core/src/crypto/tls/null.rs
+0 −8 quic/s2n-quic-core/src/event/generated/metrics.rs
+4 −2 quic/s2n-quic-core/src/frame/crypto.rs
+6 −3 quic/s2n-quic-core/src/frame/stream.rs
+1 −1 quic/s2n-quic-core/src/packet/number/map.rs
+5 −3 quic/s2n-quic-core/src/packet/number/sliding_window.rs
+1 −1 quic/s2n-quic-core/src/path/mtu.rs
+2 −1 quic/s2n-quic-core/src/path/mtu/tests.rs
+12 −2 quic/s2n-quic-core/src/recovery/pacing/tests.rs
+14 −3 quic/s2n-quic-core/src/recovery/rtt_estimator.rs
+2 −2 quic/s2n-quic-core/src/sync/cursor.rs
+3 −3 quic/s2n-quic-crypto/Cargo.toml
+0 −10 quic/s2n-quic-events/src/output/metrics.rs
+3 −3 quic/s2n-quic-platform/Cargo.toml
+1 −1 quic/s2n-quic-platform/src/io/turmoil/tests.rs
+1 −1 quic/s2n-quic-qns/Cargo.toml
+1 −1 quic/s2n-quic-qns/src/tls.rs
+1 −1 quic/s2n-quic-qns/src/xdp.rs
+4 −4 quic/s2n-quic-rustls/Cargo.toml
+1 −1 quic/s2n-quic-sim/Cargo.toml
+4 −4 quic/s2n-quic-tls-default/Cargo.toml
+4 −4 quic/s2n-quic-tls/Cargo.toml
+3 −3 quic/s2n-quic-transport/Cargo.toml
+2 −1 quic/s2n-quic-transport/src/dc/manager.rs
+1 −1 quic/s2n-quic-transport/src/path/manager/fuzz_target.rs
+1 −1 quic/s2n-quic-transport/src/path/manager/tests.rs
+27 −9 quic/s2n-quic-transport/src/stream/manager/tests.rs
+1 −1 quic/s2n-quic-transport/src/stream/send_stream/tests.rs
+2 −2 quic/s2n-quic-transport/src/stream/testing.rs
+5 −3 quic/s2n-quic-transport/src/sync/data_sender.rs
+9 −9 quic/s2n-quic/Cargo.toml
+1 −1 quic/s2n-quic/src/client/builder.rs
+2 −6 quic/s2n-quic/src/server/builder.rs
+1 −1 quic/s2n-quic/src/stream/bidirectional.rs
+1 −1 quic/s2n-quic/src/tests/deduplicate.rs
+4 −2 quic/s2n-quic/src/tests/issue_1717.rs
+3 −3 tools/xdp/s2n-quic-xdp/Cargo.toml
Loading