From 7aa62499e3cff811bce1b881b9012d4a02aee7fd Mon Sep 17 00:00:00 2001 From: d-netto Date: Fri, 12 Jan 2024 08:41:07 -0300 Subject: [PATCH] Set the number of GC threads to number of compute threads --- src/threading.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/threading.c b/src/threading.c index 5d0c0c614840fb..77b24dcb5208c4 100644 --- a/src/threading.c +++ b/src/threading.c @@ -678,13 +678,12 @@ void jl_init_threading(void) } else { // if `--gcthreads` or ENV[NUM_GCTHREADS_NAME] was not specified, - // set the number of mark threads to half of compute threads - // and number of sweep threads to 0 + // set the number of GC threads to the number of compute threads if (nthreads <= 1) { jl_n_markthreads = 0; } else { - jl_n_markthreads = (nthreads / 2) - 1; + jl_n_markthreads = nthreads - 1; } // if `--gcthreads` or ENV[NUM_GCTHREADS_NAME] was not specified, // cap the number of threads that may run the mark phase to