Re: [V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-11-22 Thread Andrew Pinski via Gcc-patches
On Mon, Nov 22, 2021 at 3:40 AM Richard Biener wrote: > > On Mon, Nov 22, 2021 at 9:40 AM Andrew Pinski wrote: > > > > On Wed, Oct 27, 2021 at 3:42 AM Richard Biener via Gcc-patches > > wrote: > > > > > > On Wed, Oct 27, 2021 at 12:00 PM apinski--- via Gcc-patches > > > wrote: > > > > > > > >

Re: [V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-11-22 Thread Richard Biener via Gcc-patches
On Mon, Nov 22, 2021 at 9:40 AM Andrew Pinski wrote: > > On Wed, Oct 27, 2021 at 3:42 AM Richard Biener via Gcc-patches > wrote: > > > > On Wed, Oct 27, 2021 at 12:00 PM apinski--- via Gcc-patches > > wrote: > > > > > > From: Andrew Pinski > > > > > > The problem here is tree-ssa-forwprop.c

Re: [V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-11-22 Thread Andrew Pinski via Gcc-patches
On Wed, Oct 27, 2021 at 3:42 AM Richard Biener via Gcc-patches wrote: > > On Wed, Oct 27, 2021 at 12:00 PM apinski--- via Gcc-patches > wrote: > > > > From: Andrew Pinski > > > > The problem here is tree-ssa-forwprop.c likes to produce > > [(void *)_4 + 152B] which is the same as > > _4 p+

Re: [V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-10-27 Thread Martin Sebor via Gcc-patches
On 10/27/21 3:59 AM, apinski--- via Gcc-patches wrote: From: Andrew Pinski The problem here is tree-ssa-forwprop.c likes to produce [(void *)_4 + 152B] which is the same as _4 p+ 152 which the rest of GCC likes better. This implements this transformation back to pointer plus to improve

Re: [V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-10-27 Thread Richard Biener via Gcc-patches
On Wed, Oct 27, 2021 at 12:00 PM apinski--- via Gcc-patches wrote: > > From: Andrew Pinski > > The problem here is tree-ssa-forwprop.c likes to produce > [(void *)_4 + 152B] which is the same as > _4 p+ 152 which the rest of GCC likes better. > This implements this transformation back to

Re: [V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-10-27 Thread Bernhard Reutner-Fischer via Gcc-patches
On 27 October 2021 11:59:58 CEST, apinski--- via Gcc-patches wrote: >From: Andrew Pinski > >The problem here is tree-ssa-forwprop.c likes to produce > [(void *)_4 + 152B] which is the same as >_4 p+ 152 which the rest of GCC likes better. >This implements this transformation back to pointer

[V2/PATCH] Fix tree-optimization/102216: missed optimization causing Warray-bounds

2021-10-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski The problem here is tree-ssa-forwprop.c likes to produce [(void *)_4 + 152B] which is the same as _4 p+ 152 which the rest of GCC likes better. This implements this transformation back to pointer plus to improve better code generation later on. OK? Bootstrapped and tested