[MPICH] MPICH2, FORTRAN disabled, yields switch-case collision

Fritz Anderson fritza at uchicago.edu
Fri Oct 21 16:28:51 CDT 2005


So I'm still working on compiling MPICH2, 1.0.2p1, using the  
configuration

CCFLAGS='-arch ppc64' LDFLAGS='-arch ppc64' CXXFLAGS='-arch ppc64' ./ 
configure --disable-f77 --disable-f90 --prefix='/usr/local' --with- 
pm=mpd:gforker

Note that I have both FORTRAN dialects disabled. This causes mpi.h to  
have the following #defines:

#define MPI_COMPLEX           ((MPI_Datatype)MPI_DATATYPE_NULL)
#define MPI_DOUBLE_COMPLEX    ((MPI_Datatype)MPI_DATATYPE_NULL)
#define MPI_LOGICAL           ((MPI_Datatype)MPI_DATATYPE_NULL)
...
#define MPI_DATATYPE_NULL  ((MPI_Datatype)0x0c000000)
...

Now consider the function CollChk_basic_value() in same_dtype in the  
mce2 tree:

unsigned int CollChk_basic_value(MPI_Datatype type)
{
     switch (type) {
         /*
            MPI_Datatype's that return 0x0 are as if they are being
            skipped/ignored in the comparison of any 2 MPI_Datatypes.
         */
         case MPI_DATATYPE_NULL :
         case MPI_UB :
         case MPI_LB :
             return 0x0;
...
         case MPI_COMPLEX :
             return 0x101;
         case MPI_DOUBLE_COMPLEX :
             return 0x103;
         case MPI_LOGICAL :
             return 0x105;
...

The compiler quite reasonably chokes, because the latter cases have  
the same value as the first.

I find that suppressing the --disable-f77 and -f90 flags does no  
good, probably because the configuration script notices that I don't  
have a FORTRAN compiler.

Is there a way around this? Are users without FORTRAN required to do  
without MPE? Or is there a configuration preprocessor symbol for the  
no-FORTRAN condition so I can #if out the erring cases?

     -- F




More information about the mpich-discuss mailing list