Sha256: 7f2eed430304c19b86d108d9cdea61b415246b5c622f1739c67ebf7aa400fd91

Contents?: true

Size: 298 Bytes

Versions: 42

Compression:

Stored size: 298 Bytes

Contents

use crate::cvt::cvt;
use std::io;
use windows_sys::Win32::System::Performance::QueryPerformanceFrequency;

pub fn perf_counter_frequency() -> io::Result<u64> {
    unsafe {
        let mut frequency = 0;
        cvt(QueryPerformanceFrequency(&mut frequency))?;
        Ok(frequency as u64)
    }
}

Version data entries

42 entries across 38 versions & 1 rubygems

Version Path
wasmtime-29.0.0 ./ext/cargo-vendor/winx-0.36.4/src/time.rs
wasmtime-28.0.0 ./ext/cargo-vendor/winx-0.36.4/src/time.rs
wasmtime-27.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-26.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-25.0.2 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-25.0.1 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-25.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-24.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-23.0.2 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-22.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-21.0.1 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-20.0.2 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-20.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-18.0.3 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-17.0.1 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-17.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-16.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-15.0.1 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-15.0.0 ./ext/cargo-vendor/winx-0.36.3/src/time.rs
wasmtime-14.0.4 ./ext/cargo-vendor/winx-0.36.2/src/time.rs