mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-05-27 17:17:06 +02:00
MSVC I LOVE YOU THANS
This commit is contained in:
parent
46f799c9c8
commit
1d5853f7c4
1 changed files with 1 additions and 1 deletions
|
|
@ -185,7 +185,7 @@ bool Event::WaitFor(const std::chrono::nanoseconds time) {
|
||||||
// RDTSC may be fenced here due to atomic load
|
// RDTSC may be fenced here due to atomic load
|
||||||
auto const now = _rdtsc();
|
auto const now = _rdtsc();
|
||||||
if (end > now) {
|
if (end > now) {
|
||||||
u32 const cycles = std::min<u32>(std::numeric_limits<u32>::max(), s64(end) - s64(now));
|
u32 const cycles = std::min<u32>((std::numeric_limits<u32>::max)(), s64(end) - s64(now));
|
||||||
// See here: https://github.com/torvalds/linux/blob/948a64995aca6820abefd17f1a4258f5835c5ad9/arch/x86/lib/delay.c#L93
|
// See here: https://github.com/torvalds/linux/blob/948a64995aca6820abefd17f1a4258f5835c5ad9/arch/x86/lib/delay.c#L93
|
||||||
// MWAITX accepts a 32-bit input timer which determines the total number of cycles to wait for
|
// MWAITX accepts a 32-bit input timer which determines the total number of cycles to wait for
|
||||||
// NOT THE TOTAL ABSOLUTE TSC VALUE, it's just a delta
|
// NOT THE TOTAL ABSOLUTE TSC VALUE, it's just a delta
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue