Re: [PATCH] Improve pow (C, x) -> exp (log (C) * x) optimization (PR middle-end/84309, take 2)

2018-02-13 Thread Richard Biener
On Mon, 12 Feb 2018, Jakub Jelinek wrote: > On Sat, Feb 10, 2018 at 03:26:46PM +0100, Jakub Jelinek wrote: > > If use_exp2 is true and (cfun->curr_properties & PROP_gimple_lvec) == 0, > > don't fold it? Then I guess if we vectorize or slp vectorize the pow > > as vector pow, we'd need to

[PATCH] Improve pow (C, x) -> exp (log (C) * x) optimization (PR middle-end/84309, take 2)

2018-02-12 Thread Jakub Jelinek
On Sat, Feb 10, 2018 at 03:26:46PM +0100, Jakub Jelinek wrote: > If use_exp2 is true and (cfun->curr_properties & PROP_gimple_lvec) == 0, > don't fold it? Then I guess if we vectorize or slp vectorize the pow > as vector pow, we'd need to match.pd it into the exp (log (vec_cst) * x). Here is an