https://gcc.gnu.org/bugzilla/show_bug.cgi?id=118615
--- Comment #28 from Jakub Jelinek <jakub at gcc dot gnu.org> --- I've managed to reproduce the aarch64-linux bootstrap miscompilation with r15-2810, and verified it is the - if (before_p) + if (before_p && PREV_INSN (curr_insn) != prev_insn) part of the last patch that actually fixes not just the -fcompare-debug issue but also the miscompilation. In particular, r15-2809 with #c27 patch bootstraps fine, that with that one liner reverted and (void) prev_insn; added before it segfaults during stage2 selftest the same as vanilla r15-2810.