1  /* { dg-do run } */
       2  /* { dg-options "-O2 -march=i686 -mtune=generic -fstack-clash-protection" } */
       3  /* { dg-require-effective-target ia32 } */
       4  
       5  __attribute__ ((noinline, noclone, weak, regparm (3)))
       6  int
       7  f1 (long arg0, int (*pf) (long, void *))
       8  {
       9    unsigned char buf[32768];
      10    return pf (arg0, buf);
      11  }
      12  
      13  __attribute__ ((noinline, noclone, weak))
      14  int
      15  f2 (long arg0, void *ignored)
      16  {
      17    if (arg0 != 17)
      18      __builtin_abort ();
      19    return 19;
      20  }
      21  
      22  int
      23  main (void)
      24  {
      25    if (f1 (17, f2) != 19)
      26      __builtin_abort ();
      27    return 0;
      28  }
      29  
      30