https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83565

--- Comment #29 from Jim Wilson <wilson at gcc dot gnu.org> ---
(In reply to Sergei Trofimovich from comment #28)
> 1. Is it directly visible for you from RTL dumps which bits GCC assumes as
> non-zero or you just know RTL invariants? I had to patch gcc locally to
> verify RTL prediction by adding printfs into print_pattern to get the idea
> how it works:

I stepped through combine in gdb to find the problem.

> 2. Does gcc have any validation mode that could have caught this error after
> code generation and checking against RTL invariant?

We have some compile-time and run-time checking code, but nothing that would
catch a problem like this.  We do have the regression testsuite which requires
manually adding testcases that get miscompiled, and hopefully prevents them
from getting miscompiled again.

Reply via email to