2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
[official-gcc.git] / gcc / testsuite / gcc.target / arm / attr-align1.c
bloba53f16706860b69fcc60071b818fbc9f89fc33c7
1 /* PR target/67745
2 Verify alignment when both attribute optimize and target are used. */
3 /* { dg-do compile } */
4 /* { dg-skip-if "" { ! { arm_thumb1_ok || arm_thumb2_ok } } } */
5 /* { dg-skip-if "" arm_cortex_m } */
7 void
8 __attribute__ ((target ("arm")))
9 bar()
13 void
14 __attribute__ ((target ("thumb")))
15 __attribute__ ((optimize ("Os")))
16 foo()
20 void
21 __attribute__ ((target ("thumb")))
22 __attribute__ ((optimize ("O2")))
23 rab()
27 /* { dg-final { scan-assembler-times ".align\[ \t]2" 2 } } */
28 /* { dg-final { scan-assembler ".align\[ \t]1" } } */