Win10: Use GetSystemTimePreciseAsFileTime
directly by ChrisDenton · Pull Request #121633 · rust-lang/rust (original) (raw)
Should Miri be limiting the precision of the other one, if that's what the official implementation does?
🤷 Technically it's left unspecified in the Microsoft docs so it could just be the same clock and it's free to change between versions.
In practice it has similar limitations to GetTickCount
as mentioned in Windows Time
GetTickCount and GetTickCount64 are limited to the resolution of the system timer, which is approximately 10 milliseconds to 16 milliseconds
This can also be adjusted with timeBeginPeriod. But as far as I can tell miri doesn't currently emulate system "ticks" (which are used for all sorts of timers and scheduling) and it would perhaps be odd to implement it only for one function.