pub struct CompilerConfig {
pub wcoj_variable_ordering: WcojVarOrderingKind,
pub wcoj_var_ordering_threshold: f64,
}Expand description
Compile-time configuration for the WCOJ variable-ordering cost model.
See module docs for activation semantics + threshold contract.
Fields§
§wcoj_variable_ordering: WcojVarOrderingKindVariable-ordering cost-model selector. Default Disabled.
wcoj_var_ordering_threshold: f64Raw threshold field. Public to keep struct-literal
construction available, but the promoter MUST NOT read this
field directly. Use
CompilerConfig::effective_wcoj_var_ordering_threshold so
out-of-range values are clamped at use, not silently honored.
Implementations§
Source§impl CompilerConfig
impl CompilerConfig
Sourcepub const DEFAULT_THRESHOLD: f64 = 0.5
pub const DEFAULT_THRESHOLD: f64 = 0.5
Default ratio at or below which a leader candidate triggers
var_order = Some(...). The gate fires on
min_card / default_leader_card ≤ threshold. A smaller
threshold demands a clearer win.
Sourcepub fn effective_wcoj_var_ordering_threshold(&self) -> f64
pub fn effective_wcoj_var_ordering_threshold(&self) -> f64
Resolve the threshold the promoter actually uses.
Out-of-range values fall back to Self::DEFAULT_THRESHOLD:
NaN- non-finite (
±INFINITY) ≤ 0.0(would never fire — clamps to default to keep the gate honest)> 1.0(would always fire — clamps to default to prevent silent gate-disable via struct-literal)
Trait Implementations§
Source§impl Clone for CompilerConfig
impl Clone for CompilerConfig
Source§fn clone(&self) -> CompilerConfig
fn clone(&self) -> CompilerConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CompilerConfig
impl Debug for CompilerConfig
Source§impl Default for CompilerConfig
impl Default for CompilerConfig
Source§impl PartialEq for CompilerConfig
impl PartialEq for CompilerConfig
impl StructuralPartialEq for CompilerConfig
Auto Trait Implementations§
impl Freeze for CompilerConfig
impl RefUnwindSafe for CompilerConfig
impl Send for CompilerConfig
impl Sync for CompilerConfig
impl Unpin for CompilerConfig
impl UnsafeUnpin for CompilerConfig
impl UnwindSafe for CompilerConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more