SetEvent and WaitForSiongleObject
C / C++ / MFC
22
Posts
4
Posters
3
Views
1
Watching
-
Sleeps arent performance optimal though, and this test app is designed to hammer some hardware hard for a day or so, so I need it to run as quick as it can. Anyway, I put the second write into the same thread as the read and its running OK now of course.
-
I see, my suggestion was to put a minimal delay of 1ms to use the side effetct of suspending thread execution. Anyway the solution to avoid handle concurrency is the fastest per sure.
Yeah, triggering a small sleep might be enough to get the thread off the CPU for long enough.