Debian Codegraph @

gcc/testsuite/gcc.dg/ipa/iinline-attr.c

raw
1 /* Verify that simple indirect calls are inlined even when
2 attribute __optimize is used. */
3 /* { dg-do compile } */
4 /* { dg-options "-O2 -fdump-ipa-inline" } */
5
6 extern void non_existent(int);
7
8 static void hooray ()
9 {
10 non_existent (1);
11 }
12
13 __attribute__ ((__optimize__ ("O2")))
14 static void hiphip (void (*f)())
15 {
16 non_existent (2);
17 f ();
18 }
19
20 int test (void)
21 {
22 hiphip (hooray);
23 return 0;
24 }
25
26 /* { dg-final { scan-ipa-dump "hooray\[^\\n\]*inline copy in test" "inline" { xfail sparc*-*-* visium-*-* } } } */
27 /* Missing back-end support for attribute __optimize__ on SPARC and Visium. */