[mpich-discuss] Using __float128 with MPI_Accumulate()?

Jeff Hammond jhammond at alcf.anl.gov
Sun Dec 25 21:23:43 CST 2011


On Sun, Dec 25, 2011 at 5:33 PM, Jed Brown <jedbrown at mcs.anl.gov> wrote:
> GCC 4.6 introduced support for quad precision using the __float128 type.
> Since __float128 is not part of the MPI standard, PETSc defines new real and
> complex MPI_Datatypes for __float128 and we define our own MPI_SUM, MPI_MAX,
> etc. This works fine for "normal" reductions, but it's a problem with
> MPI_Accumulate() because the standard does not allow user-defined reduce
> operations.

Any RMA implementation that uses active-messages anyways shouldn't
care about types to some degree, so it would be straightforward, but
not standard-conforming, to support accumulation of __float128 in
MPICH2.  This does not suggest that anyone will implement it, just
that it is theoretically possible.

The primary reason that the MPI standard does not allow user-defined
reductions for MPI_Accumulate is not the nature of floating-point
types, but rather the operations themselves, since user-defined
accumulate is equivalent to active-messages, which cannot be
implemented in hardware.  Of course, __float128 is not supported by
any hardware I know of, but neither is complex double, but the Forum
found a way to let that one slide.

> Is there any way to work around this limitation other than to not use
> MPI_Accumulate() in any context that might some day be asked to work with
> __float128?

What is your tolerance for "some day"?  It is hard to imagine this
getting in MPI 3.1 easily, given the Forum's opposition (well, just
some members) to RMA features that are not readily implementable in
hardware.  However, I can imagine some finite amount of beer would be
sufficient to get support from the open implementations of MPI.

Jeff

-- 
Jeff Hammond
Argonne Leadership Computing Facility
University of Chicago Computation Institute
jhammond at alcf.anl.gov / (630) 252-5381
http://www.linkedin.com/in/jeffhammond
https://wiki.alcf.anl.gov/old/index.php/User:Jhammond


More information about the mpich-discuss mailing list