(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
tree-ssa/
20030807-1.c
       1  /* { dg-do compile } */
       2  /* { dg-options "-O1 -fdump-tree-dom2" } */
       3      
       4  struct rtx_def;
       5  typedef struct rtx_def *rtx;
       6  
       7  
       8  
       9  union rtunion_def
      10  {
      11    int rtint;
      12  };
      13  typedef union rtunion_def rtunion;
      14  
      15  
      16  
      17  struct rtx_def
      18  {
      19    rtunion fld[1];
      20  
      21  };
      22  
      23  static int *uid_cuid;
      24  static int max_uid_cuid;
      25  int insn_cuid (rtx);
      26  
      27  rtx
      28  bar (rtx r)
      29  {
      30    rtx place = r;
      31  
      32    if (place->fld[0].rtint <= max_uid_cuid
      33        && (place->fld[0].rtint > max_uid_cuid ? insn_cuid (place) :
      34  	  uid_cuid[place->fld[0].rtint]))
      35      return r;
      36    
      37    return 0;
      38  }
      39  
      40  /* There should be two IF conditionals.  One tests <= max_uid_cuid, the
      41     other tets the value in uid_cuid.  If either is false the jumps
      42     are threaded to the return 0.  Which in turn means the path
      43     which combines the result of those two tests into a new test
      44     must always be true and it is optimized appropriately.  */
      45  /* { dg-final { scan-tree-dump-times "if " 2 "dom2"} } */