Opened 10 years ago

Closed 10 years ago

#3502 closed bug (fixed)

GC leaks memory under -threaded

Reported by: NeilMitchell Owned by:
Priority: high Milestone: 6.12.1
Component: Runtime System Version: 6.10.4
Keywords: Cc: ndmitchell@…, lennart@…
Operating System: Windows Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:


The following program leaks 2Mb/s under Windows:

$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 6.10.4
$ cat Test.hs
import System.Mem
import Control.Monad
main = forever performGC
$ ghc --make Test.hs -threaded
$ Test.exe

This leak does not occur if you remove the -threaded, or if you run the same test on Linux. I am using forever to leak memory more quickly, but I believe the same issues will arise if performGC is called in the normal course of a program.

I consider this leak to be critical, so have marked severity appropriately.

Change History (2)

comment:1 Changed 10 years ago by simonmar

difficulty: Unknown
Milestone: 6.12.1
Priority: normalhigh

Fairly sure this one is fixed, see

but I'll check for 6.12.1 anyway.

comment:2 Changed 10 years ago by simonmar

Resolution: fixed
Status: newclosed

Tested; it's flat now.

Note: See TracTickets for help on using tickets.