(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
builtin-apply4.c
       1  /* PR tree-optimization/20076 */
       2  /* { dg-options "-O2 -Wmissing-noreturn -fgnu89-inline" } */
       3  /* { dg-additional-options "-mno-mmx" { target { { i?86-*-* x86_64-*-* } && ia32 } } } */
       4  /* { dg-do run } */
       5  /* { dg-require-effective-target untyped_assembly } */
       6  /* { dg-xfail-run-if "can cause stack underflow" { amdgcn-*-* } } */
       7  
       8  extern void abort (void);
       9  
      10  double
      11  foo (int arg)
      12  {
      13    if (arg != 116)
      14      abort();
      15    return arg + 1;
      16  }
      17  
      18  inline double
      19  bar (int arg)
      20  {
      21    foo (arg);
      22    __builtin_return (__builtin_apply ((void (*) ()) foo,
      23  				     __builtin_apply_args (), 16));
      24  }
      25  
      26  int
      27  main (int argc, char **argv)
      28  {
      29    if (bar (116) != 117.0)
      30      abort ();
      31  
      32    return 0;
      33  }