This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Add value_range_base (w/o equivs)
Ughhhh ok.
On Mon, Nov 12, 2018, 12:10 Richard Biener <rguenther@suse.de wrote:
> On Mon, 12 Nov 2018, Aldy Hernandez wrote:
>
> >
> >
> > On 11/11/18 3:53 AM, Richard Biener wrote:
> > > On Fri, 9 Nov 2018, Aldy Hernandez wrote:
> > >
> > > > On 11/9/18 9:19 AM, Richard Biener wrote:
> > > > >
> > > > > This adds value_range_base, a base class of class value_range
> > > > > with all members but the m_equiv one.
> > > >
> > > > First of all, thanks so much for doing this!
> > > >
> > > > >
> > > > > I have looked into the sole GC user, IPA propagation, and replaced
> > > > > the value_range use there with value_range_base since it also
> > > > > asserted the equiv member is always NULL.
> > > > >
> > > > > This in turn means I have written down that GC users only can
> > > > > use value_range_base (and fixed the accessability issue with
> > > > > adding a bunch of friends).
> > > >
> > > > > +
> > > > > /* Range of values that can be associated with an SSA_NAME after
> VRP
> > > > > - has executed. */
> > > > > -class GTY((for_user)) value_range
> > > > > + has executed. Note you may only use value_range_base with GC
> > > > > memory.
> > > > > */
> > > > > +class GTY((for_user)) value_range_base
> > > > > +{
> > > >
> > > > GC users cannot use the derived value_range? Either way could you
> > > > document
> > > > the "why" this is the case above?
> > >
> > > I've changed the comment as it was said to be confusing. The reason is
> > > the marking isn't implemented.
> >
> > Ah, I see. In which case, shouldn't you then remove the GTY() markers
> from
> > the derived class?
> >
> > /* Note value_range cannot currently be used with GC memory, only
> > value_range_base is fully set up for this. */
> > class GTY((user)) value_range : public value_range_base
>
> It's required to make gengtype happy...
>
> Richard.
>