[mpich-discuss] Fortran integer support 4/8-bytes

William Gropp wgropp at illinois.edu
Thu Jun 7 18:55:40 CDT 2012


So the short answer to what you want is no; the MPICH2 internals are in C and tend to use int, since the intent of the C standard was that "int" was the "natural" (and hence efficient) length integer.  

There are other issues with the use of 8 bytes for Fortran INTEGER; I have an experimental interface option that will build the necessary Fortran to C interface, but it doesn't change the fact that much of the MPICH2 internals use int .

Note that there is no reason that the C compiler couldn't use 8 bytes for an int; in that case, you'd get what you want.  Some of us even remember 2-byte ints ...

Bill

William Gropp
Director, Parallel Computing Institute
Deputy Director for Research
Institute for Advanced Computing Applications and Technologies
Paul and Cynthia Saylor Professor of Computer Science
University of Illinois Urbana-Champaign



On Jun 7, 2012, at 6:03 PM, Jeff Hammond wrote:

> I think I meant something else than what page 494 addresses.
> 
> In the following, can I have the compiler use any size integer for
> COUNT, DATATYPE, DEST, TAG, COMM and IERROR (all the same, of course)?
> If I elect an N-bit integer, can I pass an argument of up to 2^(N-1)
> or am I limited by the internals of MPICH2 to 2^31 no matter what N
> is?  There are two questions here: what, if anything, does the
> standard say about this and what does MPICH2 actually do about it?
> 
> MPI_SEND(BUF, COUNT, DATATYPE, DEST, TAG, COMM, IERROR)
>       <type> BUF(*)
>       INTEGER COUNT, DATATYPE, DEST, TAG, COMM, IERROR
> 
> Thanks,
> 
> jeff
> 
> On Fri, Jun 8, 2012 at 12:48 AM, Reuti <reuti at staff.uni-marburg.de> wrote:
>> Am 08.06.2012 um 00:43 schrieb Jeff Hammond:
>> 
>>> Does MPICH2 support Fortran bindings with 8-byte integers?  Do these
>>> permit values greater than what is representable in a 4-byte integer
>>> or does the lower level implementation in C preclude the use of
>>> arguments greater than 2^31?
>>> 
>>> Sorry for the dumb question.  I consulted the MPI standard (regarding
>>> the general question with Fortran integer sizes) and the MPICH2
>>> install docs (perhaps a rather old PDF from the Internet) but did not
>>> find the answer.
>>> 
>>> If the MPI standard addresses this topic, can someone point me to the
>>> relevant section?  I can find such random topics much easier in my
>>> paper copy but I do not have access to it right now.
>> 
>> Page 494 lists some:
>> 
>> http://www.mpi-forum.org/docs/mpi-2.2/mpi22-report.pdf
>> 
>> -- Reuti
>> 
>> 
>>> Thanks,
>>> 
>>> 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/parts/index.php/User:Jhammond
>>> _______________________________________________
>>> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
>>> To manage subscription options or unsubscribe:
>>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
>> 
>> _______________________________________________
>> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
>> To manage subscription options or unsubscribe:
>> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss
> 
> 
> 
> -- 
> 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/parts/index.php/User:Jhammond
> _______________________________________________
> mpich-discuss mailing list     mpich-discuss at mcs.anl.gov
> To manage subscription options or unsubscribe:
> https://lists.mcs.anl.gov/mailman/listinfo/mpich-discuss



More information about the mpich-discuss mailing list