Re: Fold VEC_PERM_EXPR a little more

2012-09-03 Thread Richard Guenther
On Sat, Sep 1, 2012 at 4:38 PM, Marc Glisse wrote: > Hello, > > I noticed while writing the patch posted at: > http://gcc.gnu.org/ml/gcc-patches/2012-08/msg01755.html > > that fold_ternary_loc sometimes doesn't go all the way for VEC_PERM_EXPR, > calling it a second time would fold even more. Fixe

Re: Fold VEC_PERM_EXPR a little more

2012-09-03 Thread Marc Glisse
On Sun, 2 Sep 2012, Hans-Peter Nilsson wrote: On Sat, 1 Sep 2012, Marc Glisse wrote: gcc/ * fold-const.c (fold_ternary_loc): Constant-propagate after removing dead operands. gcc/testsuite/ * gcc.dg/fold-perm.c: Improve test. (adding a line and a parameter to the funct

Re: Fold VEC_PERM_EXPR a little more

2012-09-02 Thread Hans-Peter Nilsson
On Sat, 1 Sep 2012, Marc Glisse wrote: > gcc/ > * fold-const.c (fold_ternary_loc): Constant-propagate after > removing dead operands. > > gcc/testsuite/ > * gcc.dg/fold-perm.c: Improve test. (adding a line and a parameter to the function containing the test-code) JFTR: generally

Fold VEC_PERM_EXPR a little more

2012-09-01 Thread Marc Glisse
Hello, I noticed while writing the patch posted at: http://gcc.gnu.org/ml/gcc-patches/2012-08/msg01755.html that fold_ternary_loc sometimes doesn't go all the way for VEC_PERM_EXPR, calling it a second time would fold even more. Fixed by a simple reordering. (bootstrap and testsuite are ok)