Repository : ssh://darcs.haskell.org//srv/darcs/ghc On branch : ghc-7.6
http://hackage.haskell.org/trac/ghc/changeset/b3b611d9e6a7608f0d8e955d59a4a35c9867bdd3 >--------------------------------------------------------------- commit b3b611d9e6a7608f0d8e955d59a4a35c9867bdd3 Author: Simon Marlow <[email protected]> Date: Fri Sep 7 13:35:16 2012 +0100 When using -H with -M<size>, don't exceed the maximum heap size MERGED from commit 4d208aed2f433cd2f46a7df016bad50af2e07e40 >--------------------------------------------------------------- rts/sm/GC.c | 6 +++++- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/rts/sm/GC.c b/rts/sm/GC.c index c742fde..21b80ea 100644 --- a/rts/sm/GC.c +++ b/rts/sm/GC.c @@ -1570,7 +1570,11 @@ resize_generations (void) RtsFlags.GcFlags.minOldGenSize); if (RtsFlags.GcFlags.heapSizeSuggestionAuto) { - RtsFlags.GcFlags.heapSizeSuggestion = size; + if (max > 0) { + RtsFlags.GcFlags.heapSizeSuggestion = stg_min(max, size); + } else { + RtsFlags.GcFlags.heapSizeSuggestion = size; + } } // minimum size for generation zero _______________________________________________ Cvs-ghc mailing list [email protected] http://www.haskell.org/mailman/listinfo/cvs-ghc
