From 9b07028908b3b874cd399f54b5805aad56e53234 Mon Sep 17 00:00:00 2001 From: Lars Immisch Date: Sun, 24 Sep 2023 17:45:25 +0200 Subject: [PATCH] Expand RE_BREAKPOINT macro on ARM64 (works at least on MacOS/clang) --- include/re_types.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/re_types.h b/include/re_types.h index a3c4dba56..12c5cfe67 100644 --- a/include/re_types.h +++ b/include/re_types.h @@ -81,6 +81,8 @@ typedef SSIZE_T ssize_t; /** Defines a soft breakpoint */ #if (defined(__i386__) || defined(__x86_64__)) #define RE_BREAKPOINT __asm__("int $0x03") +#elif defined(__aarch64__) +#define RE_BREAKPOINT __builtin_debugtrap() #else #define RE_BREAKPOINT #endif