| 1 |
/* PR target/94743 */ |
| 2 |
/* { dg-do compile } */ |
| 3 |
/* Thumb1 mode not supported for interrupt routines. */ |
| 4 |
/* { dg-require-effective-target arm32 } */ |
| 5 |
/* { dg-options "-mgeneral-regs-only" } */ |
| 6 |
|
| 7 |
/* Check that we do not emit a warning when compiling an IRQ handler |
| 8 |
with -mgeneral-regs-only. */ |
| 9 |
typedef struct { |
| 10 |
/* Do not use floating-point types, which are not compatible with |
| 11 |
-mgeneral-regs-only under -mfloat-abi=hard */ |
| 12 |
int fpdata[32]; |
| 13 |
} dummy_t; |
| 14 |
|
| 15 |
dummy_t global_d; |
| 16 |
dummy_t global_d1; |
| 17 |
|
| 18 |
/* This function does not clobber VFP registers. */ |
| 19 |
__attribute__ ((interrupt("IRQ"))) void IRQ_HDLR_Test(void) |
| 20 |
{ |
| 21 |
global_d.fpdata[3] += global_d.fpdata[3] * global_d1.fpdata[3]; |
| 22 |
} |