Author: hbelusca Date: Fri May 22 21:21:43 2015 New Revision: 67851
URL: http://svn.reactos.org/svn/reactos?rev=67851&view=rev Log: [NTVDM]: at the end of a cpu slice, yield execution to other threads in the system.
Modified: trunk/reactos/subsystems/mvdm/ntvdm/clock.c
Modified: trunk/reactos/subsystems/mvdm/ntvdm/clock.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/mvdm/ntvdm/clock... ============================================================================== --- trunk/reactos/subsystems/mvdm/ntvdm/clock.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/mvdm/ntvdm/clock.c [iso-8859-1] Fri May 22 21:21:43 2015 @@ -118,13 +118,16 @@ /* Update the time of the last timer tick */ Timer->LastTick.QuadPart += Ticks * Timer->Delay; } + + /* Yield execution to other threads */ + NtYieldExecution(); } }
PHARDWARE_TIMER CreateHardwareTimer(ULONG Flags, ULONGLONG Delay, PHARDWARE_TIMER_PROC Callback) { PHARDWARE_TIMER Timer; - + Timer = RtlAllocateHeap(RtlGetProcessHeap(), 0, sizeof(*Timer)); if (Timer == NULL) return NULL;