On 05/18/2015 07:35 PM, Richard Henderson wrote: > On 05/11/2015 06:23 AM, Andreas Krebbel wrote: >> @@ -6784,14 +6784,18 @@ expand_vec_perm (machine_mode mode, rtx v0, rtx v1, >> rtx sel, rtx target) >> { >> /* Multiply each element by its byte size. */ >> machine_mode selmode = GET_MODE (sel); >> + /* We cannot re-use SEL as a temp operand since it might by in >> + read-only storage. */ >> + rtx sel_reg = gen_reg_rtx (selmode); >> + >> if (u == 2) >> - sel = expand_simple_binop (selmode, PLUS, sel, sel, >> - sel, 0, OPTAB_DIRECT); >> + sel_reg = expand_simple_binop (selmode, PLUS, sel, sel, >> + sel_reg, 0, OPTAB_DIRECT); >> else > > You needn't allocate sel_reg explicitly; expand_simple_binop will do that for > you if the TARGET parameter is NULL. > > Thus this patch should be an 8 character change on those two calls.
Right. Thanks! Ok to apply with that change? -Andreas-