phdMesh
Version of the Day
|
Classes | |
class | Array |
The preferred multi-dimensional Array interface with compile-time user-defined dimension ordinates. More... | |
class | ArrayDimTag |
Abstract base class for array dimension tags supplied to the Array template class. More... | |
class | ArrayDimension |
An anonymous array dimension tag, which is NOT the recommended usage. More... | |
class | Array< Scalar, array_order, void, void, void, void, void, void, void, void > |
The not-preferred multi-dimensional Array interface with runtime user-defined dimension ordinates. Typically used when runtime-polymorphic arrays are passed to functions. More... | |
class | StaticAssert |
Compiler-enforced value of 'expression == true'. More... | |
class | CSet |
Set of entities of arbitrary types. More... | |
struct | IndexList |
Compile-time list of indices. More... | |
struct | IndexListAt |
Access member of compile-time list of indices. Defines enum { value = index_at_J }; More... | |
class | NamedValue |
NamedValue to an ordinary value. More... | |
class | NamedValue< void > |
Base class for references provides access to anonymous type. More... | |
class | NamedValue< T & > |
NamedValue to an ordinary reference. More... | |
class | NamedValue< const T & > |
NamedValue to an ordinary constant value. More... | |
class | NamedValue< T[N] > |
NamedValue to a fixed size array. More... | |
class | NamedValue< T * > |
NamedValue to a fixed size array of ordinary values. More... | |
class | NamedValue< const T * > |
NamedValue to a const fixed size array of ordinary values . More... | |
class | NamedValue< std::vector< T > > |
NamedValue to a std::vector. More... | |
class | NamedValue< const std::vector< T > & > |
NamedValue to a const std::vector. More... | |
struct | NumericEnum |
Map a numeric scalar Type to an integer value. More... | |
struct | NumericEnum< void > |
Map the integer value associated with a numeric scalar type to a text name or byte size. More... | |
struct | NumericType |
Inverse map of a numeric scalar type to an integer value. More... | |
struct | IdentProcBox |
class | PairIter |
Pair of begin and end iterators wrapped to provide a container-like view of the span. More... | |
class | PairIter< IterType, std::random_access_iterator_tag > |
Pair of begin and end iterators wrapped to provide a container-like view of the span. More... | |
struct | IdentProc |
class | ParallelIndex |
class | SetvMember |
Base class for Setv members.Objects stored in a Setv container must be derived from this template base class with the key type for the container. More... | |
class | SetvIter |
Template class for the Setv bidirectional iterators. More... | |
class | Setv |
Associative container of explictly managed entities. More... | |
class | SameType |
Member enum { value = ... }; is true if T1 and T2 are the same type. More... | |
class | TypeList |
A link within a linked list of types.A linked list of types where Tail is required to either terminate the list with TypeListEnd or continue the list with another instantiation of TypeList . More... | |
class | TypeListLength |
Member enum { value = ... }; is the length of the type list. More... | |
class | TypeListAt |
Member typedef ... type ; is the type of the member of ListType at location ordinal if ordinal is less than the type list length. More... | |
class | TypeListIndex |
Member enum { value = ... }; is the location within ListType of occurance I of type TestValue . If this occurance does not exist then value = -1 . More... | |
class | TypeListCount |
Member enum { value = ... }; is the number of occurances of TestValue within ListType . More... | |
class | TypeListMember |
Member enum { value = ... }; is true if TestValue is a member of ListType . More... | |
class | TypeListUnique |
Member enum { value = ... }; is true if each member of ListType appears exactly once. More... | |
class | TypeListDisjoint |
Member enum { value = ... }; is true if all members of ListA are not a member ListB . More... | |
class | TypeListFirst |
Member typedef ... type ; is the first member of ListType . More... | |
class | TypeListLast |
Member typedef ... type ; is the last member of ListType . More... | |
class | TypeListAppend |
Member typedef ... type ; is defined by appending T to the end of ListA . More... | |
class | TypeListJoin |
Member typedef ... type ; is defined by joining ListB to the end of ListA . More... | |
class | TypeListEraseAt |
Member typedef ... type ; is defined by erasing member at ordinal from ListType . More... | |
class | TypeListClean |
Member typedef ... type ; is defined by truncating ListType at the first occurance of TypeListEnd . Used by MakeTypeList to generate a clean type list. More... | |
class | MakeTypeList |
Member typedef ... type ; is the type list formed from the template arguments. More... | |
Enumerations | |
enum | ArrayOrder { NaturalOrder, FortranOrder, RankZero } |
Define Natural (C-language) or Fortran ordering of array dimensions. A RankZero array does not have an ordering. More... | |
Functions | |
unsigned | array_stride_size (const unsigned rank, const unsigned *const stride) |
Return the total number of members from the array stride. | |
void | array_stride_to_natural_dimensions (const unsigned rank, const unsigned *const stride, unsigned *const dim) |
Generate natural dimension from array stride. | |
void | array_stride_to_natural_indices (const unsigned rank, const unsigned *const stride, const unsigned offset, unsigned *const indices) |
Generate natural indices from array stride. | |
void ** | fixed_pool_buffer_init (const std::size_t nbyte_total, const std::size_t nbyte, void **) |
void | throw_fixed_pool_buffer_bad_size (const std::size_t nbyte_total, const std::size_t nbyte_first, const std::size_t nbyte) |
void | throw_fixed_pool_buffer_exhausted (const std::size_t nbyte_total, const std::size_t nbyte) |
void | throw_fixed_pool_buffer_bad_deallocate (const std::size_t, void *const ) |
template<unsigned NBYTE, typename T > | |
bool | operator== (const FixedPoolAllocator< NBYTE, T > &lhs, const FixedPoolAllocator< NBYTE, T > &rhs) |
template<unsigned NBYTE, typename T > | |
bool | operator!= (const FixedPoolAllocator< NBYTE, T > &lhs, const FixedPoolAllocator< NBYTE, T > &rhs) |
std::istream & | operator>> (std::istream &s, NamedValueSet &v) |
std::ostream & | operator<< (std::ostream &s, const NamedValueSet &v) |
OctTreeKey | hsfc3d (const unsigned Depth, const unsigned *const coord) |
unsigned | oct_tree_size (const unsigned Depth) |
unsigned | oct_tree_offset (const unsigned Depth, const OctTreeKey &) |
template<unsigned Depth> | |
unsigned | oct_tree_offset (const OctTreeKey &k) |
void | box_global_bounds (ParallelMachine arg_comm, const unsigned arg_domain_boxes_number, const IdentProcBox *const arg_domain_boxes, const unsigned arg_range_boxes_number, const IdentProcBox *const arg_range_boxes, float *const arg_global_box) |
bool | oct_tree_proximity_search (ParallelMachine arg_comm, const float *const arg_global_box, const unsigned arg_domain_boxes_number, const IdentProcBox *const arg_domain_boxes, const unsigned arg_range_boxes_number, const IdentProcBox *const arg_range_boxes, const OctTreeKey *const arg_cuts, std::vector< std::pair< IdentProc, IdentProc > > &arg_relation, unsigned *const arg_search_tree_stats=NULL) |
bool | hsfc_box_covering (const float *const global_box, const float *const small_box, OctTreeKey *const covering, unsigned &number) |
void | oct_tree_partition_course (ParallelMachine comm, const unsigned length, const OctTreeKey *const keys, const float *const weights, OctTreeKey *const cut_keys, const unsigned override_ncuts=0) |
void | oct_tree_partition_fine (ParallelMachine comm, const unsigned length, const OctTreeKey *const keys, const float *const weights, OctTreeKey *const cut_keys) |
void | oct_tree_partition_private (const unsigned p_first, const unsigned p_end, const unsigned depth, const double tolerance, float *const weights, const unsigned cuts_length, OctTreeKey *const cuts) |
ParallelMachine | parallel_machine_null () |
ParallelMachine | parallel_machine_init (int *, char ***) |
void | parallel_machine_finalize () |
double | wall_time () |
double | wall_dtime (double &) |
unsigned | parallel_machine_size (ParallelMachine m) |
unsigned | parallel_machine_rank (ParallelMachine m) |
void | parallel_machine_barrier (ParallelMachine) |
bool | comm_sizes (ParallelMachine, const unsigned num_msg_bound, unsigned &num_msg_maximum, const unsigned *const send_size, unsigned *const recv_size, bool local_flag=false) |
bool | comm_dense_sizes (ParallelMachine, const unsigned *const send_size, unsigned *const recv_size, bool local_flag=false) |
void | all_write_string (ParallelMachine, std::ostream &, const std::string &) |
void | all_reduce_sum (ParallelMachine, const double *local, double *global, unsigned count) |
void | all_reduce_sum (ParallelMachine, const float *local, float *global, unsigned count) |
void | all_reduce_sum (ParallelMachine, const int *local, int *global, unsigned count) |
void | all_reduce_bor (ParallelMachine, const unsigned *local, unsigned *global, unsigned count) |
void | all_reduce_internal (ParallelMachine arg_comm, ParallelReduceOp arg_op, void *arg_in, void *arg_out, unsigned arg_len) |
template<class Op1 > | |
void | all_reduce (ParallelMachine comm, const Op1 &op1) |
template<class Op1 , class Op2 > | |
void | all_reduce (ParallelMachine comm, const Op1 &op1, const Op2 &op2) |
template<class Op1 , class Op2 , class Op3 > | |
void | all_reduce (ParallelMachine comm, const Op1 &op1, const Op2 &op2, const Op3 &op3) |
template<class Op1 , class Op2 , class Op3 , class Op4 > | |
void | all_reduce (ParallelMachine comm, const Op1 &op1, const Op2 &op2, const Op3 &op3, const Op4 &op4) |
template<class Op1 , class Op2 , class Op3 , class Op4 , class Op5 > | |
void | all_reduce (ParallelMachine comm, const Op1 &op1, const Op2 &op2, const Op3 &op3, const Op4 &op4, const Op5 &op5) |
template<class Op1 , class Op2 , class Op3 , class Op4 , class Op5 , class Op6 > | |
void | all_reduce (ParallelMachine comm, const Op1 &op1, const Op2 &op2, const Op3 &op3, const Op4 &op4, const Op5 &op5, const Op6 &op6) |
template<unsigned N, typename T > | |
void | Copy (T *dst, const T &src) |
dst[k] = src , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | Copy (T *dst, const T *src) |
dst[k] = src[k] , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | Sum (T *dst, const T *src) |
dst[k] += src[k] , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | Sum (T *dst, const T &a, const T *src) |
dst[k] += a * src[k] , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | Prod (T *dst, const T *src) |
dst[k] *= src[k] , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | Min (T *dst, const T *src) |
dst[k] = min( dst[k] , src[k] ) , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | Max (T *dst, const T *src) |
dst[k] = max( dst[k] , src[k] ) , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | BitOr (T *dst, const T *src) |
dst[k] |= src[k] , k = 0..N-1 | |
template<unsigned N, typename T > | |
void | BitAnd (T *dst, const T *src) |
dst[k] &= src[k] , k = 0..N-1 | |
template<unsigned N, typename T > | |
T | InnerProduct (const T *x, const T *y) |
return sum_k( x[k] * y[k] ) | |
template<unsigned N, typename T > | |
bool | Equal (const T *x, const T *y) |
return x[k] == y[k] , k == 0..N-1 | |
template<unsigned N, typename T > | |
bool | NotEqual (const T *x, const T *y) |
return ! ( x[k] == y[k] , k == 0..N-1 ) | |
template<unsigned N, typename T > | |
bool | Less (const T *x, const T *y) |
return x[k] < y[k] , first k such that x[k] != y[k] | |
template<unsigned N, typename T > | |
bool | LessEqual (const T *x, const T *y) |
return x[k] <= y[k] , first k such that x[k] != y[k] | |
template<unsigned N, typename T > | |
bool | Greater (const T *x, const T *y) |
return x[k] > y[k] , first k such that x[k] != y[k] | |
template<unsigned N, typename T > | |
bool | GreaterEqual (const T *x, const T *y) |
return x[k] => y[k] , first k such that x[k] != y[k] | |
int | test_driver (ParallelMachine, std::istream &, const TestDriverMap &) |
int | test_driver (ParallelMachine, const TestDriverMap &, int argc, const char *const *argv) |
std::string | type_name_array (const std::string &, unsigned) |
template<typename T > | |
std::string | type_name_array (unsigned n) |
std::string | type_name_vector (const std::string &, unsigned=0) |
template<typename T > | |
std::string | type_name_vector (unsigned n=0) |
OctTreeKey phdmesh::hsfc3d | ( | const unsigned | Depth, |
const unsigned *const | coord | ||
) |
Generate a 3D Hilbert space filling curve oct-tree key.
unsigned phdmesh::oct_tree_offset | ( | const unsigned | Depth, |
const OctTreeKey & | |||
) |
Offset of a oct-tree node in a dense tree of a given depth.
void phdmesh::box_global_bounds | ( | ParallelMachine | arg_comm, |
const unsigned | arg_domain_boxes_number, | ||
const IdentProcBox *const | arg_domain_boxes, | ||
const unsigned | arg_range_boxes_number, | ||
const IdentProcBox *const | arg_range_boxes, | ||
float *const | arg_global_box | ||
) |
Global bounds for a set of boxes. The lower bound is the minimum of all boxes, decreased by epsilon. The upper bound is the maximum of all boxes, increased by epsilon. Thus all input boxes are fully contained within the global box.
bool phdmesh::oct_tree_proximity_search | ( | ParallelMachine | arg_comm, |
const float *const | arg_global_box, | ||
const unsigned | arg_domain_boxes_number, | ||
const IdentProcBox *const | arg_domain_boxes, | ||
const unsigned | arg_range_boxes_number, | ||
const IdentProcBox *const | arg_range_boxes, | ||
const OctTreeKey *const | arg_cuts, | ||
std::vector< std::pair< IdentProc, IdentProc > > & | arg_relation, | ||
unsigned *const | arg_search_tree_stats = NULL |
||
) |
Search for intersection of domain boxes with range boxes within a given global bounding box. Output vector of matches with a domain or range box on the local processor.
If 'arg_cuts' is given it will be used for the parallel search. If 'arg_cuts == NULL' then a balanced internal partitioning will be generated.
The search_tree_stats are for the local search: [0] = minimum search tree domain cell size [1] = maximum search tree domain cell size [2] = average search tree domain cell size [3] = minimum search tree range cell size [4] = maximum search tree range cell size [5] = average search tree range cell size These statistics require an extra communication to gather.
Returns 'true' if all small boxes on all processors had non-negative volumes and were fully contained within the global box.
bool phdmesh::hsfc_box_covering | ( | const float *const | global_box, |
const float *const | small_box, | ||
OctTreeKey *const | covering, | ||
unsigned & | number | ||
) |
Generate an oct-tree covering of a small box within a global box. The cartesian space is mapped to an oct-tree via Hilbert space filling curve. The covering consists of 1..8 oct-tree cells, the 'covering' array must be dimensioned to at least eight. Returns true for a "good" small box: it a non-negative volume and is fully contained within the global box.
void phdmesh::oct_tree_partition_course | ( | ParallelMachine | comm, |
const unsigned | length, | ||
const OctTreeKey *const | keys, | ||
const float *const | weights, | ||
OctTreeKey *const | cut_keys, | ||
const unsigned | override_ncuts = 0 |
||
) |
Given an array of oct-tree keys and weights generate a course partitioning of the oct-tree key space. The algorithm is fast with a single 'all_reduce' operation.
void phdmesh::oct_tree_partition_fine | ( | ParallelMachine | comm, |
const unsigned | length, | ||
const OctTreeKey *const | keys, | ||
const float *const | weights, | ||
OctTreeKey *const | cut_keys | ||
) |
Given an array of oct-tree keys and weights generate a fine partitioning of the oct-tree key space. The algorithm is likely to produce a better balance than the previous course algorithm. However, it performs more communcations and computations.
void phdmesh::oct_tree_partition_private | ( | const unsigned | p_first, |
const unsigned | p_end, | ||
const unsigned | depth, | ||
const double | tolerance, | ||
float *const | weights, | ||
const unsigned | cuts_length, | ||
OctTreeKey *const | cuts | ||
) |
A recursive kernel used within the oct_tree_partitioning algorithms. Exposed to support unit testing.
bool phdmesh::comm_sizes | ( | ParallelMachine | , |
const unsigned | num_msg_bound, | ||
unsigned & | num_msg_maximum, | ||
const unsigned *const | send_size, | ||
unsigned *const | recv_size, | ||
bool | local_flag = false |
||
) |
Given the send sizes determine the receive sizes. Send and receive size arrays are dimensioned to the size of the parallel machine. Return global parallel logical OR of the input local flag. This parallel reduction is aggregated into the required communication for determining the sparse sizes. Output the receive sizes and maximum number of send or receive messages for a single processor. A dense all-to-all communication is used if: num_msg_bound < num_msg_maximum otherwise a set of point-to-point messages are used.
bool phdmesh::comm_dense_sizes | ( | ParallelMachine | , |
const unsigned *const | send_size, | ||
unsigned *const | recv_size, | ||
bool | local_flag = false |
||
) |
If the communication is known to be dense.
void phdmesh::all_write_string | ( | ParallelMachine | , |
std::ostream & | , | ||
const std::string & | |||
) |
Write string from any or all processors to the ostream on the root processor.