Skip to content

Commit 8f3304a

Browse files
carstenbauerKristofferC
authored andcommitted
Fix documentation: thread pool of main thread (#53388)
See #53217 (comment) (cherry picked from commit 8425b0e)
1 parent 5ae8707 commit 8f3304a

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

doc/src/manual/multi-threading.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,8 @@ julia> using Base.Threads
116116
julia> nthreadpools()
117117
2
118118
119-
julia> threadpool()
120-
:default
119+
julia> threadpool() # the main thread is in the interactive thread pool
120+
:interactive
121121
122122
julia> nthreads(:default)
123123
3
@@ -133,6 +133,10 @@ julia> nthreads()
133133
The zero-argument version of `nthreads` returns the number of threads
134134
in the default pool.
135135

136+
!!! note
137+
Depending on whether Julia has been started with interactive threads,
138+
the main thread is either in the default or interactive thread pool.
139+
136140
Either or both numbers can be replaced with the word `auto`, which causes
137141
Julia to choose a reasonable default.
138142

0 commit comments

Comments
 (0)