1/* { dg-do run } */ 2/* { dg-options "-Os -fomit-frame-pointer -mno-accumulate-outgoing-args -fno-asynchronous-unwind-tables" } */ 3 4extern void abort(void); 5 6static void *p[2]; 7 8void __attribute__((noinline)) 9g(int x, ...) 10{ 11 asm volatile ("" : : "g"(x)); 12} 13 14void __attribute__((noinline)) 15f(int x) 16{ 17 p[0] = __builtin_return_address (0); 18 if (x == 0) 19 g(0); 20 g(1, 2, 3, 4, 5, 6, 7); 21 22 asm goto ("jmp %l0" : : : : label); 23 abort (); 24 25 label: 26 p[1] = __builtin_return_address (0); 27} 28 29int main() 30{ 31 f(1); 32 if (p[0] != p[1]) 33 abort (); 34 return 0; 35} 36