blob: 273433ceed5e60113cbbac36279b3b3ad6e10848 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
/* { dg-do compile } */
/* { dg-options "-O2 -mlong-calls" } */
/* { dg-final { scan-assembler-times "\\tcall\[p\]*\[\\t ]*.s" 3 } } */
/* { dg-final { scan-assembler "call\[p\]*\[\\t ]*.s.\[\\t ]*.f" } } */
/* { dg-final { scan-assembler-not "call\[p\]*\[\\t ]*.s.\[\\t ]*.g" } } */
/* { dg-final { scan-assembler-not "call\[p\]*\[\\t ]*.s.\[\\t ]*.h" } } */
int x;
static __attribute__ ((noinline)) void f ()
{
x = 5;
}
extern void g ();
static __attribute__ ((noinline)) __attribute__((section(".init.text"))) void h ()
{
x = 5;
}
int bar ()
{
f ();
g ();
h ();
}
|