Skip to main content

Module timing

Module timing 

Source
Expand description

WASM-compatible timing abstraction.

Wall-clock timing backed by web_time::Instant, which transparently maps to std::time::Instant on native targets and to performance.now() on wasm32. This keeps time-based termination (time_limit_ms) working on both native and WASM — iteration limits remain the safety net that bounds every algorithm regardless of clock resolution.

A previous WASM build used a no-op timer that always reported zero elapsed time; that silently disabled time_limit_ms on WASM, so strategies ran to their full iteration cap (multi-second freezes in the browser).

Structs§

Timer
A wall-clock timer backed by web_time::Instant.