pub struct TimeLimit {
pub seconds: u32,
pub is_cpu_time: bool,
}Expand description
Time limit specification: a number of seconds and whether to measure
CPU time (-cpulimit) or wall-clock time (-timelimit).
Both are armed process-wide, not per-solve: minion uses alarm() or
setrlimit(RLIMIT_CPU) together with a process-static trigger pointer
(system/trigger_timer.cpp), so concurrent solves in one process
overwrite each other’s timers. is_cpu_time additionally sets a hard
RLIMIT_CPU of seconds + 5 on the calling process, which will kill it
outright — one solve per process is the only safe use.
Fields§
§seconds: u32§is_cpu_time: boolTrait Implementations§
impl Copy for TimeLimit
impl Eq for TimeLimit
impl StructuralPartialEq for TimeLimit
Auto Trait Implementations§
impl Freeze for TimeLimit
impl RefUnwindSafe for TimeLimit
impl Send for TimeLimit
impl Sync for TimeLimit
impl Unpin for TimeLimit
impl UnsafeUnpin for TimeLimit
impl UnwindSafe for TimeLimit
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 8 bytes