Re: [google gcc-4_8] Tree Loop Unrolling - Relax code size increase with -O2

2014-01-27 Thread Xinliang David Li
Ok. David On Mon, Jan 27, 2014 at 5:02 PM, Sriraman Tallam wrote: > Hi David, > >I had to fix a couple of tests. I have attached the patch with the > fixed tests. The fixes are simple. The tests fail due to two reasons: > > 1) Tests like bmi2-pext32-1a.c fail because the vectorize loop is >

Re: [google gcc-4_8] Tree Loop Unrolling - Relax code size increase with -O2

2014-01-27 Thread Sriraman Tallam
Hi David, I had to fix a couple of tests. I have attached the patch with the fixed tests. The fixes are simple. The tests fail due to two reasons: 1) Tests like bmi2-pext32-1a.c fail because the vectorize loop is unrolled and directive { "scan-assembler-times "bmi2_pext_si3" 1 } fails because

Re: [google gcc-4_8] Tree Loop Unrolling - Relax code size increase with -O2

2014-01-21 Thread Xinliang David Li
ok. David On Tue, Jan 21, 2014 at 4:46 PM, Sriraman Tallam wrote: > On Tue, Jan 21, 2014 at 2:49 PM, Xinliang David Li wrote: >> I think it might be better to introduce a new parameter for max peel >> insn at O2 (e.g, call it MAX_O2_COMPLETELY_PEEL_INSN or >> MAX_DEFAULT_...), and use the same

Re: [google gcc-4_8] Tree Loop Unrolling - Relax code size increase with -O2

2014-01-21 Thread Sriraman Tallam
On Tue, Jan 21, 2014 at 2:49 PM, Xinliang David Li wrote: > I think it might be better to introduce a new parameter for max peel > insn at O2 (e.g, call it MAX_O2_COMPLETELY_PEEL_INSN or > MAX_DEFAULT_...), and use the same logic in your patch to override the > MAX_COMPLETELY_PEELED_INSN paramete

Re: [google gcc-4_8] Tree Loop Unrolling - Relax code size increase with -O2

2014-01-21 Thread Xinliang David Li
I think it might be better to introduce a new parameter for max peel insn at O2 (e.g, call it MAX_O2_COMPLETELY_PEEL_INSN or MAX_DEFAULT_...), and use the same logic in your patch to override the MAX_COMPLETELY_PEELED_INSN parameter at O2). By so doing, we don't need to have a hard coded factor o

[google gcc-4_8] Tree Loop Unrolling - Relax code size increase with -O2

2014-01-21 Thread Sriraman Tallam
Hi, Currently, tree unrolling pass(cunroll) does not allow any code size growth in O2 mode. Code size growth is permitted only if O3 or funroll-loops/fpeel-loops is used. I have created a patch to allow partial code size increase in O2 mode. With funroll-loops the maximum allowed code growt