This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Update string_constant for new const initializer code
On Mon, 6 Sep 2010, Jan Hubicka wrote:
> >
> > So if it is replaceable then why is the check necessary? The function
> > looks at DECL_INITIAL anyway and I hope that is not set when
> > !varpool_get_node (array)->const_value_known but DECL_REPLACEABLE_P is
> > true?
> >
> > I'd hate to have two mechanisms that can easily get out of sync.
> >
> > But maybe I'm missing sth.
>
> The problem is opposite. You have DECL_REPLACEABLE_P false, but still
> varpool_get_node (array)->const_value_known is true because we remember from
> WPA stage that the initializer will be put into other ltrans partition.
Huh? Of course DECL_REPLACEABLE_P is false - otherwise the constant
value can't be known but would be determined at dynamic link time.
Richard.