Sunday 30 October 2011

"Insufficient virtual memory"

From: Ian Tickle
Date: 14 October 2011 10:31


Hello all, some Fortran developer out there must know the answer to
this one.  I'm getting a "forrtl: severe (41): insufficient virtual
memory" error when allocating dynamic memory from a F95 program
compiled with Intel Fortran v11.1.059.  The program was compiled on an
old ia-32 Linux box with 1Gb RAM + 2Gb swap (I only have one Intel
license to compile on this machine), but I'm running it on a brand new
x86-64 box with 12Gb RAM + 8Gb swap.  This should be ample: the
program's maximum total memory requirement (code + static data +
dynamic data) should be no more than 3Gb.

My question is: what do I have to do to make it work?  According to
the ifort man page I need to specify "-mcmodel=medium -shared-intel".

It says: "If your program has COMMON blocks and local data with a
total size smaller than 2GB -mcmodel=small is sufficient.  COMMONs
larger than 2GB require mcmodel=medium or -mcmodel=large.  Allocation
of memory larger than 2GB can be done with any setting of -mcmodel."

I'm a bit confused about the difference here between COMMONS > 2Gb
(which I don't have) and "allocation of memory" > 2Gb (which I assume
I do).

When I try setting -mcmodel=medium (and -shared-intel) I get "ifort:
command line warning #10148: option '-mcmodel' not supported".  Is
this telling me that I have to compile on the 64-bit machine?
Whatever happened to cross-compilation?

All suggestions greatly appreciated!

-- Ian

----------
From: Francois Berenger


Try the GNU (compiler) and see what it says. ;)

----------
From: Ian Tickle


Hi Francois - I won't bore you with the long list of compiler errors
that gfortran gives with my code (ifort compiles the identical code
without error and up until now it has worked just fine on both 32 & 64
bit machines as long as don't try to allocate > 2Gb).

I think we'll have to splash out on an Intel license for a 64-bit
machine (thanks for the low-down on the bugs, Harry).

Anyway thanks to all for the suggestions.

Cheers

-- Ian

----------
From: Kay Diederichs


Hi Ian,

compiling on your 32bit machine gave you a 32bit binary, so your 12GB RAM cannot be used!

HTH,
Kay





No comments:

Post a Comment