Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-09-16 Thread Richard Biener
On Fri, Sep 13, 2019 at 2:30 PM Martin Liška wrote: > > On 8/20/19 8:39 AM, Richard Biener wrote: > > Anyhow, the original patch is OK if you compare > > OBJ_TYPE_REF_TOKEN/OBJECT irrespective of virtual_method_call_p > > and order the types_same_for_odr last since that's most expensive. > > Hi.

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-09-13 Thread Martin Liška
On 8/20/19 8:39 AM, Richard Biener wrote: Anyhow, the original patch is OK if you compare OBJ_TYPE_REF_TOKEN/OBJECT irrespective of virtual_method_call_p and order the types_same_for_odr last since that's most expensive. Hi. It's done in the attached patch that survives bootstrap and

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-20 Thread Jan Hubicka
> I see. I guess dropping them if !virtual_method_call_p (at what point > do we know?) would be a good thing. As well as encoding > "types_same_for_odr" and obj_type_ref_class in a more direct manner. > I guess in reality OBJ_TYPE_REF should be all info on the > gimple_call rather than in a

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-20 Thread Richard Biener
On Mon, Aug 19, 2019 at 4:34 PM Jan Hubicka wrote: > > > On Fri, Aug 16, 2019 at 2:07 PM Jan Hubicka wrote: > > > > > > > > > > > When we compare OBJ_TYPE_REF_TOKEN and OBJ_TYPE_REF_OBJECT > > > > and they are equal, are there cases where types_same_for_odr returns > > > > false? > > > > > >

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-19 Thread Jan Hubicka
> On Fri, Aug 16, 2019 at 2:07 PM Jan Hubicka wrote: > > > > > > > > When we compare OBJ_TYPE_REF_TOKEN and OBJ_TYPE_REF_OBJECT > > > and they are equal, are there cases where types_same_for_odr returns > > > false? > > > > OBJ_TYPE_REF_OBJECT is pointer to the instance, OBJ_TYPE_REF_TOKEN is >

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-19 Thread Richard Biener
On Fri, Aug 16, 2019 at 2:07 PM Jan Hubicka wrote: > > > > > When we compare OBJ_TYPE_REF_TOKEN and OBJ_TYPE_REF_OBJECT > > and they are equal, are there cases where types_same_for_odr returns false? > > OBJ_TYPE_REF_OBJECT is pointer to the instance, OBJ_TYPE_REF_TOKEN is > index in the vtable

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-16 Thread Jan Hubicka
> > When we compare OBJ_TYPE_REF_TOKEN and OBJ_TYPE_REF_OBJECT > and they are equal, are there cases where types_same_for_odr returns false? OBJ_TYPE_REF_OBJECT is pointer to the instance, OBJ_TYPE_REF_TOKEN is index in the vtable or the type given by obj_ref_type_class. I guess one can do

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-16 Thread Richard Biener
On Thu, Aug 15, 2019 at 4:57 PM Jan Hubicka wrote: > > > On Tue, Aug 6, 2019 at 5:43 PM Martin Liska wrote: > > > > > > > > > gcc/ChangeLog: > > > > + /* Virtual table call. */ > > + case OBJ_TYPE_REF: > > + { > > + if (!operand_equal_p (OBJ_TYPE_REF_EXPR (arg0), >

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-15 Thread Jan Hubicka
> On Tue, Aug 6, 2019 at 5:43 PM Martin Liska wrote: > > > > > > gcc/ChangeLog: > > + /* Virtual table call. */ > + case OBJ_TYPE_REF: > + { > + if (!operand_equal_p (OBJ_TYPE_REF_EXPR (arg0), > + OBJ_TYPE_REF_EXPR (arg1), flags)) >

Re: [PATCH 3/9] operand_equal_p: add support for OBJ_TYPE_REF.

2019-08-07 Thread Richard Biener
On Tue, Aug 6, 2019 at 5:43 PM Martin Liska wrote: > > > gcc/ChangeLog: + /* Virtual table call. */ + case OBJ_TYPE_REF: + { + if (!operand_equal_p (OBJ_TYPE_REF_EXPR (arg0), + OBJ_TYPE_REF_EXPR (arg1), flags)) + return