https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105990
Bug ID: 105990 Summary: Dead code elimination failed at -O3 Product: gcc Version: 13.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: tree-optimization Assignee: unassigned at gcc dot gnu.org Reporter: crazylht at gmail dot com Target Milestone: --- static struct { int a; } b, c; static int d = -1; void foo(); int main() { if (b.a) d = 2 | (b.a <= 0); for (; b.a; b.a++) c = b; if (!d) foo(); } foo() can be eliminated since d would never be zero.