1 /* { dg-do compile } */
2 /* { dg-options -O2 } */
4 /* Check that we finish compiling even if instructed to
5 flatten a cyclic callgraph. Verify we correctly
6 flatten with another function marked flatten in the
9 void __attribute__((flatten
)) direct(void)
15 void __attribute__((flatten
)) indirect(void);
16 static void indirect1(void)
20 void __attribute__((flatten
)) indirect(void)
26 void __attribute__((flatten
)) doubleindirect(void);
27 static void doubleindirect2(void)
31 static void doubleindirect1(void)
35 void __attribute__((flatten
)) doubleindirect(void)
41 static void subcycle1(void);
42 static void subcycle2(void)
46 static void subcycle1(void)
50 void __attribute__((flatten
)) subcycle(void)
56 static void doublesubcycle1(void);
57 static void doublesubcycle2(void);
58 static void doublesubcycle3(void)
62 static void doublesubcycle2(void)
66 static void doublesubcycle1(void)
70 void __attribute__((flatten
)) doublesubcycle(void)
75 /* { dg-final { scan-assembler "cycle\[123\]\[: \t\n\]" } } */
76 /* { dg-final { scan-assembler-not "indirect\[12\]\[: \t\n\]" } } */