libabigail
Loading...
Searching...
No Matches
abigail::workers Namespace Reference

The namespace of the worker threads (or thread pool) implementation of libabigail. This was modelled after the article https://en.wikipedia.org/wiki/Thread_pool. More...

Classes

class  queue
 This represents a queue of tasks to be performed. More...
class  simple_task
 The template of a task to be performed. More...
class  simple_task< Fn, void, Args... >
 This is a specialization of the simple_task class template for which the function to be performed returns a void type. More...
class  task
 This represents a task to be performed. More...
class  vector

Typedefs

template<typename Fn, typename RetType, typename... Args>
using simple_task_sptr
 A type alias for shared_ptr<simple_task<Fn, RetType, Args...>>.
typedef shared_ptr< task > task_sptr

Functions

size_t get_number_of_available_threads ()
size_t get_number_of_threads ()

Detailed Description

The namespace of the worker threads (or thread pool) implementation of libabigail. This was modelled after the article https://en.wikipedia.org/wiki/Thread_pool.

Typedef Documentation

◆ simple_task_sptr

template<typename Fn, typename RetType, typename... Args>
using simple_task_sptr

A type alias for shared_ptr<simple_task<Fn, RetType, Args...>>.

Definition at line 132 of file abg-workers.h.

◆ task_sptr

typedef shared_ptr<task> task_sptr

Definition at line 56 of file abg-workers.h.

Function Documentation

◆ get_number_of_available_threads()

size_t get_number_of_available_threads ( )
Returns
The number of hardware threads of executions advertised by the underlying processor. If libabigail has been configured without multithreading support, this returns 1.
the number of hardware threads of executions advertised by the underlying processor *if* libabigail has been configured with multithreading support.

Definition at line 95 of file abg-workers.cc.

◆ get_number_of_threads()

size_t get_number_of_threads ( )
Returns
The number of hardware threads of executions advertised by the underlying processor.

Definition at line 84 of file abg-workers.cc.