Hi! This testcase started failing with r8-2090 and works again starting with r11-4755.
Tested on x86_64-linux, committed to trunk as obvious. 2020-11-24 Jakub Jelinek <ja...@redhat.com> PR tree-optimization/97964 * gcc.dg/tree-ssa/pr97964.c: New test. --- gcc/testsuite/gcc.dg/tree-ssa/pr97964.c.jj 2020-11-24 10:41:09.855529730 +0100 +++ gcc/testsuite/gcc.dg/tree-ssa/pr97964.c 2020-11-24 10:40:52.555724821 +0100 @@ -0,0 +1,18 @@ +/* PR tree-optimization/97964 */ +/* { dg-do compile } */ +/* { dg-options "-O2 -fdump-tree-optimized" } */ +/* { dg-final { scan-tree-dump-not "link_failure \\\(\\\);" "optimized" } } */ + +void link_failure (void); + +void +foo (int a) +{ + long b = -2; + int c = a > 0; + int d = b * c; + int e = 1 - d; + int t = (-1 / e) == 1; + if (t != 0) + link_failure (); +} Jakub