Next: Named Constants
Up: Data Structures
Previous: Data Structures
Contents
Descriptor data structure
All the general matrix informations and elements to be
exchanged among processes are stored within a data structure of the
type descdatapsb_desc_type.
Every structure of this type is associated to a sparse matrix, it
contains data about general matrix informations and elements to be
exchanged among processes.
It is not necessary for the user to know the internal structure of
psb_desc_type
, it is set in a transparent mode by the tools
routines of Sec. 6, and its fields may be accessed
if necessary via the routines of sec. 3.5;
nevertheless we include a description for the curious
reader:
- matrix_data
- includes general information about matrix and
process grid, such as the communication context, the size of the
global matrix, the size of the portion of matrix stored on the current
process, and so on.
Specified as: an allocatable integer array of dimension
psb_mdata_size_
.
- halo_index
- A list of the halo and boundary elements for
the current process to be exchanged with other processes; for each
processes with which it is necessary to communicate:
- Process identifier;
- Number of points to be received;
- Indices of points to be received;
- Number of points to be sent;
- Indices of points to be sent;
The list may contain an arbitrary number of groups; its end is marked
by a -1.
Specified as: an allocatable integer array of rank one.
- ext_index
- A list of element indices to be exchanged to
implement the mapping between a base descriptor and a descriptor
with overlap.
- ovrlap_index
- A list of the overlap elements for the
current process, organized in groups like the previous vector:
- Process identifier;
- Number of points to be received;
- Indices of points to be received;
- Number of points to be sent;
- Indices of points to be sent;
The list may contain an arbitrary number of groups; its end is marked
by a -1.
Specified as: an allocatable integer array of rank one.
- ovr_mst_idx
- A list to retrieve the value of each
overlap element from the respective master process.
Specified as: an allocatable integer array of rank one.
- ovrlap_elem
- For all overlap points belonging to th
ecurrent process:
- Overlap point index;
- Number of processes sharing that overlap points;
- Index of a ``master'' process:
Specified as: an allocatable integer array of rank two.
- loc_to_glob
- each element of this array contains
global identifier of the local variable .
Specified as: an allocatable integer array of rank one.
- glob_to_loc, glb_lc, hashv
- Contain a mapping from
global to local indices.
The Fortran 95 definition for psb_desc_type
structures is
as follows:
Figure 3:
The PSBLAS defined data type that
contains the communication descriptor.
|
A communication descriptor associated with a sparse matrix has a
state, which can take the following values:
- Build:
- State entered after the first allocation, and before the
first assembly; in this state it is possible to add communication
requirements among different processes.
- Assembled:
- State entered after the assembly; computations using
the associated sparse matrix, such as matrix-vector products, are
only possible in this state.
The global to local index mapping may be stored in two different
formats: the first is simpler but more expensive, as it requires on
each process an amount of memory proportional to the global size of
the index space; the second is more complex, but only requires memory
proportional to the local index space size. The choice is made at the
time of the initialization according to a threshold; this threshold
may be queried and set using the functions in
sec. 3.5.
Subsections
Next: Named Constants
Up: Data Structures
Previous: Data Structures
Contents