Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-15 Thread Richard Biener
On Tue, 14 Apr 2020, Jan Hubicka wrote: > > > > But we're using it in indirect_ref_may_alias_decl_p as > > > > /* If second reference is view-converted, give up now. */ > > if (same_type_for_tbaa (TREE_TYPE (dbase2), TREE_TYPE (ptrtype2)) != > > 1) > > return true; > > >

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Jan Hubicka
> > But we're using it in indirect_ref_may_alias_decl_p as > > /* If second reference is view-converted, give up now. */ > if (same_type_for_tbaa (TREE_TYPE (dbase2), TREE_TYPE (ptrtype2)) != > 1) > return true; > > and clearly if TREE_TYPE (ptrtype2) is void * while

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Richard Biener
On Tue, 14 Apr 2020, Jan Hubicka wrote: > > > > Note that now, looking again, the TYPE_STRUCTURAL_EQUALITY_P in my patch > > doesn't match that of get_alias_set. Since we're looking at the alias > > sets of type1 and type2 anyway we could resort to alias_sets_conflict_p > > for the two

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Jan Hubicka
> > Note that now, looking again, the TYPE_STRUCTURAL_EQUALITY_P in my patch > doesn't match that of get_alias_set. Since we're looking at the alias > sets of type1 and type2 anyway we could resort to alias_sets_conflict_p > for the two POINTER_TYPE_P case and return -1 then. Not sure about >

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Richard Biener
On Tue, 14 Apr 2020, Jan Hubicka wrote: > > On Tue, 14 Apr 2020, Richard Sandiford wrote: > > > > > Richard Biener writes: > > > > This makes same_type_for_tbaa_p conservative in the same way > > > > get_alias_set is about void * which we allow to alias all other > > > > pointers. > > > > > > >

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Jan Hubicka
> On Tue, 14 Apr 2020, Richard Sandiford wrote: > > > Richard Biener writes: > > > This makes same_type_for_tbaa_p conservative in the same way > > > get_alias_set is about void * which we allow to alias all other > > > pointers. > > > > > > Bootstrap & regtest running on

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Richard Biener
On Tue, 14 Apr 2020, Richard Sandiford wrote: > Richard Biener writes: > > This makes same_type_for_tbaa_p conservative in the same way > > get_alias_set is about void * which we allow to alias all other > > pointers. > > > > Bootstrap & regtest running on x86_64-unknown-linux-gnu. > > > >

Re: [PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Richard Sandiford
Richard Biener writes: > This makes same_type_for_tbaa_p conservative in the same way > get_alias_set is about void * which we allow to alias all other > pointers. > > Bootstrap & regtest running on x86_64-unknown-linux-gnu. > > Honza, is this what you had in mind? > > Thanks, > Richard. > >

[PATCH] middle-end/94539 - void * aliases every other pointer

2020-04-14 Thread Richard Biener
This makes same_type_for_tbaa_p conservative in the same way get_alias_set is about void * which we allow to alias all other pointers. Bootstrap & regtest running on x86_64-unknown-linux-gnu. Honza, is this what you had in mind? Thanks, Richard. 2020-04-14 Richard Biener PR