> Implementation Notes
> A. Implementation is straightforward.
> 1. The total number of bytes required on the
> calling platform for the types (and count of
> types) specified in the charDataType are
> enumerated and a block of memory is allocated.
> 2. Offsets in this block are passed to the
> appropriate MPI Datatype construction functions
> and the type is committed.
I simply don't see a general way to implement this function. The user has
created a type with (byte) displacements within it. These displacements can
be caused by several reasons:
a) Simply based on the stride neccessary to move to the next element in
b) Neccessary because of system defined alignments.
c) Neccessary because of an (arbitrary) user defined alignment.
d) Neccessary because of an arbitrary user defined hole (in which the hole
contains legitimate user data which should not be touched).
How does the MPI implementation decide how to scale the byte displacements to
take into account the characteristics of the calling machine? Any simple
will be wrong for one case or the other.
The only sensible use of the above function appears to be to limit it to
types whose displacements are specified in units of other types. This excludes
the (very desirable) "struct" type.
Hughes Aircraft Co.,