diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2024-07-26 00:23:58 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2024-07-26 00:23:58 +0000 |
commit | d0a1005038916a8061ca63e589ff6f27d5aeb8ec (patch) | |
tree | 00a7ed29b7d57d7c48467f7ed499576760e67b6c /sys | |
parent | d9eba3ac01073ff290d4700c983c03a8b08609ef (diff) |
use the fp target attribute with fpu_save()/fpu_load()
otherwise clang 18 errors when inline assembly uses floating point
registers with nofp in -march
ok kettenis@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/arm64/arm64/fpu.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/arch/arm64/arm64/fpu.c b/sys/arch/arm64/arm64/fpu.c index 0285ef78558..a50cf631968 100644 --- a/sys/arch/arm64/arm64/fpu.c +++ b/sys/arch/arm64/arm64/fpu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fpu.c,v 1.1 2022/01/01 18:52:36 kettenis Exp $ */ +/* $OpenBSD: fpu.c,v 1.2 2024/07/26 00:23:57 jsg Exp $ */ /* * Copyright (c) 2022 Mark Kettenis <kettenis@openbsd.org> * @@ -22,6 +22,7 @@ #include <machine/armreg.h> +__attribute__((target("+fp"))) void fpu_save(struct proc *p) { @@ -74,6 +75,7 @@ fpu_save(struct proc *p) fp->fp_cr = READ_SPECIALREG(fpcr); } +__attribute__((target("+fp"))) void fpu_load(struct proc *p) { |