CernVM-FS  2.9.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
util_concurrency.h File Reference
#include <pthread.h>
#include <cassert>
#include <queue>
#include <set>
#include <vector>
#include "atomic.h"
#include "util/async.h"
#include "util/single_copy.h"
#include "util_concurrency_impl.h"
Include dependency graph for util_concurrency.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


class  Lockable
struct  _RAII_Polymorphism
class  RAII< T, P >
class  LockGuard< LockableT >
class  Future< T >
class  SynchronizingCounter< T >
class  Observable< ParamT >
class  Observable< ParamT >
class  Signal
class  FifoChannel< T >
class  ConcurrentWorkers< WorkerT >
struct  ConcurrentWorkers< WorkerT >::Job< DataT >
struct  ConcurrentWorkers< WorkerT >::RunBinding
struct  ConcurrentWorkers< WorkerT >::WorkerRunBinding
class  ConcurrentWorker< DerivedWorkerT >


typedef RAII< pthread_mutex_t > MutexLockGuard
typedef RAII< pthread_rwlock_t,
typedef RAII< pthread_rwlock_t,


unsigned int GetNumberOfCpuCores ()


static const unsigned int kFallbackNumberOfCpus = 1

Typedef Documentation

typedef RAII<pthread_mutex_t> MutexLockGuard

Definition at line 114 of file util_concurrency.h.

typedef RAII<pthread_rwlock_t, _RAII_Polymorphism::ReadLock> ReadLockGuard

Definition at line 137 of file util_concurrency.h.

Definition at line 138 of file util_concurrency.h.

Function Documentation

unsigned int GetNumberOfCpuCores ( )

Returns the number of CPU cores present in the system or a fallback number if it failed to determine the number of CPU cores.

the number of active CPU cores in the system

This file is part of the CernVM File System.

Definition at line 16 of file

Referenced by anonymous_namespace{}::Params::Complete(), swissknife::CommandMigrate::DoMigrationAndCommit(), IngestionPipeline::IngestionPipeline(), and ScrubbingPipeline::ScrubbingPipeline().

Here is the caller graph for this function:

Variable Documentation

const unsigned int kFallbackNumberOfCpus = 1

Definition at line 412 of file util_concurrency.h.

Referenced by GetNumberOfCpuCores().