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-14.0.3 ./ext/cargo-vendor/winx-0.36.2/src/time.rs
wasmtime-14.0.1 ./ext/cargo-vendor/winx-0.36.2/src/time.rs
wasmtime-14.0.0 ./ext/cargo-vendor/winx-0.36.2/src/time.rs
wasmtime-13.0.0 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-12.0.1 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-12.0.0 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-11.0.0 ./ext/cargo-vendor/winx-0.35.1/src/time.rs
wasmtime-11.0.0 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-10.0.1 ./ext/cargo-vendor/winx-0.35.1/src/time.rs
wasmtime-10.0.1 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-10.0.0 ./ext/cargo-vendor/winx-0.35.1/src/time.rs
wasmtime-10.0.0 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-9.0.4 ./ext/cargo-vendor/winx-0.36.1/src/time.rs
wasmtime-9.0.4 ./ext/cargo-vendor/winx-0.35.1/src/time.rs
wasmtime-9.0.1 ./ext/cargo-vendor/winx-0.35.1/src/time.rs
wasmtime-8.0.0 ./ext/cargo-vendor/winx-0.35.1/src/time.rs
wasmtime-7.0.0 ./ext/cargo-vendor/winx-0.35.0/src/time.rs
wasmtime-6.0.1 ./ext/cargo-vendor/winx-0.35.0/src/time.rs
wasmtime-6.0.0 ./ext/cargo-vendor/winx-0.35.0/src/time.rs
wasmtime-5.0.0 ./ext/cargo-vendor/winx-0.34.0/src/time.rs