From cee00343d0c537a31281b4de74fadd7589d434b0 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 22 Oct 2019 13:03:21 +0200 Subject: Rename global_mutex_shards to global_mutexes --- libbuild2/context.hxx | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'libbuild2/context.hxx') diff --git a/libbuild2/context.hxx b/libbuild2/context.hxx index cc34803..60f5ba8 100644 --- a/libbuild2/context.hxx +++ b/libbuild2/context.hxx @@ -99,14 +99,19 @@ namespace build2 mutex lm_; }; - class global_mutex_shards + // Context-wide mutexes and mutex shards. + // + class global_mutexes { public: + + // Variable cache mutex shard (see variable.hxx for details). + // size_t variable_cache_size; unique_ptr variable_cache; explicit - global_mutex_shards (size_t vc) + global_mutexes (size_t vc) : variable_cache_size (vc), variable_cache (new shared_mutex[variable_cache_size]) {} }; @@ -134,7 +139,7 @@ namespace build2 public: scheduler& sched; - global_mutex_shards& mutex_shards; + global_mutexes& mutexes; // Dry run flag (see --dry-run|-n). // @@ -425,7 +430,7 @@ namespace build2 // explicit context (scheduler&, - global_mutex_shards&, + global_mutexes&, bool dry_run = false, bool keep_going = true, const strings& cmd_vars = {}, -- cgit v1.1