Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29261 Discussions

ifort 9.0 error on emt64/amd_x86_64 mode

Deleted_U_Intel
Employee
759 Views

Hi folks,

I have recently attempted to port my code to the ifort compiler
running on amd opteron processors, but have run up against a link
time error that I don't understand. The code compiles fine
on both xeon machines and itanium machines, with the compiler
installations there.

The error that I get (multiple times for different variables) is as follows:

tree.F: relocation truncated to fit: R_386_32 against symbol `treevars_mp_natom_' defined in COMMON section in treevars.o

After a dozen or so variants of this it stops the compile.

treevars is a module that contains declarations of various
data and nothing else. tree.F is a module that uses treevars
and natom is one of the things that is in treevars. It is
defined as a default integer.

I don't understand the meaning of this error and I don't
understand why it is talking about a COMMON section. There
are no common blocks in this part of the code and specifically
the variables it errors on are not in common blocks.
For historical reasons there are a very few common blocks
in other parts of the code.

The version of the compiler is:

Intel Fortran Compiler for Intel EM64T-based aplications, Version 9.0 Build 20051020

Also note that I get the same error on this machine if I use
the ia32 versions of the compilers.

I reduced the compiler options down to nothing as well, to eliminate that ambiguity, but am still lost.

Any suggestions what this error could mean?

Andy

0 Kudos
5 Replies
Steven_L_Intel1
Employee
759 Views
Are you compiling with "-mcmodel medium"? If not, try that. If you still have problems, please report it to Intel Premier Support.
0 Kudos
Deleted_U_Intel
Employee
759 Views

Hi folks,

Additional testing has demonstrated that the code will
compile if its total footprint is less than 1/2 GB. If
I set array dimensions to values that make the footprint
larger than that, I get the errors in the original reference
(except that they were slightly mistyped).

In any case, it appears to me that this is some sort of
configuration or memory model error in my setup or makefile
stuff. I haven't chased it down yet, but there you have it.

Andy Nelson

0 Kudos
Deleted_U_Intel
Employee
759 Views

....oh and one more thing.

Yes, I am compling with -mcmodel=medium.

AN

0 Kudos
mr2
Beginner
759 Views
Hi Andy,
Could this be something to do with position independent code?
I remember something similiar in xlf90 with the TOC on Linux on
Power. Perhaps there is a flag to deal with a 64k limit on TOC.

Following is a section of the Intel manual

Syntax
Linux: -fpic
-fno-pic
Windows: None
Arguments

None
Default
OFF The compiler does not generate position-independent code.
Description

This option tells the compiler to generate position-independent code.

It specifies full symbol preemption. Global symbol definitions as well as global symbol references get default (that is, preemptable) visibility unless explicitly specified otherwise.

On Itanium-based systems and Intel EM64T systems, this option must be used when building shared objects.

This option can also be specified as -fPIC.
0 Kudos
Deleted_U_Intel
Employee
759 Views

Apparently not. I just tried -fpic with no change in
behavior.

A

0 Kudos
Reply