On Fri, Oct 18, 2019 at 11:06:45AM +0200, Ilya Leoshkevich wrote: > Bootstrapped and regtested on x86_64-redhat-linux, s390x-redhat-linux > and ppc64le-redhat-linux. The offending patch is in gcc-9_1_0-release > and gcc-9_2_0-release - do I need to backport this fix to gcc-9-branch?
It is a regression on 9 (or so I assume), so yes please. > PR rtl-optimization/92007 > * cfgcleanup.c (thread_jump): Add an assertion that we don't > call it after reload if hot/cold partitioning has been done. > (class pass_postreload_jump): Rename to > pass_jump_after_combine. This fits on one line just fine. > (make_pass_postreload_jump): Rename to > make_pass_jump_after_combine. > * passes.def(pass_postreload_jump): Move before reload, rename Space before (. > --- a/gcc/cfgcleanup.c > +++ b/gcc/cfgcleanup.c > @@ -259,6 +259,10 @@ thread_jump (edge e, basic_block b) > bool failed = false; > reg_set_iterator rsi; > > + /* Jump threading may cause fixup_partitions to introduce new crossing > edges, > + which is not allowed after reload. */ > + gcc_checking_assert (!reload_completed || !crtl->has_bb_partition); Thanks for the assert, that will help prevent people from running into this again. The patch looks fine to me, but I'm not a global reviewer :-) Segher