(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.target/
powerpc/
pr98952.c
       1  /* { dg-do run { target { powerpc*-*-linux* && ilp32 } } } */
       2  /* { dg-options "-O2" } */
       3  
       4  /* PR 96983 reported that the test in libgcc's tramp.S was backwards and it
       5     would abort if the trampoline size passed to the function was greater than
       6     the size the runtime was expecting (40).  It should abort if the size is less
       7     than 40, not greater than 40.  This test creates a call to __trampoline_setup
       8     with a much larger buffer to make sure the function does not abort.
       9  
      10     We do not run this test on 64-bit since __trampoline_setup is not present in
      11     64-bit systems.
      12  
      13     We only run the test under Linux in case the other systems have some
      14     different variant for __trampoline_setup.  */
      15  
      16  #ifndef SIZE
      17  #define SIZE 100
      18  #endif
      19  
      20  extern void __trampoline_setup (int *, unsigned, void *, void *);
      21  
      22  int main (void)
      23  {
      24    int tramp[SIZE / sizeof (int)];
      25  
      26    __trampoline_setup (tramp, SIZE, 0, 0);
      27    return 0;
      28  }