diff options
author | Jakob Kaivo <jkk@ung.org> | 2024-05-29 16:58:17 -0400 |
---|---|---|
committer | Jakob Kaivo <jkk@ung.org> | 2024-05-29 16:58:17 -0400 |
commit | 3d00af92d2993e5fbf237e2c81b499058c21a650 (patch) | |
tree | 3e0bf27161dc8311165d071a62757356fb1985f0 | |
parent | b321e5a295074bba7e8ba52785a63bdc40c37878 (diff) |
apply GCC_SSE_HACK more uniformly
-rw-r--r-- | src/_safety.h | 2 | ||||
-rw-r--r-- | src/signal/sigaction.c | 1 | ||||
-rw-r--r-- | src/stdio/_stdio.h | 2 | ||||
-rw-r--r-- | src/stdlib/__jkmalloc.c | 1 |
4 files changed, 4 insertions, 2 deletions
diff --git a/src/_safety.h b/src/_safety.h index 85637013..3fb3a66e 100644 --- a/src/_safety.h +++ b/src/_safety.h @@ -3,6 +3,8 @@ _Noreturn void __undefined(const char *, ...); +#define GCC_SSE_HACK __attribute__((noinline, target("no-sse"))) + #include <errno.h> #include <stdlib.h> #include <stdio.h> diff --git a/src/signal/sigaction.c b/src/signal/sigaction.c index d4721538..3aa41b49 100644 --- a/src/signal/sigaction.c +++ b/src/signal/sigaction.c @@ -3,6 +3,7 @@ #include "_syscall.h" #include "_safety.h" +GCC_SSE_HACK int sigaction(int sig, const struct sigaction * restrict act, struct sigaction * restrict oact) { SIGNAL_SAFE(-1); diff --git a/src/stdio/_stdio.h b/src/stdio/_stdio.h index 6302ee83..80e25546 100644 --- a/src/stdio/_stdio.h +++ b/src/stdio/_stdio.h @@ -20,8 +20,6 @@ #define f_is_open(s) (s && (s->bmode != 0)) -#define GCC_SSE_HACK __attribute__((noinline, target("no-sse"))) - #define ORIENT_WIDE (1) #define ORIENT_BYTE (-1) diff --git a/src/stdlib/__jkmalloc.c b/src/stdlib/__jkmalloc.c index e21baffd..c7a5685b 100644 --- a/src/stdlib/__jkmalloc.c +++ b/src/stdlib/__jkmalloc.c @@ -182,6 +182,7 @@ static void __jk_sigaction(int sig, siginfo_t *si, void *addr) __jk_error(NULL, NULL, &src); } +GCC_SSE_HACK void* __jkmalloc(void *ptr, size_t alignment, size_t size1, size_t size2, const char *user) { static int sa_set = 0; |