BornAgain  1.19.79
Open-source research software to simulate and fit neutron and x-ray reflectometry and grazing-incidence small-angle scattering
ThreadInfo.h
Go to the documentation of this file.
1 // ************************************************************************************************
2 //
3 // BornAgain: simulate and fit reflection and scattering
4 //
5 //! @file Base/Util/ThreadInfo.h
6 //! @brief Defines struct ThreadInfo.
7 //!
8 //! @homepage http://www.bornagainproject.org
9 //! @license GNU General Public License v3 or higher (see COPYING)
10 //! @copyright Forschungszentrum Jülich GmbH 2018
11 //! @authors Scientific Computing Group at MLZ (see CITATION, AUTHORS)
12 //
13 // ************************************************************************************************
14 
15 #ifndef BORNAGAIN_BASE_UTIL_THREADINFO_H
16 #define BORNAGAIN_BASE_UTIL_THREADINFO_H
17 
18 //! Information to run simulation with dedicated number of threads.
19 //! @ingroup simulation
20 
21 struct ThreadInfo {
23  unsigned n_threads{0};
24  unsigned n_batches{1};
25  unsigned current_batch{0};
26 };
27 
28 inline ThreadInfo::ThreadInfo() = default;
29 
30 #endif // BORNAGAIN_BASE_UTIL_THREADINFO_H
Information to run simulation with dedicated number of threads.
Definition: ThreadInfo.h:21
unsigned current_batch
Definition: ThreadInfo.h:25
unsigned n_batches
Definition: ThreadInfo.h:24
unsigned n_threads
Definition: ThreadInfo.h:23