diff --git a/dumux/parallel/multithreading.hh b/dumux/parallel/multithreading.hh index 1efc82f8beda386001fb33f8cf1662255d335083..b8bf23402e5cc4fa7ea589ae40bbebcdbb8f6a93 100644 --- a/dumux/parallel/multithreading.hh +++ b/dumux/parallel/multithreading.hh @@ -46,4 +46,18 @@ using ExecutionBackend = ExecutionBackends::DUMUX_MULTITHREADING_BACKEND; } // end namespace Dumux::Detail::Multithreading +namespace Dumux::Multithreading { + +/*! + * \ingroup Parallel + * \brief Checking whether the backend is serial + */ +inline constexpr bool isSerial() +{ + using namespace Dumux::Detail::Multithreading; + return std::is_same_v<ExecutionBackends::Serial, ExecutionBackend>; +}; + +} // end namespace Dumux + #endif