On Thu, Nov 8, 2018 at 3:24 PM Richard Biener <richard.guent...@gmail.com> wrote: > > On Thu, Nov 8, 2018 at 1:17 PM Aldy Hernandez <al...@redhat.com> wrote: > > > > This one's rather obvious and does not depend on any get_range_info API > > change. > > > > OK for trunk? > > Hmm, no - that's broken. IIRC m_equiv are shared bitmaps if you > do tem = *old_vr so you modify it in place with equiv_clear(). > > Thus, operator= should be really deleted or mapped to value_range::set() > in which case tem = *old_vr would do useless bitmap allocation and > copying that you then clear. > > It's also two lines of code instead of one.
And... (making uses of operator= not link): /space/rguenther/src/gcc-slpcost/gcc/ipa-prop.c:1781: undefined reference to `value_range::operator=(value_range const&)' /space/rguenther/src/gcc-slpcost/gcc/tree-ssa-threadedge.c:169: undefined reference to `value_range::operator=(value_range const&)' /space/rguenther/src/gcc-slpcost/gcc/tree-vrp.c:230: undefined reference to `value_range::operator=(value_range const&)' /space/rguenther/src/gcc-slpcost/gcc/tree-vrp.c:237: undefined reference to `value_range::operator=(value_range const&)' /space/rguenther/src/gcc-slpcost/gcc/tree-vrp.c:562: undefined reference to `value_range::operator=(value_range const&)' tree-vrp.o:/space/rguenther/src/gcc-slpcost/gcc/tree-vrp.c:1163: more undefined references to `value_range::operator=(value_range const&)' follow can you investiage all those for the same error? Since we need to do deep copying for the equiv bitmap I think operator=() should be not implemented: diff --git a/gcc/tree-vrp.h b/gcc/tree-vrp.h index c251329a195..ad4b0cd621b 100644 --- a/gcc/tree-vrp.h +++ b/gcc/tree-vrp.h @@ -45,6 +45,7 @@ class GTY((for_user)) value_range void update (value_range_kind, tree, tree); bool operator== (const value_range &) const; bool operator!= (const value_range &) const; + value_range& operator=(const value_range &); void intersect (const value_range *); void union_ (const value_range *); likewise for copy construction. Richard. > Richard.