Re: [Patch] Fix regex multiple consecutive quantifiers bug.

2014-01-20 Thread Paolo Carlini
Hi, On 01/20/2014 09:31 AM, Marc Glisse wrote: It is a FAQ that you can't get the effects of -Oy with -Ox and a bunch of -f flags. Some things depend directly on the optimization level. For example, inlining of free functions. By the way, I think it is a *very* common experience that -O3 doesn'

Re: [Patch] Fix regex multiple consecutive quantifiers bug.

2014-01-20 Thread Marc Glisse
On Mon, 20 Jan 2014, Tim Shen wrote: ...even the regex input is nothing to do with quantifiers at all (say regex re(" ")), g++ -O3 generates slower code than -O2: ~ # g++ -O2 perf.cc && time ./a.out ./a.out 0.46s user 0.00s system 99% cpu 0.461 total ~ # g++ -O3 perf.cc && time ./a.out ./a.out

Re: [Patch] Fix regex multiple consecutive quantifiers bug.

2014-01-20 Thread Tim Shen
On Sun, Jan 19, 2014 at 4:59 PM, Tim Shen wrote: > Tested and committed. It's quite interesting that after this change in the patch: - this->_M_quantifier(); + while (this->_M_quantifier()); ...even the regex input is nothing to do with quantifiers at all (say regex re(" ")), g++ -O3 generat

Re: [Patch] Fix regex multiple consecutive quantifiers bug.

2014-01-19 Thread Tim Shen
On Sun, Jan 19, 2014 at 5:01 AM, Paolo Carlini wrote: > Ok. Please remove 2013 as copyright year for the tescase. I also think you > can avoid the auxiliary includes. Oops, fixed, including fixing incorrect file name :) Tested and committed. -- Regards, Tim Shen commit 5e36fe9d0d2dbbb2141016d

Re: [Patch] Fix regex multiple consecutive quantifiers bug.

2014-01-19 Thread Paolo Carlini
Hi, On 01/19/2014 06:52 AM, Tim Shen wrote: Regex like "a**" will throw an unexpected exception. Now fixed (but currently no optimizations on it). Booted and tested with -m64 and -m32 respectively. Ok. Please remove 2013 as copyright year for the tescase. I also think you can avoid the auxilia

[Patch] Fix regex multiple consecutive quantifiers bug.

2014-01-18 Thread Tim Shen
Regex like "a**" will throw an unexpected exception. Now fixed (but currently no optimizations on it). Booted and tested with -m64 and -m32 respectively. Thank you! -- Regards, Tim Shen commit ceffce7f974d3ed58ba217807ffd431147ce717f Author: tim Date: Sat Jan 18 23:35:09 2014 -0500 201