From 9ee3d161f715de9e68ba60c17e3893107bb7c42a Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 2 Jul 2019 23:22:43 +0200 Subject: patch 8.1.1618: Amiga-like systems quickly run out of stack MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Problem: Amiga-like systems quickly run out of stack. Solution: Reserve a Megabyte stack. (Ola Söder, closes #4608) --- src/os_amiga.c | 11 +++++++++++ src/version.c | 2 ++ 2 files changed, 13 insertions(+) diff --git a/src/os_amiga.c b/src/os_amiga.c index 6b8eddb55..94355b81c 100644 --- a/src/os_amiga.c +++ b/src/os_amiga.c @@ -60,6 +60,17 @@ #endif /* PROTO */ +/* + * Set stack size to 1 MiB on NG systems. This should be enough even for + * hungry syntax HL / plugin combinations. Leave the stack alone on OS 3 + * and below, those systems might be low on memory. + */ +#if defined(__amigaos4__) +static const char* __attribute__((used)) stackcookie = "$STACK: 1048576"; +#elif defined(__AROS__) || defined(__MORPHOS__) +unsigned long __stack = 1048576; +#endif + /* * At this point TRUE and FALSE are defined as 1L and 0L, but we want 1 and 0. */ diff --git a/src/version.c b/src/version.c index 35575e276..10e4c40d8 100644 --- a/src/version.c +++ b/src/version.c @@ -777,6 +777,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 1618, /**/ 1617, /**/ -- cgit v1.2.1