"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "dlls/ntdll/tests/time.c" between
wine-5.12.tar.xz and wine-5.13.tar.xz

About: Wine is an Open Source implementation of the MS Windows API on top of X, OpenGL, and Unix. Think of Wine as a compatibility layer for running Windows programs. Development release.

time.c  (wine-5.12.tar.xz):time.c  (wine-5.13.tar.xz)
skipping to change at line 202 skipping to change at line 202
low = time->LowPart; low = time->LowPart;
} }
while (high != time->High2Time); while (high != time->High2Time);
return high << 32 | low; return high << 32 | low;
} }
static void test_user_shared_data_time(void) static void test_user_shared_data_time(void)
{ {
KSHARED_USER_DATA *user_shared_data = (void *)0x7ffe0000; KSHARED_USER_DATA *user_shared_data = (void *)0x7ffe0000;
ULONGLONG t1, t2, t3; ULONGLONG t1, t2, t3;
int i = 0; int i = 0, changed = 0;
i = 0; i = 0;
do do
{ {
t1 = GetTickCount(); t1 = GetTickCount();
if (user_shared_data->NtMajorVersion <= 5 && user_shared_data->NtMinorVe rsion <= 1) if (user_shared_data->NtMajorVersion <= 5 && user_shared_data->NtMinorVe rsion <= 1)
t2 = (*(volatile ULONG*)&user_shared_data->TickCountLowDeprecated * (ULONG64)user_shared_data->TickCountMultiplier) >> 24; t2 = (*(volatile ULONG*)&user_shared_data->TickCountLowDeprecated * (ULONG64)user_shared_data->TickCountMultiplier) >> 24;
else else
t2 = (read_ksystem_time(&user_shared_data->u.TickCount) * user_share d_data->TickCountMultiplier) >> 24; t2 = (read_ksystem_time(&user_shared_data->u.TickCount) * user_share d_data->TickCountMultiplier) >> 24;
t3 = GetTickCount(); t3 = GetTickCount();
skipping to change at line 256 skipping to change at line 256
t2 = read_ksystem_time(&user_shared_data->InterruptTime); t2 = read_ksystem_time(&user_shared_data->InterruptTime);
pRtlQueryUnbiasedInterruptTime(&t3); pRtlQueryUnbiasedInterruptTime(&t3);
} while(t3 < t1 && i++ < 1); /* allow for wrap, but only once */ } while(t3 < t1 && i++ < 1); /* allow for wrap, but only once */
ok(t1 <= t2, "USD InterruptTime / RtlQueryUnbiasedInterruptTime are out of order %s %s\n", ok(t1 <= t2, "USD InterruptTime / RtlQueryUnbiasedInterruptTime are out of order %s %s\n",
wine_dbgstr_longlong(t1), wine_dbgstr_longlong(t2)); wine_dbgstr_longlong(t1), wine_dbgstr_longlong(t2));
ok(t2 <= t3 || broken(t2 == t3 + 82410089070) /* w864 has some weird off set on testbot */, ok(t2 <= t3 || broken(t2 == t3 + 82410089070) /* w864 has some weird off set on testbot */,
"USD InterruptTime / RtlQueryUnbiasedInterruptTime are out of order % s %s\n", "USD InterruptTime / RtlQueryUnbiasedInterruptTime are out of order % s %s\n",
wine_dbgstr_longlong(t2), wine_dbgstr_longlong(t3)); wine_dbgstr_longlong(t2), wine_dbgstr_longlong(t3));
} }
for (i = 0; i < 100; i++)
{
t1 = GetTickCount();
Sleep(1);
t2 = GetTickCount();
if (t1 != t2) changed++;
}
todo_wine ok(changed >= 90, "tick count isn't updated after sleeping one mil
lisecond (%d%% correct)\n", changed);
} }
START_TEST(time) START_TEST(time)
{ {
HMODULE mod = GetModuleHandleA("ntdll.dll"); HMODULE mod = GetModuleHandleA("ntdll.dll");
pRtlTimeToTimeFields = (void *)GetProcAddress(mod,"RtlTimeToTimeFields"); pRtlTimeToTimeFields = (void *)GetProcAddress(mod,"RtlTimeToTimeFields");
pRtlTimeFieldsToTime = (void *)GetProcAddress(mod,"RtlTimeFieldsToTime"); pRtlTimeFieldsToTime = (void *)GetProcAddress(mod,"RtlTimeFieldsToTime");
pNtQueryPerformanceCounter = (void *)GetProcAddress(mod, "NtQueryPerformance Counter"); pNtQueryPerformanceCounter = (void *)GetProcAddress(mod, "NtQueryPerformance Counter");
pNtQuerySystemInformation = (void *)GetProcAddress(mod, "NtQuerySystemInform ation"); pNtQuerySystemInformation = (void *)GetProcAddress(mod, "NtQuerySystemInform ation");
pRtlQueryTimeZoneInformation = pRtlQueryTimeZoneInformation =
 End of changes. 2 change blocks. 
1 lines changed or deleted 11 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)