Enable -fworker-wrapper-cbv on ghc-9.4#1003
Conversation
This flag allows for some significant perf improvements and the downsides don't apply to containers. In particular this flag can cause rules to not fire *if* the relevant functions don't have NOINLINE pragmas. However the relevant functions in containers seem to have such a pragma so there should be no downside.
|
For reference I benchmarked this using 9.10 on a skylake machine. If others could try to reproduce these results I would be grateful. |
|
There is a segfault on 9.4.8, weirdly enough I'm not yet sure it has anything to do with this flag. In particular ghc segfaults when building the Main.hs of the seq-properties tests: I opened a ghc ticket. |
|
Sadly seems there is a ghc bug in 9.4+ that causes the segfault. So I will let this rest until new point releases which contain a fix have been released. |
|
Is the GHC issue fixed? If not, why don't we just enable the flag on >= 9.6? |
I believe 9.10.1 does not yet have the fix but 9.10.2 isn't far away and contains it. Once that is out all recent ghc versions will have it. Here is the upstream ticket: https://gitlab.haskell.org/ghc/ghc/-/issues/24870 |
This flag allows for some significant perf improvements and the downsides don't apply to containers.
In particular this flag can cause rules to not fire if the relevant functions don't have NOINLINE pragmas. However the relevant functions in containers seem to have such a pragma so there should be no downside.
Here are the results for map-benchmarks: