Re: Ping agian: [PATCH V2] Loop split upon semi-invariant condition (PR tree-optimization/89134)

2019-09-12 Thread Feng Xue OS
>> Suppose a loop as: >> >> void f (std::map m) >> { >> for (auto it = m.begin (); it != m.end (); ++it) { >> /* if (b) is semi-invariant. */ >> if (b) { >> b = do_something();/* Has effect on b */ >> } else { >>

Re: Ping agian: [PATCH V2] Loop split upon semi-invariant condition (PR tree-optimization/89134)

2019-09-12 Thread Richard Biener
On Mon, Jul 15, 2019 at 4:20 AM Feng Xue OS wrote: > > Some time passed, so ping again. I made this patch, because it can reward us > with 7% > > performance benefit in some real application. For convenience, the > optimization to be > > implemented was listed in the following again. And hope

Re: Ping agian: [PATCH V2] Loop split upon semi-invariant condition (PR tree-optimization/89134)

2019-09-12 Thread Feng Xue OS
Hi, Michael, Since I was involved in other tasks, it is a little bit late to reply you. Sorry for that. I composed a new one with your suggestions. Please review that when you are in convenience. > Generally I do like the idea of the transformation, and the basic building > blocks seem to be

Re: Ping agian: [PATCH V2] Loop split upon semi-invariant condition (PR tree-optimization/89134)

2019-07-31 Thread Feng Xue OS
Thanks for these comments. Feng From: Michael Matz Sent: Tuesday, July 30, 2019 1:59:04 AM To: Feng Xue OS Cc: Richard Biener; gcc-patches@gcc.gnu.org Subject: Re: Ping agian: [PATCH V2] Loop split upon semi-invariant condition (PR tree-optimization

Re: Ping agian: [PATCH V2] Loop split upon semi-invariant condition (PR tree-optimization/89134)

2019-07-29 Thread Michael Matz
Hello Feng, first, sorry for the terrible delay in reviewing, but here is one now :) Generally I do like the idea of the transformation, and the basic building blocks seem to be sound. But I dislike it being a separate pass, so please integrate the code you have written into the existing loop