Cloudy
Spectral Synthesis Code for Astrophysics
Loading...
Searching...
No Matches
ran_pool< T > Class Template Reference

#include <ran.h>

Collaboration diagram for ran_pool< T >:

Public Member Functions

void init (size_t s, t_ran *rc, t_ran_fun f)
 
void reset ()
 
bool lgInitialized () const
 
next ()
 
 ran_pool ()
 
 ran_pool (const ran_pool &)=delete
 
ran_pooloperator= (const ran_pool &)=delete
 
 ~ran_pool ()
 

Private Member Functions

void p_alloc ()
 
void p_update_pool ()
 

Private Attributes

void * p_pool
 
T * p_next
 
T * p_end
 
size_t p_size
 
size_t p_squad
 
t_ranp_rc
 
t_ran_fun p_fill
 

Constructor & Destructor Documentation

◆ ran_pool() [1/2]

template<class T>
ran_pool< T >::ran_pool ( )
inline

References NULL, p_end, p_fill, p_next, p_pool, p_rc, p_size, and p_squad.

Referenced by operator=(), and ran_pool().

◆ ran_pool() [2/2]

template<class T>
ran_pool< T >::ran_pool ( const ran_pool< T > & )
delete

References ran_pool().

Here is the call graph for this function:

◆ ~ran_pool()

template<class T>
ran_pool< T >::~ran_pool ( )
inline

References p_pool, and posix_memalign_free().

Here is the call graph for this function:

Member Function Documentation

◆ init()

template<class T>
void ran_pool< T >::init ( size_t s,
t_ran * rc,
t_ran_fun f )
inline

References ASSERT, lgInitialized(), p_fill, p_rc, p_size, and p_squad.

Here is the call graph for this function:

◆ lgInitialized()

template<class T>
bool ran_pool< T >::lgInitialized ( ) const
inline

References p_size.

Referenced by init(), and p_update_pool().

◆ next()

template<class T>
T ran_pool< T >::next ( )
inline

References p_end, p_next, p_update_pool(), and UNLIKELY.

Here is the call graph for this function:

◆ operator=()

template<class T>
ran_pool & ran_pool< T >::operator= ( const ran_pool< T > & )
delete

References ran_pool().

Here is the call graph for this function:

◆ p_alloc()

template<class T>
void ran_pool< T >::p_alloc ( )
inlineprivate

References CD_ALIGN, p_end, p_next, p_pool, and p_size.

Referenced by p_update_pool().

◆ p_update_pool()

template<class T>
void ran_pool< T >::p_update_pool ( )
inlineprivate

References ASSERT, lgInitialized(), NULL, p_alloc(), p_fill, p_next, p_pool, p_rc, and p_squad.

Referenced by next().

Here is the call graph for this function:

◆ reset()

template<class T>
void ran_pool< T >::reset ( )
inline

References p_end, and p_next.

Member Data Documentation

◆ p_end

template<class T>
T* ran_pool< T >::p_end
private

Referenced by next(), p_alloc(), ran_pool(), and reset().

◆ p_fill

template<class T>
t_ran_fun ran_pool< T >::p_fill
private

Referenced by init(), p_update_pool(), and ran_pool().

◆ p_next

template<class T>
T* ran_pool< T >::p_next
private

◆ p_pool

template<class T>
void* ran_pool< T >::p_pool
private

◆ p_rc

template<class T>
t_ran* ran_pool< T >::p_rc
private

Referenced by init(), p_update_pool(), and ran_pool().

◆ p_size

template<class T>
size_t ran_pool< T >::p_size
private

Referenced by init(), lgInitialized(), p_alloc(), and ran_pool().

◆ p_squad

template<class T>
size_t ran_pool< T >::p_squad
private

Referenced by init(), p_update_pool(), and ran_pool().


The documentation for this class was generated from the following file: