1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18
/* { dg-do compile } */ /* { dg-require-effective-target fpic } */ /* { dg-options "-O2 -fPIC" } */ /* { dg-require-effective-target tls } */ struct initial_sp { void *sp; long len; }; __thread struct initial_sp __morestack_initial_sp; void bar (void *); void foo () { bar (&__morestack_initial_sp.len); }