on master help sign in
Add the -fdicts-strict flag to avoid memory leaks
1987b9eHarendra Kumar
docs/Build.md+5−1
@@ -2,7 +2,11 @@
2
2
3Recommended GHC options are:
3Recommended GHC options are:
4
4
5− `-O2 -fspec-constr-recursive=16 -fmax-worker-args=16`
5+ `-O2 -fdicts-strict -fspec-constr-recursive=16 -fmax-worker-args=16`
6+
7+`-fdicts-strict` is needed to avoid [a GHC
8+issue](https://gitlab.haskell.org/ghc/ghc/issues/17745) leading to
9+memory leak in some cases.
6
10
7`-fspec-constr-recursive` is needed for better stream fusion by enabling
11`-fspec-constr-recursive` is needed for better stream fusion by enabling
8the `SpecConstr` optimization in more cases.
12the `SpecConstr` optimization in more cases.
streamly.cabal+1
@@ -215,6 +215,7 @@ common compile-options
215
215
216common optimization-options
216common optimization-options
217 ghc-options: -O2
217 ghc-options: -O2
218+ -fdicts-strict
218 -fspec-constr-recursive=16
219 -fspec-constr-recursive=16
219 -fmax-worker-args=16
220 -fmax-worker-args=16
220
221