kernel32: Add threadpool stack information exports.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Nikolay Sivov 2020-02-12 12:05:28 +03:00 committed by Alexandre Julliard
parent b2f5b03429
commit ad5257b3b6
6 changed files with 26 additions and 8 deletions

View File

@ -22,12 +22,12 @@
@ stdcall FreeLibraryWhenCallbackReturns(ptr ptr) kernel32.FreeLibraryWhenCallbackReturns @ stdcall FreeLibraryWhenCallbackReturns(ptr ptr) kernel32.FreeLibraryWhenCallbackReturns
@ stdcall IsThreadpoolTimerSet(ptr) kernel32.IsThreadpoolTimerSet @ stdcall IsThreadpoolTimerSet(ptr) kernel32.IsThreadpoolTimerSet
@ stdcall LeaveCriticalSectionWhenCallbackReturns(ptr ptr) kernel32.LeaveCriticalSectionWhenCallbackReturns @ stdcall LeaveCriticalSectionWhenCallbackReturns(ptr ptr) kernel32.LeaveCriticalSectionWhenCallbackReturns
@ stub QueryThreadpoolStackInformation @ stdcall QueryThreadpoolStackInformation(ptr ptr) kernel32.QueryThreadpoolStackInformation
@ stdcall RegisterWaitForSingleObjectEx(long ptr ptr long long) kernel32.RegisterWaitForSingleObjectEx @ stdcall RegisterWaitForSingleObjectEx(long ptr ptr long long) kernel32.RegisterWaitForSingleObjectEx
@ stdcall ReleaseMutexWhenCallbackReturns(ptr long) kernel32.ReleaseMutexWhenCallbackReturns @ stdcall ReleaseMutexWhenCallbackReturns(ptr long) kernel32.ReleaseMutexWhenCallbackReturns
@ stdcall ReleaseSemaphoreWhenCallbackReturns(ptr long long) kernel32.ReleaseSemaphoreWhenCallbackReturns @ stdcall ReleaseSemaphoreWhenCallbackReturns(ptr long long) kernel32.ReleaseSemaphoreWhenCallbackReturns
@ stdcall SetEventWhenCallbackReturns(ptr long) kernel32.SetEventWhenCallbackReturns @ stdcall SetEventWhenCallbackReturns(ptr long) kernel32.SetEventWhenCallbackReturns
@ stub SetThreadpoolStackInformation @ stdcall SetThreadpoolStackInformation(ptr ptr) kernel32.SetThreadpoolStackInformation
@ stdcall SetThreadpoolThreadMaximum(ptr long) kernel32.SetThreadpoolThreadMaximum @ stdcall SetThreadpoolThreadMaximum(ptr long) kernel32.SetThreadpoolThreadMaximum
@ stdcall SetThreadpoolThreadMinimum(ptr long) kernel32.SetThreadpoolThreadMinimum @ stdcall SetThreadpoolThreadMinimum(ptr long) kernel32.SetThreadpoolThreadMinimum
@ stdcall SetThreadpoolTimer(ptr ptr long long) kernel32.SetThreadpoolTimer @ stdcall SetThreadpoolTimer(ptr ptr long long) kernel32.SetThreadpoolTimer

View File

@ -17,11 +17,11 @@
@ stdcall FreeLibraryWhenCallbackReturns(ptr ptr) kernel32.FreeLibraryWhenCallbackReturns @ stdcall FreeLibraryWhenCallbackReturns(ptr ptr) kernel32.FreeLibraryWhenCallbackReturns
@ stdcall IsThreadpoolTimerSet(ptr) kernel32.IsThreadpoolTimerSet @ stdcall IsThreadpoolTimerSet(ptr) kernel32.IsThreadpoolTimerSet
@ stdcall LeaveCriticalSectionWhenCallbackReturns(ptr ptr) kernel32.LeaveCriticalSectionWhenCallbackReturns @ stdcall LeaveCriticalSectionWhenCallbackReturns(ptr ptr) kernel32.LeaveCriticalSectionWhenCallbackReturns
@ stub QueryThreadpoolStackInformation @ stdcall QueryThreadpoolStackInformation(ptr ptr) kernel32.QueryThreadpoolStackInformation
@ stdcall ReleaseMutexWhenCallbackReturns(ptr long) kernel32.ReleaseMutexWhenCallbackReturns @ stdcall ReleaseMutexWhenCallbackReturns(ptr long) kernel32.ReleaseMutexWhenCallbackReturns
@ stdcall ReleaseSemaphoreWhenCallbackReturns(ptr long long) kernel32.ReleaseSemaphoreWhenCallbackReturns @ stdcall ReleaseSemaphoreWhenCallbackReturns(ptr long long) kernel32.ReleaseSemaphoreWhenCallbackReturns
@ stdcall SetEventWhenCallbackReturns(ptr long) kernel32.SetEventWhenCallbackReturns @ stdcall SetEventWhenCallbackReturns(ptr long) kernel32.SetEventWhenCallbackReturns
@ stub SetThreadpoolStackInformation @ stdcall SetThreadpoolStackInformation(ptr ptr) kernel32.SetThreadpoolStackInformation
@ stdcall SetThreadpoolThreadMaximum(ptr long) kernel32.SetThreadpoolThreadMaximum @ stdcall SetThreadpoolThreadMaximum(ptr long) kernel32.SetThreadpoolThreadMaximum
@ stdcall SetThreadpoolThreadMinimum(ptr long) kernel32.SetThreadpoolThreadMinimum @ stdcall SetThreadpoolThreadMinimum(ptr long) kernel32.SetThreadpoolThreadMinimum
@ stdcall SetThreadpoolTimer(ptr ptr long long) kernel32.SetThreadpoolTimer @ stdcall SetThreadpoolTimer(ptr ptr long long) kernel32.SetThreadpoolTimer

