Ok, this is odd.

I was just testing my Timer class and for some reason both win32 Sleep and C++ std::this_thread::sleep_for are unable to sleep for less than around 15ms.

Even just a bare for loop doing Sleep(1) 100 times results in a delay or around 1.5s.

I even made a new project with just this (the pic) and it took 15s to run.

Has win 10 changed sleep precision?

I'll reboot and see what happens.

@kojack You need to call timeBeginPeriod(1) before using Sleep(), otherwise all bets are off.

@Pierre I've known about timeBeginPeriod for reading time (although I always used queryperformancecounter instead, so didn't need it), but I didn't know it affected sleep too.

I guess I was always lucky and had something else in the system do it, since it's always worked fine in the past. :)

@Pierre Well, I always knew sleep was unreliable (could be longer than desired), but not 1/64s minimum. :)