summaryrefslogtreecommitdiff
path: root/src/glibext/gwidthtracker.c
diff options
context:
space:
mode:
authorCyrille Bagard <nocbos@gmail.com>2018-06-04 17:58:34 (GMT)
committerCyrille Bagard <nocbos@gmail.com>2018-06-04 17:58:48 (GMT)
commit1f2b71e31326a5bc021785888cd2203010acf4e6 (patch)
treeb82fd64f1137a09553aa2cb513f974e1308e3022 /src/glibext/gwidthtracker.c
parenta7f73441a0d466824798a421f369628db0184030 (diff)
Defined the number of threads to run from a centralized function.
Diffstat (limited to 'src/glibext/gwidthtracker.c')
-rw-r--r--src/glibext/gwidthtracker.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/glibext/gwidthtracker.c b/src/glibext/gwidthtracker.c
index 181759c..0741133 100644
--- a/src/glibext/gwidthtracker.c
+++ b/src/glibext/gwidthtracker.c
@@ -36,6 +36,7 @@
#include "delayed-int.h"
#include "gbuffercache.h"
#include "../core/global.h"
+#include "../core/nproc.h"
@@ -986,7 +987,7 @@ void g_width_tracker_build_initial_cache(GWidthTracker *tracker, wgroup_id_t gid
/* Lancement des traitements */
- runs_count = g_get_num_processors();
+ runs_count = get_max_online_threads();
updates = (GWidthUpdate **)calloc(runs_count, sizeof(GWidthUpdate *));