View File

@ -1177,7 +1177,7 @@
@ stdcall QueryProcessCycleTime(long ptr) @ stdcall QueryProcessCycleTime(long ptr)
@ stdcall QueryThreadCycleTime(long ptr) @ stdcall QueryThreadCycleTime(long ptr)
# @ stub QueryThreadProfiling # @ stub QueryThreadProfiling
# @ stub QueryThreadpoolStackInformation @ stdcall -import QueryThreadpoolStackInformation(ptr ptr)
@ stdcall -arch=x86_64 QueryUmsThreadInformation(ptr long ptr long ptr) @ stdcall -arch=x86_64 QueryUmsThreadInformation(ptr long ptr long ptr)
@ stdcall -import QueryUnbiasedInterruptTime(ptr) @ stdcall -import QueryUnbiasedInterruptTime(ptr)
@ stub QueryWin31IniFilesMappedToRegistry @ stub QueryWin31IniFilesMappedToRegistry
@ -1462,7 +1462,7 @@
@ stdcall -import SetThreadStackGuarantee(ptr) @ stdcall -import SetThreadStackGuarantee(ptr)
# @ stub SetThreadToken # @ stub SetThreadToken
@ stdcall -import SetThreadUILanguage(long) @ stdcall -import SetThreadUILanguage(long)
# @ stub SetThreadpoolStackInformation @ stdcall -import SetThreadpoolStackInformation(ptr ptr)
@ stdcall SetThreadpoolThreadMaximum(ptr long) ntdll.TpSetPoolMaxThreads @ stdcall SetThreadpoolThreadMaximum(ptr long) ntdll.TpSetPoolMaxThreads
@ stdcall SetThreadpoolThreadMinimum(ptr long) ntdll.TpSetPoolMinThreads @ stdcall SetThreadpoolThreadMinimum(ptr long) ntdll.TpSetPoolMinThreads
@ stdcall SetThreadpoolTimer(ptr ptr long long) ntdll.TpSetTimer @ stdcall SetThreadpoolTimer(ptr ptr long long) ntdll.TpSetTimer

View File

@ -1213,7 +1213,7 @@
# @ stub QueryStateContainerCreatedNew # @ stub QueryStateContainerCreatedNew
# @ stub QueryStateContainerItemInfo # @ stub QueryStateContainerItemInfo
@ stdcall QueryThreadCycleTime(long ptr) kernel32.QueryThreadCycleTime @ stdcall QueryThreadCycleTime(long ptr) kernel32.QueryThreadCycleTime
@ stub QueryThreadpoolStackInformation @ stdcall QueryThreadpoolStackInformation(ptr ptr)
@ stdcall QueryUnbiasedInterruptTime(ptr) ntdll.RtlQueryUnbiasedInterruptTime @ stdcall QueryUnbiasedInterruptTime(ptr) ntdll.RtlQueryUnbiasedInterruptTime
# @ stub QueryUnbiasedInterruptTimePrecise # @ stub QueryUnbiasedInterruptTimePrecise
# @ stub QueryVirtualMemoryInformation # @ stub QueryVirtualMemoryInformation
@ -1492,7 +1492,7 @@
@ stdcall SetThreadStackGuarantee(ptr) @ stdcall SetThreadStackGuarantee(ptr)
@ stdcall SetThreadToken(ptr ptr) @ stdcall SetThreadToken(ptr ptr)
@ stdcall SetThreadUILanguage(long) @ stdcall SetThreadUILanguage(long)
@ stub SetThreadpoolStackInformation @ stdcall SetThreadpoolStackInformation(ptr ptr)
@ stdcall SetThreadpoolThreadMaximum(ptr long) ntdll.TpSetPoolMaxThreads @ stdcall SetThreadpoolThreadMaximum(ptr long) ntdll.TpSetPoolMaxThreads
@ stdcall SetThreadpoolThreadMinimum(ptr long) ntdll.TpSetPoolMinThreads @ stdcall SetThreadpoolThreadMinimum(ptr long) ntdll.TpSetPoolMinThreads
@ stdcall SetThreadpoolTimer(ptr ptr long long) ntdll.TpSetTimer @ stdcall SetThreadpoolTimer(ptr ptr long long) ntdll.TpSetTimer

View File

@ -1254,3 +1254,19 @@ BOOL WINAPI DECLSPEC_HOTPATCH QueueUserWorkItem( LPTHREAD_START_ROUTINE func, PV
{ {
return set_ntstatus( RtlQueueWorkItem( func, context, flags )); return set_ntstatus( RtlQueueWorkItem( func, context, flags ));
} }
/***********************************************************************
* SetThreadpoolStackInformation (kernelbase.@)
*/
BOOL WINAPI DECLSPEC_HOTPATCH SetThreadpoolStackInformation( PTP_POOL pool, PTP_POOL_STACK_INFORMATION stack_info )
{
return set_ntstatus( TpSetPoolStackInformation( pool, stack_info ));
}
/***********************************************************************
* QueryThreadpoolStackInformation (kernelbase.@)
*/
BOOL WINAPI DECLSPEC_HOTPATCH QueryThreadpoolStackInformation( PTP_POOL pool, PTP_POOL_STACK_INFORMATION stack_info )
{
return set_ntstatus( TpQueryPoolStackInformation( pool, stack_info ));
}

View File

@ -43,9 +43,11 @@ WINBASEAPI void WINAPI DisassociateCurrentThreadFromCallback(PTP_CALLBACK
WINBASEAPI void WINAPI FreeLibraryWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HMODULE); WINBASEAPI void WINAPI FreeLibraryWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HMODULE);
WINBASEAPI BOOL WINAPI IsThreadpoolTimerSet(PTP_TIMER); WINBASEAPI BOOL WINAPI IsThreadpoolTimerSet(PTP_TIMER);
WINBASEAPI void WINAPI LeaveCriticalSectionWhenCallbackReturns(PTP_CALLBACK_INSTANCE,RTL_CRITICAL_SECTION*); WINBASEAPI void WINAPI LeaveCriticalSectionWhenCallbackReturns(PTP_CALLBACK_INSTANCE,RTL_CRITICAL_SECTION*);
WINBASEAPI BOOL WINAPI QueryThreadpoolStackInformation(PTP_POOL,PTP_POOL_STACK_INFORMATION);
WINBASEAPI void WINAPI ReleaseMutexWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HANDLE); WINBASEAPI void WINAPI ReleaseMutexWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HANDLE);
WINBASEAPI void WINAPI ReleaseSemaphoreWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HANDLE,DWORD); WINBASEAPI void WINAPI ReleaseSemaphoreWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HANDLE,DWORD);
WINBASEAPI void WINAPI SetEventWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HANDLE); WINBASEAPI void WINAPI SetEventWhenCallbackReturns(PTP_CALLBACK_INSTANCE,HANDLE);
WINBASEAPI BOOL WINAPI SetThreadpoolStackInformation(PTP_POOL,PTP_POOL_STACK_INFORMATION);
WINBASEAPI void WINAPI SetThreadpoolThreadMaximum(PTP_POOL,DWORD); WINBASEAPI void WINAPI SetThreadpoolThreadMaximum(PTP_POOL,DWORD);
WINBASEAPI BOOL WINAPI SetThreadpoolThreadMinimum(PTP_POOL,DWORD); WINBASEAPI BOOL WINAPI SetThreadpoolThreadMinimum(PTP_POOL,DWORD);
WINBASEAPI void WINAPI SetThreadpoolTimer(PTP_TIMER,FILETIME*,DWORD,DWORD); WINBASEAPI void WINAPI SetThreadpoolTimer(PTP_TIMER,FILETIME*,DWORD,DWORD);