Documentation for module cp_fm_pool_types

pool for for elements that are retained and released

source: cp_fm_pool_types.F
Loading...

public Types:

cp_fm_pool_type
represent a pool of elements with the same structure
cp_fm_pool_p_type
to create arrays of pools

public Subroutines/Functions:

Returns a vector with an element from each pool
SUBROUTINE
fm_pools_dealloc (pools)
deallocate an array of pools (releasing each pool)
returns a vector to the pools. The vector is deallocated (like cp_fm_vect_dealloc)
creates a pool of elements
returns an element, allocating it if none is in the pool
returns the structure of the elements in this pool
returns the element to the pool
SUBROUTINE
fm_pool_release (pool)
releases the given pool (see cp2k/doc/ReferenceCounting.html)
SUBROUTINE
fm_pool_retain (pool)
retains the pool (see cp2k/doc/ReferenceCounting.html)

public Types:

TYPE :: cp_fm_pool_p_type

to create arrays of pools


POINTER :: pool the pool

TYPE :: cp_fm_pool_type

represent a pool of elements with the same structure


INTEGER
:: ref_count reference count (see /cp2k/doc/ReferenceCounting.html)
INTEGER
:: id_nr ...
POINTER :: el_struct the structure of the elements stored in this pool
POINTER :: cache linked list with the elements in the pool

SUBROUTINEfm_pools_create_fm_vect(pools, elements, name)

Returns a vector with an element from each pool

Arguments:
POINTER
:: pools(:) the pools to create the elements from
POINTER
:: elements(:) will contain the vector of elements
CHARACTER(*),
INTENT(in),
OPTIONAL
:: name the name for the new matrixes (optional)

SUBROUTINEfm_pools_dealloc(pools)

deallocate an array of pools (releasing each pool)

Arguments:
POINTER
:: pools(:) the pools to release

SUBROUTINEfm_pools_give_back_fm_vect(pools, elements)

returns a vector to the pools. The vector is deallocated (like cp_fm_vect_dealloc)

Arguments:
POINTER
:: pools(:) the pool where to give back the vector
POINTER
:: elements(:) the vector of elements to give back

SUBROUTINEfm_pool_create(pool, el_struct)

creates a pool of elements

Arguments:
POINTER
:: pool the pool to create
POINTER
:: el_struct the structure of the elements that are stored in this pool

SUBROUTINEfm_pool_create_fm(pool, element, name)

returns an element, allocating it if none is in the pool

Arguments:
POINTER
:: pool the pool from where you get the element
TYPE(cp_fm_type),
POINTER
:: element will contain the new element
CHARACTER(*),
INTENT(in),
OPTIONAL
:: name the name for the new matrix (optional)

FUNCTIONfm_pool_get_el_struct(pool)

returns the structure of the elements in this pool

Return Value ::
Arguments:
POINTER
:: pool the pool you are interested in

SUBROUTINEfm_pool_give_back_fm(pool, element)

returns the element to the pool

Arguments:
POINTER
:: pool the pool where to cache the element
TYPE(cp_fm_type),
POINTER
:: element the element to give back

SUBROUTINEfm_pool_release(pool)

releases the given pool (see cp2k/doc/ReferenceCounting.html)

Arguments:
POINTER
:: pool the pool to release

SUBROUTINEfm_pool_retain(pool)

retains the pool (see cp2k/doc/ReferenceCounting.html)

Arguments:
POINTER
:: pool the pool to retain