]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Remove references to DEAL_II_WITH_THREADS. 12180/head
authorDavid Wells <drwells@email.unc.edu>
Tue, 11 May 2021 15:13:02 +0000 (11:13 -0400)
committerDavid Wells <drwells@email.unc.edu>
Tue, 11 May 2021 15:13:02 +0000 (11:13 -0400)
doc/doxygen/options.dox.in
doc/external-libs/cuda.html
doc/readme.html
doc/users/cmake_dealii.html
doc/users/config.sample
include/deal.II/base/config.h.in
include/deal.II/base/thread_management.h
include/deal.II/lac/sparse_vanka.templates.h

index 56a50b7c6a1cc1ad1d6413e3cf947e0affe60340..02e614bdd8388fdd2cddcd5222713a3aa6cf6b56 100644 (file)
@@ -229,7 +229,6 @@ PREDEFINED             = DOXYGEN=1 \
                          DEAL_II_WITH_SYMENGINE=1 \
                          DEAL_II_SYMENGINE_WITH_LLVM=1 \
                          DEAL_II_WITH_TBB=1 \
-                         DEAL_II_WITH_THREADS=1 \
                          DEAL_II_WITH_TRILINOS=1 \
                          DEAL_II_TRILINOS_WITH_EPETRAEXT=1 \
                          DEAL_II_TRILINOS_WITH_MUELU=1 \
index bd9acea7c2191fdda05e48982e3b43bd2454042c..a2de7fd637e0a61c9cd7f23d065598260600ff45 100644 (file)
@@ -70,7 +70,7 @@
       Using CUDA in combination with architecture-specific C++ compiler flags
       like <code>-march=native</code> is known to be fragile and there might be
       compatibility issues with other libraries, e.g. using CUDA 10.1 with
-      <code>-DDEAL_II_WITH_THREADS=ON</code> and
+      <code>-DDEAL_II_WITH_TBB=ON</code> and
       <code>-DDEAL_II_CXX_FLAGS=-march=native</code> results in compile time
       errors like:
       <pre>
index 1bb38cc2329403383f8ea43aab1df4bec35b5020..ab92e11d5b1d159812c7490f385140498a0e57a3 100644 (file)
         <li>
             <p>
                 <i>Threading</i>: By default, deal.II supports parallelism between multiple cores on the same machine using threads and a task-based model built on the
-                <a href="http://threadingbuildingblocks.org/" target="_top">Threading Building Blocks</a>. You can switch threading off by passing the <code>-DDEAL_II_WITH_THREADS=OFF</code> argument to <code>cmake</code>.
+                <a href="http://threadingbuildingblocks.org/" target="_top">Threading Building Blocks</a>. You can switch threading inside the library off by passing the <code>-DDEAL_II_WITH_TBB=OFF</code> argument to <code>cmake</code>.
             </p>
         </li>
 
index f4e3b095c0aa4251e5b15abfb7a7d32e4523150e..880b379cabc69bc4c732247e48b3cf6f1ca22664 100644 (file)
@@ -473,19 +473,15 @@ DEAL_II_WITH_SCALAPACK
 DEAL_II_WITH_SLEPC
 DEAL_II_WITH_SUNDIALS
 DEAL_II_WITH_SYMENGINE
-DEAL_II_WITH_THREADS
+DEAL_II_WITH_TBB
 DEAL_II_WITH_TRILINOS
 DEAL_II_WITH_UMFPACK
 DEAL_II_WITH_ZLIB
 </pre>
-      They all have standard meaning with the exception of
-      two:
+      They all have standard meanings with the exception of one:
       <ul>
         <li> <code>DEAL_II_WITH_BOOST</code> is always <code>ON</code>
-          since BOOST is a mandatory build time dependency.
-
-        <li> <code>DEAL_II_WITH_THREADS</code> enables threading support
-          with the help of the Threading Building Blocks (TBB) library.
+          since BOOST is a mandatory build time dependency.</li>
       </ul>
     </p>
 
index c7f66fb9340a4c87db1daef6230b9b8202644b5c..0662ff78c75105efb71ddd73bf1c8e787377abbb 100644 (file)
 
 
 #
-# Threading support:
+# TBB support:
 #
-# SET(DEAL_II_WITH_THREADS ON CACHE BOOL
-#   "Build deal.II with support for threads"
+# SET(DEAL_II_WITH_TBB ON CACHE BOOL
+#   "Build deal.II with support for threads via TBB"
 #   )
 #
-# SET(DEAL_II_FORCE_BUNDLED_THREADS TRUE CACHE BOOL
+# SET(DEAL_II_FORCE_BUNDLED_TBB TRUE CACHE BOOL
 #   "Always use the bundled tbb library instead of an external one."
 #   )
 #
index 4d7179fe66aa3e22316eed1fbc1ec244f59f1e66..3d4445f07d1fa4abaad64cbe0be472fe96d63a62 100644 (file)
 #cmakedefine DEAL_II_WITH_ZLIB
 
 #ifdef DEAL_II_WITH_TBB
-/*
- * Backward compatibility setting:
- * FIXME: Update once transition to taskflow is complete
+/**
+ * For backwards compatibility, continue defining DEAL_II_WITH_THREADS when the
+ * library is configured with TBB.
  */
 #define DEAL_II_WITH_THREADS
+
 #define TBB_SUPPRESS_DEPRECATED_MESSAGES 1
 #endif
 
index f6a73197aebbc2d5d5c26cfa7e50cbc69b481fdc..0f7fcb1ca350c1946841f06a90a66def944a11d8 100644 (file)
@@ -1318,14 +1318,8 @@ namespace Threads
    *
    * @note Threads::new_task() is, in essence, equivalent to calling
    *   `std::async(std::launch::async, ...)` in that it runs the given task
-   *   in the background. (See https://en.cppreference.com/w/cpp/thread/async
-   *   for more information.) The only difference is if you configured deal.II
-   *   with `DEAL_II_WITH_THREADS=OFF`, then the operation described by the
-   *   arguments of this function are executed immediately and the returned
-   *   value is placed in the Task object returned here. This is useful for
-   *   cases where one wants to run a program in a way where deal.II does not
-   *   internally create parallel tasks, for example because one is already
-   *   using one MPI process per core in a parallel computation.
+   *   in the background. See https://en.cppreference.com/w/cpp/thread/async
+   *   for more information.
    *
    * @ingroup threads
    */
@@ -1408,14 +1402,8 @@ namespace Threads
    *
    * @note Threads::new_task() is, in essence, equivalent to calling
    *   `std::async(std::launch::async, ...)` in that it runs the given task
-   *   in the background. (See https://en.cppreference.com/w/cpp/thread/async
-   *   for more information.) The only difference is if you configured deal.II
-   *   with `DEAL_II_WITH_THREADS=OFF`, then the operation described by the
-   *   arguments of this function are executed immediately and the returned
-   *   value is placed in the Task object returned here. This is useful for
-   *   cases where one wants to run a program in a way where deal.II does not
-   *   internally create parallel tasks, for example because one is already
-   *   using one MPI process per core in a parallel computation.
+   *   in the background. See https://en.cppreference.com/w/cpp/thread/async
+   *   for more information.
    *
    * @ingroup CPP11
    */
index 06c0f5d571dabf4cb624fb1d60b1dc3ba6036a38..54b36f6126da019252242871e78d6fca7a5a6083 100644 (file)
@@ -106,9 +106,6 @@ SparseVanka<number>::compute_inverses()
   Assert(matrix != nullptr, ExcNotInitialized());
   Assert(selected != nullptr, ExcNotInitialized());
 
-#ifndef DEAL_II_WITH_THREADS
-  compute_inverses(0, matrix->m());
-#else
   const size_type n_inverses =
     std::count(selected->begin(), selected->end(), true);
   // somewhat arbitrarily set up an equal number of tasks as we have threads
@@ -161,7 +158,6 @@ SparseVanka<number>::compute_inverses()
       this->compute_inverses(blocking[i].first, blocking[i].second);
     });
   tasks.join_all();
-#endif
 }
 
 

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.