aboutsummaryrefslogtreecommitdiffhomepage
path: root/unsupported/test/cxx11_non_blocking_thread_pool.cpp
Commit message (Collapse)AuthorAge
* Clean up the Tensor header and get rid of the EIGEN_SLEEP macro.Gravatar Rasmus Munk Larsen2020-12-02
|
* Collapsed revisionGravatar Ravi Kiran2018-09-17
| | | | * Merged eigen/eigen into default
* Account for missing change on commit "Remove SimpleThreadPool and..."Gravatar Gustavo Lima Chaves2018-07-23
| | | | | | "... always use {NonBlocking}ThreadPool". It seems the non-blocking implementation was me the default/only one, but a reference to the old name was left unmodified. Fix that.
* Get rid of EIGEN_TEST_FUNC, unit tests must now be declared with ↵Gravatar Gael Guennebaud2018-07-17
| | | | | | | | | EIGEN_DECLARE_TEST(mytest) { /* code */ }. This provide several advantages: - more flexibility in designing unit tests - unit tests can be glued to speed up compilation - unit tests are compiled with same predefined macros, which is a requirement for zapcc
* Make the non-blocking threadpool more flexible and less wasteful of CPU ↵Gravatar Rasmus Munk Larsen2017-03-09
| | | | | | | | | | | | cycles for high-latency use-cases. * Adds a hint to ThreadPool allowing us to turn off spin waiting. Currently each reader and record yielder op in a graph creates a threadpool with a thread that spins for 1000 iterations through the work stealing loop before yielding. This is wasteful for such ops that process I/O. * This also changes the number of iterations through the steal loop to be inversely proportional to the number of threads. Since the time of each iteration is proportional to the number of threads, this yields roughly a constant spin time. * Implement a separate worker loop for the num_threads == 1 case since there is no point in going through the expensive steal loop. Moreover, since Steal() calls PopBack() on the victim queues it might reverse the order in which ops are executed, compared to the order in which they are scheduled, which is usually counter-productive for the types of I/O workloads the single thread pools tend to be used for. * Store num_threads in a member variable for simplicity and to avoid a data race between the thread creation loop and worker threads calling threads_.size().
* Introduce a portable EIGEN_SLEEP macro.Gravatar Benoit Steiner2016-12-09
|
* Reworked the threadpool cancellation mechanism to not depend on ↵Gravatar Benoit Steiner2016-12-09
| | | | pthread_cancel since it turns out that pthread_cancel doesn't work properly on numerous platforms.
* Added a message to ease the detection of platforms on which thread ↵Gravatar Benoit Steiner2016-12-08
| | | | cancellation isn't supported.
* Added support for thread cancellation on LinuxGravatar Benoit Steiner2016-12-08
|
* Return -1 from CurrentThreadId when called by thread outside the pool.Gravatar Rasmus Munk Larsen2016-06-23
|
* size_t -> intGravatar Rasmus Munk Larsen2016-06-03
|
* Add CurrentThreadId and NumThreads methods to Eigen threadpools and ↵Gravatar Rasmus Munk Larsen2016-06-03
| | | | TensorDeviceThreadPool.
* Fixed potential race condition in the non blocking thread poolGravatar Benoit Steiner2016-05-12
|
* Added a test to validate the new non blocking thread poolGravatar Benoit Steiner2016-05-10