public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hjl.tools at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/54332] [4.8 Regression] 481.wrf in SPEC CPU 2006 takes > 10GB memory to compile
Date: Tue, 21 Aug 2012 19:28:00 -0000	[thread overview]
Message-ID: <bug-54332-4-0btIZVLsBt@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-54332-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54332

--- Comment #22 from H.J. Lu <hjl.tools at gmail dot com> 2012-08-21 19:27:50 UTC ---
This seems to work:

diff --git a/gcc/df-scan.c b/gcc/df-scan.c
index 35100d1..39f444f 100644
--- a/gcc/df-scan.c
+++ b/gcc/df-scan.c
@@ -4392,6 +4392,7 @@ df_bb_verify (basic_block bb)
       if (!INSN_P (insn))
         continue;
       df_insn_refs_verify (&collection_rec, bb, insn, true);
+      df_free_collection_rec (&collection_rec);
     }

   /* Do the artificial defs and uses.  */
diff --git a/gcc/vec.h b/gcc/vec.h
index cc7e819..3a298ff 100644
--- a/gcc/vec.h
+++ b/gcc/vec.h
@@ -1031,21 +1031,9 @@ vec_reserve (vec_t<T> *vec_, int reserve MEM_STAT_DECL)
                           sizeof (T), false
                           PASS_MEM_STAT);
   else
-    {
-      /* Only allow stack vectors when re-growing them.  The initial
-     allocation of stack vectors must be done with the
-     VEC_stack_alloc macro, because it uses alloca() for the
-     allocation.  */
-      if (vec_ == NULL)
-    {
-      fprintf (stderr, "Stack vectors must be initially allocated "
-           "with VEC_stack_alloc.\n");
-      gcc_unreachable ();
-    }
-      return (vec_t<T> *) vec_stack_o_reserve (vec_, reserve,
-                           offsetof (vec_t<T>, vec),
-                           sizeof (T) PASS_MEM_STAT);
-    }
+    return (vec_t<T> *) vec_stack_o_reserve (vec_, reserve,
+                         offsetof (vec_t<T>, vec),
+                         sizeof (T) PASS_MEM_STAT);
 }


  parent reply	other threads:[~2012-08-21 19:28 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-20 18:06 [Bug fortran/54332] New: " hjl.tools at gmail dot com
2012-08-20 20:53 ` [Bug fortran/54332] " hjl.tools at gmail dot com
2012-08-20 21:18 ` hjl.tools at gmail dot com
2012-08-20 21:21 ` steven at gcc dot gnu.org
2012-08-20 21:42 ` hjl.tools at gmail dot com
2012-08-21  2:59 ` hjl.tools at gmail dot com
2012-08-21  8:26 ` rguenth at gcc dot gnu.org
2012-08-21 13:39 ` dnovillo at google dot com
2012-08-21 13:58 ` hjl.tools at gmail dot com
2012-08-21 14:07 ` dnovillo at google dot com
2012-08-21 16:21 ` hjl.tools at gmail dot com
2012-08-21 16:44 ` dnovillo at google dot com
2012-08-21 16:52 ` hjl.tools at gmail dot com
2012-08-21 16:56 ` dnovillo at gcc dot gnu.org
2012-08-21 17:10 ` hjl.tools at gmail dot com
2012-08-21 17:41 ` hjl.tools at gmail dot com
2012-08-21 17:58 ` hjl.tools at gmail dot com
2012-08-21 18:09 ` hjl.tools at gmail dot com
2012-08-21 18:19 ` dnovillo at google dot com
2012-08-21 18:32 ` dnovillo at google dot com
2012-08-21 18:55 ` hjl.tools at gmail dot com
2012-08-21 19:08 ` dnovillo at google dot com
2012-08-21 19:20 ` steven at gcc dot gnu.org
2012-08-21 19:28 ` hjl.tools at gmail dot com [this message]
2012-08-21 19:50 ` dnovillo at google dot com
2012-08-21 19:53 ` hjl.tools at gmail dot com
2012-08-21 20:49 ` dnovillo at google dot com
2012-08-21 21:07 ` hjl at gcc dot gnu.org
2012-08-21 21:11 ` hjl.tools at gmail dot com
2012-08-22  9:02 ` [Bug middle-end/54332] " steven at gcc dot gnu.org

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=bug-54332-4-0btIZVLsBt@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /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).