[cfe-commits] r54237 - in /cfe/trunk: lib/CodeGen/CGExprAgg.cpp test/CodeGen/2008-07-30-implicit-initialization.c

Daniel Dunbar daniel at zuster.org
Thu Jul 31 09:38:45 PDT 2008


Eli,

Thanks for catching this, in fact I meant to but then it slipped my mind.

The problem is actually after memset has been lowered so I filed a new bug
on it: http://llvm.org/PR2619


 - Daniel


----- Original Message ----
From: Eli Friedman <eli.friedman at gmail.com>
To: Daniel Dunbar <daniel at zuster.org>
Cc: cfe-commits at cs.uiuc.edu
Sent: Wednesday, July 30, 2008 5:46:45 PM
Subject: Re: [cfe-commits] r54237 - in /cfe/trunk: lib/CodeGen/CGExprAgg.cpp test/CodeGen/2008-07-30-implicit-initialization.c

On Wed, Jul 30, 2008 at 2:00 PM, Daniel Dunbar <daniel at zuster.org> wrote:
> +#if 0
> +/* Optimizer isn't smart enough to reduce this since we use
> +   memset. Hrm. */
> +int f1() {
> +  struct s0 x[2] = { {0} };
> +  return x[1].x;
> +}
> +#endif

It might be worth filing a bug on this.  I don't think it It should be
very difficult to make GVN smart enough to deal with this.

-Eli




More information about the cfe-commits mailing list