https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120599
Bug ID: 120599 Summary: [16 Regression] Copy prop for aggregates loses non-call exception Product: gcc Version: 16.0 Status: UNCONFIRMED Keywords: EH, wrong-code Severity: normal Priority: P3 Component: tree-optimization Assignee: pinskia at gcc dot gnu.org Reporter: pinskia at gcc dot gnu.org Target Milestone: --- Take: ``` // { dg-do compile } // { dg-additional-options "-fexceptions -fnon-call-exceptions" } struct RefitOption { char subtype; int string; } n; void h(RefitOption) __attribute__((nothrow)); void k(RefitOption *__val, RefitOption a) { try { a = *__val; RefitOption __trans_tmp_2 = a; h(__trans_tmp_2); } catch(...){} } ``` At -O1 and above the load from *__val is proped into __trans_tmp_2 and that statement does not have a landing pad possibility because it was known not to trap before hand. I will be fixing this when I get back from vacation in July.