memory limit in pgf77


I’m trying to compile a code requiring very large memory (~6-7GB) with pgf77.
If I compile it with simple ‘pgf77 -O’, it shows limit of memory capacity at ~2GB.
If I add an option of -mcmodel=medium when compiling, memory capacity increases, but only to about 4GB.
If I require more memory than this, I got the error messages like “undefined reference to `.BSS1’”.

I’m wondering whether there is any way to increase memory capacty over 4GB. The RAM memory in my cluster is 24GB, and it’s frustrating that I can’t use enough memory although there is plenty of it.
Thank you.


There are various requirements and limitations to large memory access, some of the latter traceable to limitations in the OS.

Read about the -Mlarge_arrays, -i8, -Mlargeaddressaware options in the PGI User Guide.

Hi Sung-Joon,

Are you using data initialization? If so, then the problem is that your code size is growing beyond 2GB. The medium memory model only allows the data to grow beyond 2GB. The large memory model is required for the code to go beyond 2GB. To work around the problem, initialize your data at runtime.

  • Mat