diff options
Diffstat (limited to 'src/tape.zig')
| -rw-r--r-- | src/tape.zig | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/tape.zig b/src/tape.zig index 2875b156..9337ff9f 100644 --- a/src/tape.zig +++ b/src/tape.zig @@ -286,6 +286,9 @@ pub const Tape = struct { /// A digest only when asked (`recordDigest`): the replica stream's, /// one a unit, not one after each of its inputs. unit_digests: bool = false, + /// A digest record replayed is compared with the core's own; a replica + /// client's compares one now and then (src/replica.zig `check_every`). + checks: bool = true, /// A replica client's guess of the session's clocks for a speculation /// (src/replica.zig): its clock reads (a message's stamp, a file's /// mtime) answer this instead of the clocks here. @@ -570,6 +573,7 @@ pub const Tape = struct { /// A digest record's payload (a unit's last) against the core's own: a /// difference is `diverged`, its fields named when the record has them. pub fn check(t: *Tape, payload: []const u8) void { + if (!t.checks) return; var r: walk.Reader = .{ .bytes = payload }; const want = walk.decode([]const u64, &r, t.arena.allocator()) catch return; const p = t.core orelse return; |
