[mpich-discuss] f77 bindings and profiling
Isaila, Florin D.
fisaila at mcs.anl.gov
Thu Nov 20 12:09:43 CST 2014
ldd output:
fisaila at howard:f77_program$ gfortran init_finalize.f -I/homes/fisaila/software/mpich/include -I/homes/fisaila/software/mpich/include -L/homes/fisaila/software/mpich/lib -L.. -ltarget -lmpifort -Wl,-rpath -Wl,/homes/fisaila/software/mpich/lib -Wl,--enable-new-dtags -lmpi
fisaila at howard:f77_program$ ldd a.out
linux-vdso.so.1 => (0x00007fff5c1ff000)
libmpifort.so.12 => /homes/fisaila/software/mpich/lib/libmpifort.so.12 (0x00007fd2b4957000)
libgfortran.so.3 => /usr/lib/x86_64-linux-gnu/libgfortran.so.3 (0x00007fd2b460f000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fd2b424f000)
libmpi.so.12 => /homes/fisaila/software/mpich/lib/libmpi.so.12 (0x00007fd2b394c000)
libquadmath.so.0 => /usr/lib/x86_64-linux-gnu/libquadmath.so.0 (0x00007fd2b3716000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fd2b3419000)
/lib64/ld-linux-x86-64.so.2 (0x00007fd2b4b91000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fd2b3211000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fd2b2ff4000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fd2b2ddd000)
________________________________________
From: Kenneth Raffenetti [raffenet at mcs.anl.gov]
Sent: Thursday, November 20, 2014 9:37 AM
To: discuss at mpich.org
Subject: Re: [mpich-discuss] f77 bindings and profiling
Can you paste the output of ldd on your binary?
Ken
On 11/20/2014 09:22 AM, Isaila, Florin D. wrote:
> Hi Ken,
>
> it is not working this way.
>
> Florin
> ________________________________________
> From: Kenneth Raffenetti [raffenet at mcs.anl.gov]
> Sent: Wednesday, November 19, 2014 10:56 AM
> To: discuss at mpich.org
> Cc: mpich-discuss at mcs.anl.gov
> Subject: Re: [mpich-discuss] f77 bindings and profiling
>
> On 11/18/2014 09:47 AM, Isaila, Florin D. wrote:
>> fisaila at howard:f77$ mpif77 -show fpi.f
>> gfortran fpi.f -I/homes/fisaila/software/mpich/include -I/homes/fisaila/software/mpich/include -L/homes/fisaila/software/mpich/lib -lmpifort -lfoo -Wl,-rpath -Wl,/homes/fisaila/software/mpich/lib -Wl,--enable-new-dtags -lmpi
>
> This looks to be the problem. PROFILE_PRELIB needs to be added *before*
> libmpifort. Some time after 3.1, we re-organized which symbols go into
> which libraries and now libmpifort.so contains PMPI_Init and all its
> weak aliases (MPI_Init, mpi_init_, etc.) This means the MPI_Init symbol
> is resolved before your library is searched.
>
> Can you manually try a compile line with -lfoo before -lmpifort and
> confirm that it works as expected? I.e.
>
> gfortran fpi.f -I/homes/fisaila/software/mpich/include
> -I/homes/fisaila/software/mpich/include
> -L/homes/fisaila/software/mpich/lib -lfoo -lmpifort -Wl,-rpath
> -Wl,/homes/fisaila/software/mpich/lib -Wl,--enable-new-dtags -lmpi
>
> Ken
> _______________________________________________
> discuss mailing list discuss at mpich.org
> To manage subscription options or unsubscribe:
> https://lists.mpich.org/mailman/listinfo/discuss
> _______________________________________________
> discuss mailing list discuss at mpich.org
> To manage subscription options or unsubscribe:
> https://lists.mpich.org/mailman/listinfo/discuss
>
_______________________________________________
discuss mailing list discuss at mpich.org
To manage subscription options or unsubscribe:
https://lists.mpich.org/mailman/listinfo/discuss
_______________________________________________
discuss mailing list discuss at mpich.org
To manage subscription options or unsubscribe:
https://lists.mpich.org/mailman/listinfo/discuss
More information about the discuss
mailing list