https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91358
--- Comment #5 from Marc Glisse <glisse at gcc dot gnu.org> --- (In reply to Richard Biener from comment #4) > I guess valgrind could be improved to check > only at uses of the uninit value? It is used. In the easy case it would be used in "undef & 0", so the result does not depend on undef. It may get a bit complicated for valgrind to recognize all operations that do not depend on one of the operands, but a subset would be doable. However, here we transform: if (x) if (y) ... to if (x & y) and expand to if (y) if (x) ... where y may be undefined when !x. After a few jumps we end up in the same place, but that seems impossible for valgrind to handle.