Subject: Re: "virtual memory exausted" building netbsd-1-6 for sparc on alpha
To: NetBSD/alpha Discussion List <port-alpha@NetBSD.ORG>
From: Martin Husemann <>
List: port-alpha
Date: 11/08/2003 00:01:47
On Fri, Nov 07, 2003 at 05:22:58PM -0500, Greg A. Woods wrote:
> I'm trying a cross-build of netbsd-1-6 for sparc on my alpha.  It gets this far:
> /build/woods/building/NetBSD-1.6.x-alpha-sparc-tools/bin/sparc--netbsdelf-gcc -O2 -g -DALL_STATE -DUSG_COMPAT -pipe -Wall -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Wno-uninitialized -Wreturn-type -Wpointer-arith -Wswitch -Wshadow  -Werror  -D_LIBC -DLIBC_SCCS -DSYSLIBC_SCCS -D_REENTRANT -I/proven/work/woods/m-NetBSD-1.6/lib/libc/include -DINET6 -DNLS -D__DBINTERFACE_PRIVATE -I/proven/work/woods/m-NetBSD-1.6/lib/libc/../../libexec/ld.elf_so -I/proven/work/woods/m-NetBSD-1.6/lib/libc/dlfcn -DI18NMODULE_MAJOR=4 -DWITH_RUNE -I/proven/work/woods/m-NetBSD-1.6/lib/libc -DRESOLVDEBUG -DRESOLVSORT -I. -DPOSIX_MISTAKE -DPORTMAP -DFLOATING_POINT -nostdinc -isystem /build/woods/building/NetBSD-1.6.x-sparc-destdir/usr/include  -c /proven/work/woods/m-NetBSD-1.6/lib/libc/hash/sha1.c
> /proven/work/woods/m-NetBSD-1.6/lib/libc/hash/sha1.c: In function `_SHA1Transform':
> /proven/work/woods/m-NetBSD-1.6/lib/libc/hash/sha1.c:206: virtual memory exhausted

Gcc 2.95.x had lots of problems compiling sha* code for sparc on 64bit 
machines, most sha* places in our kernel have #ifdef __sparc64__ versions
that split otherwise inlined code into smaller procedures for this reason.

Seems like host=alpha target=sparc triggers the same problem.

It is solved in gcc 3.3.x.