public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Mark Mitchell <mark@codesourcery.com>
To: Joe Buck <Joe.Buck@synopsys.com>
Cc: "Joseph S. Myers" <joseph@codesourcery.com>,
	 Ian Lance Taylor <ian@wasabisystems.com>,
	gcc@gcc.gnu.org
Subject: Re: Compiler uses a lot of memory for large initialized arrays
Date: Thu, 02 Dec 2004 18:23:00 -0000	[thread overview]
Message-ID: <41AF5D87.3010507@codesourcery.com> (raw)
In-Reply-To: <20041202101803.A18628@synopsys.com>

Joe Buck wrote:

> If we successfully reach the end of the initializer without anything evil
> like the above case, then append the temp file to the assembly output.
> Otherwise, go back and do it in memory.

I can't fathom why we are considering things like this.

Like anything else, we should try to use an efficient representation, 
which we are not, at present.  We should fix that.  But why should we go 
beyond that, jumping through complicated hoops to support initialization 
of gigabytes of data?  We don't jump through these kinds of hoops to 
support compilation of functions with millions of lines of code, or 
translation units with millions of functions.

I think it's perfectly reasonable to run out of memory processing a 
truly huge array -- provided that the compiler is being sensible about 
its internal representation.

-- 
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com
(916) 791-8304

  reply	other threads:[~2004-12-02 18:23 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-02 16:08 Ian Lance Taylor
2004-12-02 16:34 ` Joseph S. Myers
2004-12-02 17:03   ` Ian Lance Taylor
2004-12-02 17:05   ` Steven Bosscher
2004-12-02 17:12     ` Richard Guenther
2004-12-02 17:17       ` Nathan Sidwell
2004-12-02 17:29         ` Peter Barada
2004-12-02 17:39           ` Mark Mitchell
2004-12-02 17:42           ` Ian Lance Taylor
2004-12-02 17:49           ` Dave Korn
2004-12-02 17:36       ` Andreas Schwab
2004-12-02 18:18   ` Joe Buck
2004-12-02 18:23     ` Mark Mitchell [this message]
2004-12-02 17:31 ` Mark Mitchell
2004-12-02 17:33 ` Giovanni Bajo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41AF5D87.3010507@codesourcery.com \
    --to=mark@codesourcery.com \
    --cc=Joe.Buck@synopsys.com \
    --cc=gcc@gcc.gnu.org \
    --cc=ian@wasabisystems.com \
    --cc=joseph@codesourcery.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).