Andrew Stubbs <[email protected]> writes: > On 09/10/2026 12:15, Richard Sandiford wrote: >> Sorry, a couple of other things: >> >>>> + >>>> + rtx new_addr >>>> + = (REG_P (addr) >>>> + ? simplify_gen_subreg (addr_elt_mode, addr, addrmode, >>>> + addr_byte) >>>> + : simplify_subreg (addr_elt_mode, addr, addrmode, addr_byte)); >> >> I think we should use simplify_gen_subreg unconditionally unless there's >> a specific reason not to. This is a simplification regardless of what >> the address is. > > I tried this and got an ICE. AFAICT, simplify_gen_subreg does the wrong > thing (in this situation) when the address has an offset: > > (mem/i:V8QI (plus:V8DI (reg:V8DI 720) > (vec_duplicate:V8DI (const_int 0)))) > > It tries to wrap the plus in a subreg, which is not valid. So, I'm going > to leave this bit as-is, unless you have a better suggestion?
Why's it not valid though? Richard
