2 /* { dg-do compile } */
3 /* { dg-skip-if "do not override -mfloat-abi" { *-*-* } { "-mfloat-abi=*" } {"-mfloat-abi=hard" } } */
4 /* { dg-require-effective-target arm_vfp_ok } */
5 /* { dg-add-options arm_vfp } */
6 /* Make sure with use -mfloat-abi=hard. */
7 /* { dg-additional-options "-mfloat-abi=hard" } */
9 /* Check that we emit a warning when compiling an IRQ handler without
10 -mgeneral-regs-only. */
18 /* This function may clobber VFP registers. */
19 __attribute__ ((interrupt("IRQ"))) void IRQ_HDLR_Test(void)
20 { /* { dg-warning { FP registers might be clobbered despite 'interrupt' attribute: compile with '-mgeneral-regs-only'} "" { target *-*-* } . } */
21 global_d
.fpdata
[3] += global_d
.fpdata
[3] * global_d1
.fpdata
[3];
24 /* This function does not need to clobber VFP registers. */
25 /* Do we want to emit a (useless?) warning? */
26 __attribute__ ((interrupt("IRQ"))) void IRQ_HDLR_Test2(void)
27 { /* { dg-warning { FP registers might be clobbered despite 'interrupt' attribute: compile with '-mgeneral-regs-only'} "" { target *-*-* } . } */
28 global_d
.fpdata
[3] = 1.0;