]> https://gitweb.dealii.org/ - dealii.git/commitdiff
add a comment
authorMatthias Maier <tamiko@43-1.org>
Wed, 27 May 2020 04:18:17 +0000 (23:18 -0500)
committerMatthias Maier <tamiko@43-1.org>
Wed, 27 May 2020 16:26:14 +0000 (11:26 -0500)
include/deal.II/base/thread_local_storage.h

index 2c96321bb315c067538f0046fcdd9a0ed11c1522..59cdd3d9082b8d847fee45aed813d0cb755c4e79 100644 (file)
@@ -230,6 +230,11 @@ namespace Threads
 
     /**
      * A mutex to guard insertion into the data object.
+     *
+     * We use a std::shared_timed_mutex (or std::shared_mutex if available)
+     * here to be able to use std::unique_lock and std::shared_lock for a
+     * readers-writer lock
+     * (https://en.wikipedia.org/wiki/Readers%E2%80%93writer_lock).
      */
 #  ifdef DEAL_II_HAVE_CXX17
     std::shared_mutex insertion_mutex;

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.