Debian Codegraph @

gcc/testsuite/gcc.target/arm/pr69245.c

raw
1 /* PR target/69245 */
2 /* Test that pop_options restores the vfp fpu mode. */
3 /* { dg-do compile } */
4 /* { dg-require-effective-target arm_neon_ok } */
5 /* { dg-require-effective-target arm_fp_ok } */
6 /* { dg-options "-O2" } */
7 /* { dg-add-options arm_fp } */
8
9 #pragma GCC target "fpu=vfp"
10
11 #pragma GCC push_options
12 #pragma GCC target "fpu=neon-vfpv4"
13 int a, c, d;
14 float b;
15 int fn1 ()
16 {
17 return 0;
18 }
19 #pragma GCC pop_options
20
21 void fn2 ()
22 {
23 d = b * c + a;
24 }
25
26 /* Because we don't know the exact command-line options used to invoke the test
27 we cannot expect these tests to match exactly once. But they must appear at
28 least once. */
29 /* { dg-final { scan-assembler "\.fpu\\s+vfp\n" } } */
30 /* { dg-final { scan-assembler "\.fpu\\s+neon-vfpv4\n" } } */