#[non_exhaustive]pub struct Config {
pub max_size: u8,
pub max_terms: usize,
pub samples: usize,
pub conflicts: u64,
pub propagations: u64,
pub restarts: usize,
pub max_vars: usize,
pub comparisons: bool,
pub selects: bool,
}Expand description
How far to search.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.max_size: u8The largest candidate, in nodes (a tree: leaves and operators).
max_terms: usizeThe most distinct behaviors kept (memory: each costs a word per sample).
samples: usizeRandom sample points (besides boundary values).
conflicts: u64The SAT solver’s conflict budget for each proof; a candidate whose proof needs more is
left unproved (Report::unproved).
propagations: u64The SAT solver’s propagation budget for each proof (u64::MAX, the default: no limit),
likewise. A conflict costs more propagation on a larger circuit, so this bounds the time
a proof takes more closely than conflicts does, and as
deterministically.
restarts: usizeHow many counterexamples may restart the search.
max_vars: usizeAt most this many variables.
comparisons: boolWhether candidates may hold comparisons (== != <u <s, each the value 0 or 1 at the
target’s width; a comparison counts one node, its extension none). On by default:
(x | -x) >>u 63 is x != 0, and a sum with a correction where a value is zero has
no smaller writing without one. The enumeration is about a third larger with them.
selects: boolWhether candidates may hold select(c, a, b), c a candidate that is 0 or 1 at
every sample (a comparison, or what has a comparison’s values: 1 >>u x is x == 0),
read as c != 0. On by default: the smaller of two values is select(x <u y, x, y).
Implementations§
Source§impl Config
impl Config
Sourcepub fn with_max_size(self, value: u8) -> Self
pub fn with_max_size(self, value: u8) -> Self
Sets max_size.
Sourcepub fn with_max_terms(self, value: usize) -> Self
pub fn with_max_terms(self, value: usize) -> Self
Sets max_terms.
Sourcepub fn with_samples(self, value: usize) -> Self
pub fn with_samples(self, value: usize) -> Self
Sets samples.
Sourcepub fn with_conflicts(self, value: u64) -> Self
pub fn with_conflicts(self, value: u64) -> Self
Sets conflicts.
Sourcepub fn with_propagations(self, value: u64) -> Self
pub fn with_propagations(self, value: u64) -> Self
Sets propagations.
Sourcepub fn with_restarts(self, value: usize) -> Self
pub fn with_restarts(self, value: usize) -> Self
Sets restarts.
Sourcepub fn with_max_vars(self, value: usize) -> Self
pub fn with_max_vars(self, value: usize) -> Self
Sets max_vars.
Sourcepub fn with_comparisons(self, value: bool) -> Self
pub fn with_comparisons(self, value: bool) -> Self
Sets comparisons.
Sourcepub fn with_selects(self, value: bool) -> Self
pub fn with_selects(self, value: bool) -> Self
Sets selects.