-
Type:
Bug
-
Resolution: Won't Fix
-
Priority:
Not Prioritized
-
Code Generation Tools
-
CODEGEN-15635
-
ARMCLANG_5.1.0.LTS
-
default
-
The `interrupt_save_fp` function attribute should replace any use of `interrupt` on functions. Here, the presence of both attributes is resulting in the compiler seeing `interrupt` and issuing the warning.
The attached function has these lines ...
__attribute__((target("arm"), interrupt("SWI")))
__attribute__((interrupt_save_fp))
void handler(void)
{
}
Note it uses the interrupt_save_fp attribute. Build it ...
% tiarmclang -mcpu=cortex-r5 -c file.c
file.c:3:6: warning: interrupt service routine with vfp enabled may clobber the
interruptee's vfp state; consider using the `interrupt_save_fp` attribute
to prevent this behavior [-Warm-interrupt-vfp-clobber]
3 | void handler(void)
| ^
1 warning generated.