(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
ipa/
ipa-icf-10.c
       1  /* { dg-do compile } */
       2  /* { dg-options "-O2 -fdump-ipa-icf-optimized"  } */
       3  
       4  int ferda(int x, int y) __attribute__ ((pure));
       5  int funkce(int a, int b) __attribute__ ((pure));
       6  
       7  __attribute__ ((noinline))
       8  int ferda(int x, int y)
       9  {
      10    if (x < y)
      11      {
      12        return x;
      13      }
      14    else
      15      return y;
      16  }
      17  
      18  __attribute__ ((noinline))
      19  int funkce(int a, int b)
      20  {
      21    if(a < b)
      22      return a;
      23    else
      24      return b;
      25  }
      26  
      27  int main(int argc, char **argv)
      28  {
      29    return 0;
      30  }
      31  
      32  /* { dg-final { scan-ipa-dump "Semantic equality hit:ferda/\[0-9+\]+->funkce/\[0-9+\]+" "icf"  } } */
      33  /* { dg-final { scan-ipa-dump "Equal symbols: 1" "icf"  } } */