"virtual memory exhausted: Out of memory" with a large static array

Rask Ingemann Lambertsen rask@sygehus.dk
Thu Feb 8 18:46:00 GMT 2007


On Thu, Feb 08, 2007 at 04:30:24PM +0100, Pavel Saviankou wrote:

> First I try the "g++ (GCC) 4.1.2 20070115 (prerelease) (SUSE Linux)" and -O0.
> The compilation breaks with  "virtual memory exhausted: Out of memory".
> The same result, even if i turn on the optimisation -O1,2,3,4,5 and a lot of 
> flags -fxxx .-
> 
> Then i try the "g++ (GCC) 3.4.5".
> It compiles,  both with -O0 and with -O1,2,3,4,5!

   This is a known regression. New versions of GCC can only compile small
arrays. I don't know the bug number (if it has one) or the version of GCC
where this regression was introduced.

-- 
Rask Ingemann Lambertsen



More information about the Gcc-help mailing list