From 42285566893e0296e6def8a769c10a94042a974c Mon Sep 17 00:00:00 2001 From: sof Date: Fri, 31 Oct 2003 16:22:11 +0000 Subject: [PATCH] [project @ 2003-10-31 16:22:11 by sof] Report max heap in Mbytes as well. merge to stable --- ghc/rts/hooks/OutOfHeap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ghc/rts/hooks/OutOfHeap.c b/ghc/rts/hooks/OutOfHeap.c index ec02a7f..587587b 100644 --- a/ghc/rts/hooks/OutOfHeap.c +++ b/ghc/rts/hooks/OutOfHeap.c @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: OutOfHeap.c,v 1.4 2002/07/17 09:21:51 simonmar Exp $ + * $Id: OutOfHeap.c,v 1.5 2003/10/31 16:22:11 sof Exp $ * * User-overridable RTS hooks. * @@ -14,7 +14,7 @@ OutOfHeapHook (lnat request_size, lnat heap_size) /* both sizes in bytes */ /* fprintf(stderr, "Heap exhausted;\nwhile trying to allocate %lu bytes in a %lu-byte heap;\nuse `+RTS -H' to increase the total heap size.\n", */ (void)request_size; /* keep gcc -Wall happy */ - fprintf(stderr, "Heap exhausted;\nCurrent maximum heap size is %lu bytes;\nuse `+RTS -M' to increase it.\n", - heap_size); + fprintf(stderr, "Heap exhausted;\nCurrent maximum heap size is %lu bytes (%lu Mb);\nuse `+RTS -M' to increase it.\n", + heap_size, heap_size / (1024*1024)); } -- 1.7.10.4