From: Eli Zaretskii Date: Sun, 9 Nov 2014 15:57:37 +0000 (+0200) Subject: Fix bug #18995 with compiling w32heap.c with -funroll-loops. X-Git-Tag: emacs-24.4.90~242 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=2ae1e0d427eaf8583875a31525eca42c0a9ebb99;p=emacs.git Fix bug #18995 with compiling w32heap.c with -funroll-loops. src/w32heap.c (allocate_heap): Set the lower limit of heap at 8MB. --- diff --git a/src/ChangeLog b/src/ChangeLog index 0f9ef11c9d7..c03218c21f9 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2014-11-09 Eli Zaretskii + + * w32heap.c (allocate_heap): Set the lower limit of heap at 8MB. + (Bug#18995) + 2014-11-09 Jan Djärv * nsterm.h (EmacsScroller): judge returns bool. diff --git a/src/w32heap.c b/src/w32heap.c index 8ab2f58c6e7..4367f710643 100644 --- a/src/w32heap.c +++ b/src/w32heap.c @@ -96,7 +96,7 @@ static char * allocate_heap (void) { #ifdef _WIN64 - size_t size = 0x4000000000ull; /* start by asking for 32GB */ + size_t size = 0x4000000000ull; /* start by asking for 256GB */ #else /* We used to start with 2GB here, but on Windows 7 that would leave too little room in the address space for threads started by @@ -106,7 +106,7 @@ allocate_heap (void) #endif void *ptr = NULL; - while (!ptr && size > 0x00100000) + while (!ptr && size >= 0x00800000) { reserved_heap_size = size; ptr = VirtualAlloc (NULL,