]> granicus.if.org Git - vim/commitdiff
patch 8.1.1618: Amiga-like systems quickly run out of stack v8.1.1618
authorBram Moolenaar <Bram@vim.org>
Tue, 2 Jul 2019 21:22:43 +0000 (23:22 +0200)
committerBram Moolenaar <Bram@vim.org>
Tue, 2 Jul 2019 21:22:43 +0000 (23:22 +0200)
Problem:    Amiga-like systems quickly run out of stack.
Solution:   Reserve a Megabyte stack. (Ola Söder, closes #4608)

src/os_amiga.c
src/version.c

index 6b8eddb5528e2d7dbec5a95d37038c82e727d143..94355b81c75ebb14d1d83d9e45d8e51338eeefc6 100644 (file)
 
 #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.
  */
index 35575e2768e7c001fb700bb34ef2657caa2789c9..10e4c40d8ec6b8c11c26da38e1c8bb8c0aaa532b 100644 (file)
@@ -777,6 +777,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    1618,
 /**/
     1617,
 /**/