Re: [PATCH] Implement smart multiple switch expansion algorithms.

2017-12-29 Thread Martin Liška
On 10/06/2017 03:46 PM, Wilco Dijkstra wrote: > Martin Liska wrote: > >> There are some numbers for cc1plus: >> >> $ bloaty ./objdir2/gcc/cc1plus -- ./objdir/gcc/cc1plus >> VM SIZE FILE SIZE >> +3.8% +1.11Mi TOTAL +1.03Mi +0.5% > >> insn-attrtab.o: >> VM S

Re: [PATCH] Implement smart multiple switch expansion algorithms.

2017-12-29 Thread Martin Liška
On 10/06/2017 07:24 PM, David Malcolm wrote: > On Fri, 2017-10-06 at 14:25 +0200, Martin Liška wrote: >> Hello. >> >> As presented at this year's Cauldron, I rewrote current switch >> expansion to support >> multiple algorithms (jump table and bit-test) that can be used just >> for a fraction >> of

Re: [PATCH] Implement smart multiple switch expansion algorithms.

2017-10-06 Thread Mikhail Maltsev
Hi. I have watched Martin's talk on switch lowering improvements ( https://slideslive.com/38902416/switch-lowering-improvements), the last slide has a question about benchmarks that can be used for tuning the switch statement optimizer. Martin mentioned one common use case - bytecode interpreters

Re: [PATCH] Implement smart multiple switch expansion algorithms.

2017-10-06 Thread David Malcolm
On Fri, 2017-10-06 at 14:25 +0200, Martin Liška wrote: > Hello. > > As presented at this year's Cauldron, I rewrote current switch > expansion to support > multiple algorithms (jump table and bit-test) that can be used just > for a fraction > of cases. Balanced decision tree is built on top of tha

Re: [PATCH] Implement smart multiple switch expansion algorithms.

2017-10-06 Thread Wilco Dijkstra
Martin Liska wrote: > There are some numbers for cc1plus: > > $ bloaty ./objdir2/gcc/cc1plus -- ./objdir/gcc/cc1plus > VM SIZE FILE SIZE > +3.8% +1.11Mi TOTAL +1.03Mi +0.5% > insn-attrtab.o: > VM SIZE FILE SIZE > +214% +682Ki .r

[PATCH] Implement smart multiple switch expansion algorithms.

2017-10-06 Thread Martin Liška
ap on ppc64le-redhat-linux and survives regression tests. I'm still planning to come with some numbers and stats. Will do that next week. Martin >From db7ad52eb5d65e41d617fb3ff10ab1bc2cef8d04 Mon Sep 17 00:00:00 2001 From: marxin Date: Wed, 20 Sep 2017 15:22:04 +0200 Subject: [PAT