Compilation problem when using openmpi-1.3.3
Kui Gao
kgao at eecs.northwestern.edu
Wed Nov 25 22:53:48 CST 2009
Hi Chris,
The attached patch is for openmpi-1.3.3. The patch should apply to
the original parallel-netcdf1.1.0. A new MPI_Datatype variable is added in
the struct in order to avoid the convert between nc_type and MPI_Datatype.
Thanks a lot for Rich's patch.
Kui.
________________________________________
From: parallel-netcdf-bounces at lists.mcs.anl.gov
[mailto:parallel-netcdf-bounces at lists.mcs.anl.gov] On Behalf Of Rich Lee
Sent: Wednesday, November 25, 2009 5:38 PM
To: Christoper Daley
Cc: parallel-netcdf at lists.mcs.anl.gov
Subject: Re: Compilation problem when using openmpi-1.3.3
I found that the attached patch I created helped me in compiling
parallel-netcdf 1.1.0 with openmpi (version 1.2.7). Note that the patch
should apply to the original parallel-netcdf 1.1.0 distribution. It
contained addition fix (for C++ compiler) I reported early.
Best regards,
Rich Lee
SLAC National Accelerator Lab
On Tue, Nov 24, 2009 at 9:45 AM, Christoper Daley
<cdaley at flash.uchicago.edu> wrote:
Hi Kui,
I applied the patch, and now get a different compilation error:
mpinetcdf.c: In function ncmpii_postprocess:
mpinetcdf.c:8249: error: incompatible type for argument 1 of
ncmpii_postread
mpinetcdf.c:8143: note: expected nc_type but argument is of type
MPI_Datatype
mpinetcdf.c: In function ncmpi_iget_var1:
mpinetcdf.c:8794: error: incompatible types when assigning to type
MPI_Datatype from type nc_type
mpinetcdf.c: In function ncmpi_iget_var:
mpinetcdf.c:9078: error: incompatible types when assigning to type
MPI_Datatype from type nc_type
mpinetcdf.c: In function ncmpi_iget_vara:
mpinetcdf.c:9372: error: incompatible types when assigning to type
MPI_Datatype from type nc_type
mpinetcdf.c: In function ncmpi_iget_vars:
mpinetcdf.c:9661: error: incompatible types when assigning to type
MPI_Datatype from type nc_type
Chris
Kui Gao wrote:
Hi Chris,
Thank you very much for your report. It is a bug. "nc_type
vartype" should be replaced by "MPI_Datatype vartype" at
L66 in src/lib/pnetcdf.h . The patch file is attached.
Thanks,
Kui.
-----Original Message-----
From: parallel-netcdf-bounces at lists.mcs.anl.gov
[mailto:parallel-netcdf-bounces at lists.mcs.anl.gov] On Behalf Of Rob Ross
Sent: Tuesday, November 24, 2009 8:37 AM
To: Christoper Daley
Cc: parallel-netcdf at lists.mcs.anl.gov
Subject: Re: Compilation problem when using openmpi-1.3.3
Yeah you're right that does look like a bug. Thanks! -- Rob
On Nov 24, 2009, at 12:16 AM, Christoper Daley wrote:
Hi all,
I'm unable to compile parallel-netcdf-1.1.0 with openmpi-1.3.3 compiler
wrapper script (using gcc 4.4.2). I get the following compilation error:
mpinetcdf.c:13216: error: incompatible types when assigning to type
'nc_type' from type 'MPI_Datatype'
(*request)->vartype = datatype;
This looks like a bug to me as vartype is an enum field in the
NCMPI_Req data structure.
I am able to compile parallel-netcdf-1.1.0 with mpich2-1.1.1p1
compiler wrapper script. I think this is because MPI_Datatype is
a typedef for an integer in mpich, and so can be freely
mixed with enum types. This is not the case in openmpi where
MPI_Datatype is a typedef for a pointer to struct.
Thanks for any help,
Chris
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.openmpi
Type: application/octet-stream
Size: 3004 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/parallel-netcdf/attachments/20091125/f8c2c267/attachment.obj>
More information about the parallel-netcdf
mailing list