🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: gnu.gcc.bug
Article #750

Re: gcc "fails" in stage1 compile

#750
From: Piet van Oostrum
Date: Mon, 23 Oct 1989 10:43
37 lines
2174 bytes
In article <1407@calvin.EE.CORNELL.EDU>, johns@calvin (John Sahr) writes:
 `computer: Decstation 3100, 8Mbyte memory
 `gcc v1.36, ftp'd from prep.ai.mit.edu
 `
 `I have been attempting to install gcc-1.36 on a Decstation 3100, 8 Mb.
 `After running "config.gcc decstation", the first compile with cc runs
 `fine.
 `
 `However, the stage 1 self compile grabs more and more and more virtual
 `memory, until the whole computer just stops (can't rlogin, can't login, etc).
 `I did remove the "-g" from the CFLAGS in the stage 1 compile.  Is there
 `an alternate compilation order, or something, that is less memory hungry?

This happens also on other workstations. The problem is in the alloca()
emulation using malloc(). This grabs more and more memory until finally the
machine thrashes, paging in and out like mad.

This will not happen if you don't specify -O.

Solution:

Either compile the first compiler with gcc and take care that your alloca
is #defined as _builtin_alloca.

Or if you can't start with gcc:
Do the stage1 and stage2 compilation without the -O flag. (both, otherwise
they will not compare equal)
To get an optimized compiler, you can then redo the stage1/stage2 stuff (or
call them stage3/stage4) with gcc -O. Don't forget to #define alloca.

I think someone reported the omission of the #define alloca in the mips
configuration. 
-- 
Piet van Oostrum, Dept of Computer Science, University of Utrecht
Padualaan 14, P.O. Box 80.089, 3508 TB Utrecht,  The Netherlands.
Telephone: +31-30-531806      Internet: piet@cs.ruu.nl
Telefax:   +31-30-513791      Uucp: uunet!mcsun!hp4nl!ruuinf!piet
Technical Details
Message-ID: <1731@ruuinf.cs.ruu.nl>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!mcsun!hp4nl!ruuinf!piet
References: <1407@calvin.EE.CORNELL.EDU>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!mcsun!hp4nl!ruuinf!piet
From: piet@cs.ruu.nl (Piet van Oostrum)
Newsgroups: gnu.gcc.bug
Subject: Re: gcc "fails" in stage1 compile
Keywords: gcc 1.36 decstation stage1
Message-ID: <1731@ruuinf.cs.ruu.nl>
Date: 23 Oct 89 10:43:39 GMT
References: <1407@calvin.EE.CORNELL.EDU>
Sender: news@ruuinf.cs.ruu.nl
Reply-To: piet@cs.ruu.nl (Piet van Oostrum)
Organization: Dept of Computer Science, University of Utrecht, Holland
Lines: 37
In-reply-to: johns@calvin.EE.CORNELL.EDU (John Sahr)