[MITgcm-support] OpenMPI and Mac Pro
Martin Losch
Martin.Losch at awi.de
Fri Mar 4 02:38:08 EST 2011
Hi Nicolas,
this looks very much like the bug in the gfortran compiler, over which I stumbled a few weeks ago (see here for more details and a demonstration of how often I can upload wrong files: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47574). The bug has been fixed but you probably downloaded the binaries from hcp.sourceforge.net, and that version still contains the bug. I have notified Gaurav Khanna (who is behind this really helpful web-page) and I am also waiting/hoping for him to update the binary. In the meantime I add this to my optfile (which basically reduces the optimizaiton for a few files as Jean-Michel suggested):
NOOPTFLAGS='-O1 -funroll-loops -ftree-vectorize'
NOOPTFILES='exch2_uv_agrid_3d_r4.F exch2_uv_agrid_3d_r8.F exch2_uv_agrid_3d_rl.F exch2_uv_agrid_3d_rs.F exch2_uv_bgrid_3d_r4.F exch2_uv_cgrid_3d_r4.F exch2_uv_cgrid_3d_r8.F exch2_uv_cgrid_3d_rl.F exch2_uv_cgrid_3d_rs.F'
Martin
On Mar 4, 2011, at 3:46 AM, Jean-Michel Campin wrote:
> Hi Nicolas,
>
> I have an other suggestion (not very original): I would try a lower
> optimisation: -O3 is the default in darwin_ia32_gfortran+mpi and it
> happens sometimes that "internal compiler error" goes away with -O2
> or -O1 instead of -O3.
>
> Cheers,
> Jean-Mcihel
>
> On Thu, Mar 03, 2011 at 06:18:19PM -0800, Yuan Lian wrote:
>> I assume you used macports to install 64bit gcc, gfortran and openmpi. I
>> am using this opt file
>> and so far it works very well on an 8 core mac pro. Hope this helps.
>>
>>
>> CPP='/usr/bin/cpp -traditional -P'
>> FC=openmpif90
>> CC=openmpicc
>>
>> LINK=openmpif90
>> NOOPTFLAGS='-O0'
>> EXTENDED_SRC_FLAG='-ffixed-line-length-132'
>> MPIROOT=/opt/local
>>
>> S64='$(TOOLSDIR)/set64bitConst.sh'
>> DEFINES='-DWORDLENGTH=4 -DNML_TERMINATOR'
>> INCLUDEDIRS=`pkg-config --variable=includedir`
>> INCLUDES=$(eval echo "-I/opt/local/include/openmpi -I/opt/local/include
>> " `pkg-config --cflags`)
>> LIBS='-L/opt/local/lib'
>>
>> # For IEEE, use the "-ffloat-store" option
>> if test "x$IEEE" = x ; then
>> FFLAGS='-Wunused -Wuninitialized -fno-second-underscore
>> -fconvert=big-endian'
>> FOPTIM='-O3 -funroll-loops'
>> NOOPTFLAGS='-O2 -funroll-loops'
>> else
>> FFLAGS='-Wunused -ffloat-store -fno-second-underscore
>> -fconvert=big-endian'
>> FOPTIM='-O0'
>> fi
>>
>> On 3/3/11 2:40 PM, Nicolas Grisouard wrote:
>>> Hi,
>>>
>>> I just got a brand new 8-core Mac Pro and am trying to run a
>>> parallelized version of MITgcm. I use GCC 4.6 (which includes
>>> gfortran) and OpenMPI 1.4
>>>
>>> To build it, I tried to start from the optfile
>>> darwin_ia32_gfortran+mpi and just added an additional path for the
>>> libs (see attached). genmake2 with option -mpi works well, make depend
>>> too but the compilation itself produces the following error:
>>>
>>> make: *** [exch_uv_agrid_3d_rl.o] Error 1
>>> exch_uv_agrid_3d_rs.for: In function ‘exch_uv_agrid_3d_rs’:
>>> exch_uv_agrid_3d_rs.for:278:0: internal compiler error: in
>>> build2_stat, at tree.c:3795
>>> Please submit a full bug report,
>>> with preprocessed source if appropriate.
>>> See <http://gcc.gnu.org/bugs.html> for instructions.
>>>
>>> It's tempting to follow the suggestion but as a few people are using
>>> this configuration, I was wondering what their configuration/optfile
>>> were, or if they had come accross this problem. And maybe there is a
>>> more dumb problem, given my gross lack of experience in parallelized
>>> computing.
>>>
>>> Also note that this error occurs when I indicate nPx=2 in SIZE.h, and
>>> not when nPx=1. In the latter case, compilation goes smoothly. The
>>> configuration is basically MITgcm/verification/internal_wave as I'm
>>> still running some tests.
>>>
>>> Thanks for all the help/input.
>>> Nicolas.
>>>
>>>
>>> _______________________________________________
>>> MITgcm-support mailing list
>>> MITgcm-support at mitgcm.org
>>> http://mitgcm.org/mailman/listinfo/mitgcm-support
>>
>
>> _______________________________________________
>> MITgcm-support mailing list
>> MITgcm-support at mitgcm.org
>> http://mitgcm.org/mailman/listinfo/mitgcm-support
>
>
> _______________________________________________
> MITgcm-support mailing list
> MITgcm-support at mitgcm.org
> http://mitgcm.org/mailman/listinfo/mitgcm-support
More information about the MITgcm-support
mailing list