Re: [PATCH] Add GIMPLE switch support to loop unswitching

2022-05-25 Thread Michael Matz via Gcc-patches
Hello, On Wed, 25 May 2022, Richard Biener via Gcc-patches wrote: > I guess we might want to (warn about labels in the "toplevel" > scope in switch statements). So warn about > > switch (x) > { > case 1: > bar: > }; That style is actually used quite some time in GCC itself. Sometimes with st

Re: [PATCH] Add GIMPLE switch support to loop unswitching

2022-05-25 Thread Richard Biener via Gcc-patches
On Wed, 25 May 2022, David Malcolm wrote: > On Wed, 2022-05-25 at 10:36 +0200, Richard Biener via Gcc-patches > wrote: > > This patch adds support to unswitch loops with switch statements > > based on invariant index.  It furthermore reworks the cost model > > to allow an overall budget of stateme

Re: [PATCH] Add GIMPLE switch support to loop unswitching

2022-05-25 Thread David Malcolm via Gcc-patches
On Wed, 2022-05-25 at 10:36 +0200, Richard Biener via Gcc-patches wrote: > This patch adds support to unswitch loops with switch statements > based on invariant index.  It furthermore reworks the cost model > to allow an overall budget of statements to be created per original > loop by all unswitch