public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "jakub at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug debug/56510] [4.7/4.8 Regression] More var-tracking scalability problems
Date: Mon, 04 Mar 2013 09:23:00 -0000	[thread overview]
Message-ID: <bug-56510-4-5D3MClnUWx@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-56510-4@http.gcc.gnu.org/bugzilla/>


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

--- Comment #10 from Jakub Jelinek <jakub at gcc dot gnu.org> 2013-03-04 09:21:38 UTC ---
That reduced testcase actually compiles in a few seconds on a fast box, so
let's make it larger, then it will take a few years:
struct S { unsigned long s1; void **s2[0]; };
void **a, **b, **c, **d, **e, **f;

static void **
baz (long x, long y)
{
  void **s = f;
  *f = (void **) (y << 8 | (x & 0xff));
  f += y + 1;
  return s;
}

void bar (void);
void
foo (void)
{
  void **g = b[4];
  a = b[2];
  b = b[1];
  g[2] = e;
  void **h = ((void **************************)
a)[1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][1][66];
  void **i = ((struct S *) h)->s2[4];
  d = baz (4, 3);
  d[1] = b;
  d[2] = a;
  d[3] = bar;
  b = d;
  g[1] = i[2];
  a = g;
  ((void (*) (void)) (i[1])) ();
}

Alex, I think creating debug temporaries from within expand_debug_expr sounds
too complicated and furthermore at expand_debug_expr time we don't know yet
whether we'll actually return non-NULL for the whole expression or throw
everything away.  So, what would you think about just keeping the code as is
and just after expand_debug_expr is called, we look at the VARIABLE_LOCATION
second operand and if the RTL nesting depth is deep enough (say 3-4 levels of
nesting?) in something that we'd be ok to split into debug temporaries (I'd say
RTX_*COMPARE/UNARY/*ARITH/TERNARY plus first operand of MEM), create debug
temporary for the subexpression and replace the operand with the debug
temporary.  Otherwise, I'm afraid with TER we can end up with arbitrarily deep
DEBUG_INSN operands.


  parent reply	other threads:[~2013-03-04  9:23 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-02 23:57 [Bug debug/56510] New: adding -g compiles 'forever' vs 49s sam-gccbug at rushing dot nightmare.com
2013-03-03  0:11 ` [Bug debug/56510] " pinskia at gcc dot gnu.org
2013-03-03  0:49 ` sam-gccbug at rushing dot nightmare.com
2013-03-03  0:57 ` steven at gcc dot gnu.org
2013-03-03  1:06 ` steven at gcc dot gnu.org
2013-03-03  1:19 ` sam-gccbug at rushing dot nightmare.com
2013-03-03 11:49 ` [Bug debug/56510] [4.8 Regression] More var-tracking scalability problems steven at gcc dot gnu.org
2013-03-03 12:08 ` jakub at gcc dot gnu.org
2013-03-03 12:16 ` [Bug debug/56510] [4.7/4.8 " steven at gcc dot gnu.org
2013-03-03 12:40 ` jakub at gcc dot gnu.org
2013-03-03 12:50 ` steven at gcc dot gnu.org
2013-03-04  9:23 ` jakub at gcc dot gnu.org [this message]
2013-03-04 10:53 ` rguenth at gcc dot gnu.org
2013-03-04 10:56 ` jakub at gcc dot gnu.org
2013-03-05 13:51 ` jakub at gcc dot gnu.org
2013-03-05 22:32 ` jakub at gcc dot gnu.org
2013-03-05 22:36 ` [Bug debug/56510] [4.7 " jakub at gcc dot gnu.org
2013-03-22 14:43 ` jakub at gcc dot gnu.org
2013-04-03  8:25 ` jakub at gcc dot gnu.org
2013-04-03  8:27 ` jakub 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-56510-4-5D3MClnUWx@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).