aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/include
diff options
context:
space:
mode:
authorCalvin Rose <calsrose@gmail.com>2025-05-16 18:03:32 -0500
committerCalvin Rose <calsrose@gmail.com>2025-05-16 18:26:43 -0500
commita8e2c8e5b8aee67da562d8a3a87aee5b3b403005 (patch)
tree8c3977a5c8dbc38eb0ded3691e1797971dcfc9ed /src/include
parentAllow configuration of JANET_THREAD_LOCAL. Address #1595 (diff)
Address #1596 - Use atomic intrinsics to check allow_interrupt flag.
Use a relaxed memory order if possible to mitigate performance issues as much as possible. relaxed memory order should be sufficient.
Diffstat (limited to 'src/include')
-rw-r--r--src/include/janet.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/include/janet.h b/src/include/janet.h
index 8e6ca968..74d0661f 100644
--- a/src/include/janet.h
+++ b/src/include/janet.h
@@ -667,6 +667,7 @@ typedef int32_t JanetAtomicInt;
JANET_API JanetAtomicInt janet_atomic_inc(JanetAtomicInt volatile *x);
JANET_API JanetAtomicInt janet_atomic_dec(JanetAtomicInt volatile *x);
JANET_API JanetAtomicInt janet_atomic_load(JanetAtomicInt volatile *x);
+JANET_API JanetAtomicInt janet_atomic_load_relaxed(JanetAtomicInt volatile *x);
/* We provide three possible implementations of Janets. The preferred
* nanboxing approach, for 32 or 64 bits, and the standard C version. Code in the rest of the