https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120987
--- Comment #28 from Andrew Pinski <pinskia at gcc dot gnu.org> --- (In reply to Andrew Pinski from comment #27) > This means this loop: > ``` > /* Combine in outer flags. */ > cgraph_node *n; > for (n = edge->caller; n->inlined_to; n = n->callers->caller) > flags |= flags_from_decl_or_type (n->decl); > flags |= flags_from_decl_or_type (n->decl); > ``` > is wrong. > I am not even sure this loop even makes sense. I removed this loop and the combine of outer flags and I didn't get any regressions and it fixes the wrong code here because of what I wrote in comment #27 as it was combining NOTHROW and NORETURN and getting the wrong info. Or maybe the fix is ignore_stores_p below the loop only should look the original decl's flags ...
