Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
a311140f
Commit
a311140f
authored
Sep 09, 2019
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Move QueryPerformanceCounter/Frequency functions to ntdll.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
ddf82f7c
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
26 additions
and
51 deletions
+26
-51
cpu.c
dlls/kernel32/cpu.c
+0
-45
kernel32.spec
dlls/kernel32/kernel32.spec
+2
-2
kernelbase.spec
dlls/kernelbase/kernelbase.spec
+2
-2
registry.c
dlls/kernelbase/registry.c
+1
-2
ntdll.spec
dlls/ntdll/ntdll.spec
+2
-0
time.c
dlls/ntdll/time.c
+17
-0
winternl.h
include/winternl.h
+2
-0
No files found.
dlls/kernel32/cpu.c
View file @
a311140f
...
...
@@ -46,51 +46,6 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
reg
);
/****************************************************************************
* QueryPerformanceCounter (KERNEL32.@)
*
* Get the current value of the performance counter.
*
* PARAMS
* counter [O] Destination for the current counter reading
*
* RETURNS
* Success: TRUE. counter contains the current reading
* Failure: FALSE.
*
* SEE ALSO
* See QueryPerformanceFrequency.
*/
BOOL
WINAPI
QueryPerformanceCounter
(
PLARGE_INTEGER
counter
)
{
NtQueryPerformanceCounter
(
counter
,
NULL
);
return
TRUE
;
}
/****************************************************************************
* QueryPerformanceFrequency (KERNEL32.@)
*
* Get the resolution of the performance counter.
*
* PARAMS
* frequency [O] Destination for the counter resolution
*
* RETURNS
* Success. TRUE. Frequency contains the resolution of the counter.
* Failure: FALSE.
*
* SEE ALSO
* See QueryPerformanceCounter.
*/
BOOL
WINAPI
QueryPerformanceFrequency
(
PLARGE_INTEGER
frequency
)
{
LARGE_INTEGER
counter
;
NtQueryPerformanceCounter
(
&
counter
,
frequency
);
return
TRUE
;
}
/***********************************************************************
* GetSystemInfo [KERNEL32.@]
*
...
...
dlls/kernel32/kernel32.spec
View file @
a311140f
...
...
@@ -1169,8 +1169,8 @@
@ stdcall -import QueryMemoryResourceNotification(ptr ptr)
@ stub QueryNumberOfEventLogRecords
@ stub QueryOldestEventLogRecord
@ stdcall QueryPerformanceCounter(ptr)
@ stdcall QueryPerformanceFrequency(ptr)
@ stdcall
-import
QueryPerformanceCounter(ptr)
@ stdcall
-import
QueryPerformanceFrequency(ptr)
# @ stub QueryProcessAffinityUpdateMode
@ stdcall QueryProcessCycleTime(long ptr)
@ stdcall QueryThreadCycleTime(long ptr)
...
...
dlls/kernelbase/kernelbase.spec
View file @
a311140f
...
...
@@ -1204,8 +1204,8 @@
# @ stub QueryInterruptTimePrecise
@ stdcall QueryMemoryResourceNotification(ptr ptr)
# @ stub QueryOptionalDelayLoadedAPI
@ stdcall QueryPerformanceCounter(ptr)
kernel32.
QueryPerformanceCounter
@ stdcall QueryPerformanceFrequency(ptr)
kernel32.
QueryPerformanceFrequency
@ stdcall QueryPerformanceCounter(ptr)
ntdll.Rtl
QueryPerformanceCounter
@ stdcall QueryPerformanceFrequency(ptr)
ntdll.Rtl
QueryPerformanceFrequency
@ stub QueryProcessAffinityUpdateMode
@ stdcall QueryProcessCycleTime(long ptr) kernel32.QueryProcessCycleTime
# @ stub QueryProtectedPolicy
...
...
dlls/kernelbase/registry.c
View file @
a311140f
...
...
@@ -1368,8 +1368,7 @@ static DWORD query_perf_data(const WCHAR *query, DWORD *type, void *data, DWORD
pdb
->
HeaderLength
=
sizeof
(
*
pdb
);
pdb
->
NumObjectTypes
=
0
;
pdb
->
DefaultObject
=
0
;
QueryPerformanceCounter
(
&
pdb
->
PerfTime
);
QueryPerformanceFrequency
(
&
pdb
->
PerfFreq
);
NtQueryPerformanceCounter
(
&
pdb
->
PerfTime
,
&
pdb
->
PerfFreq
);
data
=
pdb
+
1
;
pdb
->
SystemNameOffset
=
sizeof
(
*
pdb
);
...
...
dlls/ntdll/ntdll.spec
View file @
a311140f
...
...
@@ -850,6 +850,8 @@
@ stub RtlQueryInformationActiveActivationContext
@ stub RtlQueryInterfaceMemoryStream
@ stdcall RtlQueryPackageIdentity(long ptr ptr ptr ptr ptr)
@ stdcall RtlQueryPerformanceCounter(ptr)
@ stdcall RtlQueryPerformanceFrequency(ptr)
@ stub RtlQueryProcessBackTraceInformation
@ stdcall RtlQueryProcessDebugInformation(long long ptr)
@ stub RtlQueryProcessHeapInformation
...
...
dlls/ntdll/time.c
View file @
a311140f
...
...
@@ -552,6 +552,23 @@ NTSTATUS WINAPI NtQueryPerformanceCounter( LARGE_INTEGER *counter, LARGE_INTEGER
return
STATUS_SUCCESS
;
}
/******************************************************************************
* RtlQueryPerformanceCounter [NTDLL.@]
*/
BOOL
WINAPI
DECLSPEC_HOTPATCH
RtlQueryPerformanceCounter
(
LARGE_INTEGER
*
counter
)
{
counter
->
QuadPart
=
monotonic_counter
();
return
TRUE
;
}
/******************************************************************************
* RtlQueryPerformanceFrequency [NTDLL.@]
*/
BOOL
WINAPI
DECLSPEC_HOTPATCH
RtlQueryPerformanceFrequency
(
LARGE_INTEGER
*
frequency
)
{
frequency
->
QuadPart
=
TICKSPERSEC
;
return
TRUE
;
}
/******************************************************************************
* NtGetTickCount (NTDLL.@)
...
...
include/winternl.h
View file @
a311140f
...
...
@@ -2799,6 +2799,8 @@ NTSYSAPI NTSTATUS WINAPI RtlQueryEnvironmentVariable_U(PWSTR,PUNICODE_STRING,PU
NTSYSAPI
NTSTATUS
WINAPI
RtlQueryHeapInformation
(
HANDLE
,
HEAP_INFORMATION_CLASS
,
PVOID
,
SIZE_T
,
PSIZE_T
);
NTSYSAPI
NTSTATUS
WINAPI
RtlQueryInformationAcl
(
PACL
,
LPVOID
,
DWORD
,
ACL_INFORMATION_CLASS
);
NTSYSAPI
NTSTATUS
WINAPI
RtlQueryInformationActivationContext
(
ULONG
,
HANDLE
,
PVOID
,
ULONG
,
PVOID
,
SIZE_T
,
SIZE_T
*
);
NTSYSAPI
BOOL
WINAPI
RtlQueryPerformanceCounter
(
LARGE_INTEGER
*
);
NTSYSAPI
BOOL
WINAPI
RtlQueryPerformanceFrequency
(
LARGE_INTEGER
*
);
NTSYSAPI
NTSTATUS
WINAPI
RtlQueryProcessDebugInformation
(
ULONG
,
ULONG
,
PDEBUG_BUFFER
);
NTSYSAPI
NTSTATUS
WINAPI
RtlQueryRegistryValues
(
ULONG
,
PCWSTR
,
PRTL_QUERY_REGISTRY_TABLE
,
PVOID
,
PVOID
);
NTSYSAPI
NTSTATUS
WINAPI
RtlQueryTimeZoneInformation
(
RTL_TIME_ZONE_INFORMATION
*
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment