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
fa8e36fa
Commit
fa8e36fa
authored
Sep 23, 2022
by
Brendan Shanks
Committed by
Alexandre Julliard
Sep 26, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ntdll: Set the name of internal thread pool threads.
parent
c3025582
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
threadpool.c
dlls/ntdll/threadpool.c
+13
-0
No files found.
dlls/ntdll/threadpool.c
View file @
fa8e36fa
...
...
@@ -396,6 +396,14 @@ static BOOL array_reserve(void **elements, unsigned int *capacity, unsigned int
return
TRUE
;
}
static
void
set_thread_name
(
const
WCHAR
*
name
)
{
THREAD_NAME_INFORMATION
info
;
RtlInitUnicodeString
(
&
info
.
ThreadName
,
name
);
NtSetInformationThread
(
GetCurrentThread
(),
ThreadNameInformation
,
&
info
,
sizeof
(
info
));
}
static
void
CALLBACK
process_rtl_work_item
(
TP_CALLBACK_INSTANCE
*
instance
,
void
*
userdata
)
{
struct
rtl_work_item
*
item
=
userdata
;
...
...
@@ -703,6 +711,7 @@ static void WINAPI timer_queue_thread_proc(LPVOID p)
struct
timer_queue
*
q
=
p
;
ULONG
timeout_ms
;
set_thread_name
(
L"wine_threadpool_timer_queue"
);
timeout_ms
=
INFINITE
;
for
(;;)
{
...
...
@@ -1052,6 +1061,7 @@ static void CALLBACK timerqueue_thread_proc( void *param )
struct
list
*
ptr
;
TRACE
(
"starting timer queue thread
\n
"
);
set_thread_name
(
L"wine_threadpool_timerqueue"
);
RtlEnterCriticalSection
(
&
timerqueue
.
cs
);
for
(;;)
...
...
@@ -1241,6 +1251,7 @@ static void CALLBACK waitqueue_thread_proc( void *param )
NTSTATUS
status
;
TRACE
(
"starting wait queue thread
\n
"
);
set_thread_name
(
L"wine_threadpool_waitqueue"
);
RtlEnterCriticalSection
(
&
waitqueue
.
cs
);
...
...
@@ -1511,6 +1522,7 @@ static void CALLBACK ioqueue_thread_proc( void *param )
NTSTATUS
status
;
TRACE
(
"starting I/O completion thread
\n
"
);
set_thread_name
(
L"wine_threadpool_ioqueue"
);
RtlEnterCriticalSection
(
&
ioqueue
.
cs
);
...
...
@@ -2323,6 +2335,7 @@ static void CALLBACK threadpool_worker_proc( void *param )
struct
list
*
ptr
;
TRACE
(
"starting worker thread for pool %p
\n
"
,
pool
);
set_thread_name
(
L"wine_threadpool_worker"
);
RtlEnterCriticalSection
(
&
pool
->
cs
);
for
(;;)
...
...
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