https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93582
Martin Sebor <msebor at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |missed-optimization --- Comment #13 from Martin Sebor <msebor at gcc dot gnu.org> --- So the question is whether the test in the following simplified test case should be folded to false earlier: $ cat pr93582.c && gcc -O2 -S -Wall -fdump-tree-optimized=/dev/stdout pr93582.c struct S { unsigned b:1; }; void f (void) { struct S s; s.b = 0; if (s.b) __builtin_abort (); } ;; Function f (f, funcdef_no=0, decl_uid=1933, cgraph_uid=1, symbol_order=0) f () { struct S s; unsigned char _1; unsigned char _2; <bb 2> [local count: 1073741824]: s.b = 0; _1 = BIT_FIELD_REF <s, 8, 0>; _2 = _1 & 1; if (_2 != 0) goto <bb 3>; [0.00%] else goto <bb 4>; [100.00%] <bb 3> [count: 0]: __builtin_abort (); <bb 4> [local count: 1073741824]: s ={v} {CLOBBER}; return; }