problem with mcmodel=large -shared-intel linking with libifcoremt.a "relocation truncated to fit: R_X86_64_PC32 message_catalog

problem with mcmodel=large -shared-intel linking with libifcoremt.a "relocation truncated to fit: R_X86_64_PC32 message_catalog

I'm having a similar problem that "alaryme" had on 12/17/2009   I have a very large (i.e. > 2 Gb) comined Fortran/C code that also must link with several MKL libraries and openmp libraries.  Everything works great as long as I stay less than 2 Gb.  To make my code larger I added the mcmodel=large and -shared-intel to both the compile argument lists and the link argument list.  It all seems to work okay for my fortran compiles, and my C compiles, but it doesn't appear to be linking correctly to the INTEL library libifcoremt.a    Can anyone help me?  LIsted below is the output:

=============================

ifort saramain3.o adjust.o ave_subs.o assemble.o vsurfcp.o xpression.o arpack.o eigena.o /common/progs/lapackblas/lib/intel64/libmkl_lapack.a /opt/intel/composerxe-2011/mkl/lib/intel64/libmkl_solver_lp64.a -Wl,--start-group /opt/intel/composerxe-2011/mkl/lib/intel64/libmkl_intel_lp64.a /opt/intel/composerxe-2011/mkl/lib/intel64/libmkl_intel_thread.a /opt/intel/composerxe-2011/mkl/lib/intel64/libmkl_core.a -mcmodel=large -shared-intel -static-intel -Wl,--end-group -openmp -lpthread -o ./sara3d_pard_drs

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0x17): In function `for__message_catalog_close':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0x941): In function `for__io_return':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xac9): In function `for__io_return':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xad2): In function `for__io_return':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xb23): In function `for__io_return':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xc4e): In function `for__issue_diagnostic':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xe69): In function `for__issue_diagnostic':

: relocation truncated to fit: R_X86_64_PC32 for__l_excpt_info

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xf58): In function `for__issue_diagnostic':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xf61): In function `for__issue_diagnostic':

: relocation truncated to fit: R_X86_64_PC32 message_catalog

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xf9e): In function `for__issue_diagnostic':

: relocation truncated to fit: R_X86_64_PC32 for__l_excpt_info

/opt/intel/fce/10.1.011/lib/libifcoremt.a(for_diags_intel.o)(.text+0xfaf): In function `for__issue_diagnostic':

: additional relocation overflows omitted from the output

make: *** [sara3d] Error 1

================================================

 

6 posts / 0 nouveau(x)
Dernière contribution
Reportez-vous à notre Notice d'optimisation pour plus d'informations sur les choix et l'optimisation des performances dans les produits logiciels Intel.

Take out -static-intel

Steve - Intel Developer Support

Steve - Thank you very much.  Taking out the -static-intel fixed everything.

Glad to hear it. -static-intel was overriding -shared-intel, which is required to make this work.

Steve - Intel Developer Support

I am compiling w/ intel 12.1.5
mpif90 -r8 -heap-arrays -mcmodel=large -shared-intel
and am getting the relocation errors, e.g.:

for_diags_intel.c:(.text+0xa6c): relocation truncated to fit: R_X86_64_PC32 against symbol `message_catalog' defined in COMMON section in /ncar/opt/intel/12.1.0.233/composer_xe_2011_sp1.11.339/compiler/lib/intel64/libifcore.a(for_diags_intel.o)
for_diags_intel.c:(.text+0xbdb): relocation truncated to fit: R_X86_64_PC32 against symbol `message_catalog' defined in COMMON section in /ncar/opt/intel/12.1.0.233/composer_xe_2011_sp1.11.339/compiler/lib/intel64/libifcore.a(for_diags_intel.o)
for_diags_intel.c:(.text+0xbeb): relocation truncated to fit: R_X86_64_PC32 against symbol `message_catalog' defined in COMMON section in /ncar/opt/intel/12.1.0.233/composer_xe_2011_sp1.11.339/compiler/lib/intel64/libifcore.a(for_diags_intel.o)
for_diags_intel.c:(.text+0xc46): relocation truncated to fit: R_X86_64_PC32 against symbol `message_catalog' defined in COMMON section in /ncar/opt/intel/12.1.0.233/composer_xe_2011_sp1.11.339/compiler/lib/intel64/libifcore.a(for_diags_intel.o)
/ncar/opt/intel/12.1.0.233/composer_xe_2011_sp1.11.339/compiler/lib/intel64/libifcore.a(for_diags_intel.o): In function `for__issue_diagnostic':

I have reduced my static memory allocations in several places. I am using the
Linux "size" command to locate where I am allocating large static arrays, e.g.,
"size *.o >! size.out". How do I determine my total static memory usage, so I
know how much I have to reduce to get under the 2GB limit? Do I total all numbers
under the bss column?

I am also linking netcdf v4.2. Thanks for any help,

--Ben
foster@ucar.edu

The size of the .o file is not necessarily related to the size of the memory consumed by the .o file after linking. Try using objdump on the object files being linked. This may expose a large static object. See: http://linux.die.net/man/1/objdump

You may also want to try readelf http://www.ibm.com/developerworks/aix/library/au-unixtools.html

Jim Dempsey

 

 

www.quickthreadprogramming.com

Laisser un commentaire

Veuillez ouvrir une session pour ajouter un commentaire. Pas encore membre ? Rejoignez-nous dès aujourd’hui