[Bug 59864] New: 0024:fixme:ntdll:NtQuerySystemInformation (0x000000c5,0x7ffffe30fe60,0x00000008,0x7ffffe30fe58) stub
http://bugs.winehq.org/show_bug.cgi?id=59864 Bug ID: 59864 Summary: 0024:fixme:ntdll:NtQuerySystemInformation (0x000000c5,0x7ffffe30fe60,0x00000008,0x7ffffe30fe58) stub Product: Wine Version: 11.10 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: ntdll Assignee: wine-bugs@list.winehq.org Reporter: timothylottes@protonmail.com Distribution: --- 0024:fixme:ntdll:NtQuerySystemInformation (0x000000c5,0x7ffffe30fe60,0x00000008,0x7ffffe30fe58) stub ERROR[__103800]:C0000003 The best mechanism to do low cost TSC conversion to wall-clock time (like seconds,microseconds,or nanoseconds) without the aid of a system call is to grab the Windows computed TSC scalar value. The method is well described in this code (and program) here: https://gist.github.com/pmttavara/6f06fc5c7679c07375483b06bb77430c This method involves using NtQuerySystemInformation() specifically the SystemHypervisorSharedPageInformation (aka 0xc5) Documented here: https://ntdoc.m417z.com/system_hypervisor_user_shared_data Specifically this element of the structure /** * Multiplier used to convert hypervisor QPC ticks to host time. * * This value is applied to the hypervisor's virtualized performance * counter to compute a stable, high-resolution timebase. The multiplier * is chosen by the hypervisor based on the underlying hardware timer * source and virtualization mode. */ ULONGLONG QpcMultiplier; Suggestion: implement this interface in Wine The 'pmttavara' link above provides the Linux variation Simply use perf_event_mmap_page to get the data -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=59864 Zeb Figura <z.figura12@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |z.figura12@gmail.com --- Comment #1 from Zeb Figura <z.figura12@gmail.com> --- What application needs this? -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=59864 --- Comment #2 from Timothy Paul Lottes <timothylottes@protonmail.com> --- I'm a developer not a consumer, so wouldn't know the extent of consumer apps that have this issue. I found this while attempting to migrate from Windows to Wine on Linux for all my Windows development. And this is one of the more serious issues that showed up right away. Given this method is popularized by a thread on the "hand made hero" youtube series forum post here: https://hero.handmade.network/forums/code-discussion/t/7485-queryperformance... It should perhaps actually have some priority attached to it. The method is the best way to manage timing on Windows on modern processors. The result is knowing the right TSC scalar so you can do RDTSC to get the CPU TSC clock, and then multiply it by a constant to convert to wallclock time (say in microseconds or nanoseconds). -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
http://bugs.winehq.org/show_bug.cgi?id=59864 Zeb Figura <z.figura12@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|0024:fixme:ntdll:NtQuerySys |Custom application needs |temInformation |NtQuerySystemInformation(Sy |(0x000000c5,0x7ffffe30fe60, |stemHypervisorSharedPageInf |0x00000008,0x7ffffe30fe58) |ormation) |stub | -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
WineHQ Bugzilla