https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91720
--- Comment #5 from Jakub Jelinek <jakub at gcc dot gnu.org> --- (In reply to Eric Botcazou from comment #3) > > So, the bug is either in nonzero_bits that it for the > > WORD_REGISTER_OPERATIONS and load_extend_op (QImode) == ZERO_EXTEND returns > > 0s in the upper bits, or in > > simplify_and_const_int trusting nonzero_bits even on paradoxical subregs, > > ... > > As Jim said on gcc-patches@, let's concede defeat for > WORD_REGISTER_OPERATIONS and just remove it from the compiler. This will > pessimize but I'm personally fed up with this endless stream of nonsensical > bug reports with dozens of improbable -fno-xxxx switches... The "nonsensical bug reports" just happen to uncover bugs in the RTL optimizers and backends that are usually latent because GIMPLE optimizations optimize stuff before it has a chance to get into RTL. It isn't clear to me how WORD_REGISTER_OPERATIONS is supposed to work, while loads from memory will have those upper bits of the paradoxical regs perhaps clear, the registers can be set by other operations; do we zero extend say any addition afterwards to ensure that? And in this case, do all immediate loads need to be also zero extended for LOAD_EXTEND_OP ZERO_EXTEND?