aboutsummaryrefslogtreecommitdiffstats
path: root/coroutine
diff options
context:
space:
mode:
Diffstat (limited to 'coroutine')
-rw-r--r--coroutine/arm32/Context.h1
-rw-r--r--coroutine/copy/Context.h4
-rw-r--r--coroutine/ucontext/Context.h4
-rw-r--r--coroutine/win32/Context.h1
-rw-r--r--coroutine/x86/Context.h1
5 files changed, 11 insertions, 0 deletions
diff --git a/coroutine/arm32/Context.h b/coroutine/arm32/Context.h
index 27f97908bc..e29fe1bb63 100644
--- a/coroutine/arm32/Context.h
+++ b/coroutine/arm32/Context.h
@@ -11,6 +11,7 @@
#include <string.h>
#define COROUTINE __attribute__((noreturn)) void
+#define COROUTINE_LIMITED_ADDRESS_SPACE
enum {COROUTINE_REGISTERS = 8};
diff --git a/coroutine/copy/Context.h b/coroutine/copy/Context.h
index a62efa4e8a..0b6e3a9be0 100644
--- a/coroutine/copy/Context.h
+++ b/coroutine/copy/Context.h
@@ -16,6 +16,10 @@
#define COROUTINE __attribute__((noreturn)) void
+#if INTPTR_MAX <= INT32_MAX
+#define COROUTINE_LIMITED_ADDRESS_SPACE
+#endif
+
// This stack copying implementation which uses a private stack for each coroutine, including the main one.
#define COROUTINE_PRIVATE_STACK
diff --git a/coroutine/ucontext/Context.h b/coroutine/ucontext/Context.h
index bde9be302a..6cf16c8604 100644
--- a/coroutine/ucontext/Context.h
+++ b/coroutine/ucontext/Context.h
@@ -13,6 +13,10 @@
#define COROUTINE __attribute__((noreturn)) void
+#if INTPTR_MAX <= INT32_MAX
+#define COROUTINE_LIMITED_ADDRESS_SPACE
+#endif
+
struct coroutine_context
{
ucontext_t state;
diff --git a/coroutine/win32/Context.h b/coroutine/win32/Context.h
index fe1a8a3648..c70b65cd2f 100644
--- a/coroutine/win32/Context.h
+++ b/coroutine/win32/Context.h
@@ -11,6 +11,7 @@
#include <string.h>
#define COROUTINE __declspec(noreturn) void __fastcall
+#define COROUTINE_LIMITED_ADDRESS_SPACE
/* This doesn't include thread information block */
enum {COROUTINE_REGISTERS = 4};
diff --git a/coroutine/x86/Context.h b/coroutine/x86/Context.h
index a783dd296f..6d3a56eaa6 100644
--- a/coroutine/x86/Context.h
+++ b/coroutine/x86/Context.h
@@ -11,6 +11,7 @@
#include <string.h>
#define COROUTINE __attribute__((noreturn, fastcall)) void
+#define COROUTINE_LIMITED_ADDRESS_SPACE
enum {COROUTINE_REGISTERS = 4};