From 5051524d40b79ee6731987ef2ae564a7f8685d88 Mon Sep 17 00:00:00 2001
From: greg
Date: Sat, 9 Mar 2019 13:09:27 -0500
Subject: [PATCH] wip
---
README.md | 6 +++++-
img/{flat_pat_mutex_4.PNG => flat_par_mutex_4.PNG} | Bin
img/{flat_pat_mutex_5.PNG => flat_par_mutex_5.PNG} | Bin
...mutex_5_speed.PNG => flat_par_mutex_5_speed.PNG} | Bin
...mutex_6_speed.PNG => flat_par_mutex_6_speed.PNG} | Bin
pdf/parallel_hashmap.html | 5 ++++-
6 files changed, 9 insertions(+), 2 deletions(-)
rename img/{flat_pat_mutex_4.PNG => flat_par_mutex_4.PNG} (100%)
rename img/{flat_pat_mutex_5.PNG => flat_par_mutex_5.PNG} (100%)
rename img/{flat_pat_mutex_5_speed.PNG => flat_par_mutex_5_speed.PNG} (100%)
rename img/{flat_pat_mutex_6_speed.PNG => flat_par_mutex_6_speed.PNG} (100%)
diff --git a/README.md b/README.md
index 1e562ba..c7b9b5f 100644
--- a/README.md
+++ b/README.md
@@ -204,10 +204,14 @@ template Still, this is a pretty good result, we are now inserting values into our parallel_hash_map three times faster than we were able to do using the flat_hash_map, while using a lower memory ceiling.
Using the intrinsic parallelism of the parallel_hash_map with internal mutexes
It may not be practical to add logic into your program to ensure you use different internal submaps from each thread. Still, locking the whole parallel_hash_map for each access would forego taking advantage of its intrinsic parallelism.
-For that reason, the parallel_hash_map provides optional internal locking using the absl::Mutex (the default template parameter is absl::NullMutex, which does no locking and doesn't have any extra size cost). When selecting absl::Mutex, one mutex is created for each internal submap at a cost of 8 bytes per submap.
+For that reason, the parallel_hash_map can provide internal locking using the absl::Mutex (the default template parameter is absl::NullMutex, which does no locking and has no size cost). When selecting absl::Mutex, one mutex is created for each internal submap at a cost of 8 bytes per submap.