how to make use of more memory on HP-UX when comiling with gcc
Guerra-Salcedo, Cesar M
Tue Sep 4 17:26:00 GMT 2007
I know this is trivial for many of you but I have no clue. I am trying to run a program compiled with gcc under HP-UX. The machine is supposed to have 32G main memory. My program is a very simple C program that reads two arrays (doubles) into memory (I am using malloc for the array) the size of each array is about 700K rows*124 columns. If I compile it with MS C in a windows environment I can make use of all available memory for the machine so in my PC with 2Gb I have no problems in running it. When compiling it and running it in the HP-UX environment I cannot get enough memory for both arrays. I used "gcc program.c -O -N -lm -o program" (If I don't use the -N option it gets even worst.). Is there a way to compile (maybe I am missing something with -N or some other directive for gcc) that will allow me to make use of all available memory ???
I have gcc version 4.1.0
Any help will be much appreciated.
Thanks a lot Cesar.
More information about the Gcc-help