Repository navigation
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 |
|
Hi @AndreasPK, https://gitlab.haskell.org/ghc/ghc/-/work_items/24870 seems to be fixed and backported. Is there any other issue to be aware of, or can we start enabling the flag? |
|
I'm not aware of other open issues! |
|
Nice! Would you like to update this PR with the GHC versions that have the fix? |
|
@AndreasPK I'm hoping to get this merged and release 0.8.1 (#1186) soon. If you are a bit too busy right now, let me know if you would like me to take over. |
|
I ran a bunch of the benchmarks with GHC 9.14.1 and with the flag on/off. And I'm seeing some improvements but not in all the cases as the PR description here, which doesn't seem unreasonable since this PR is a few years old now. However this change seems to significantly degrade Seq's For vs This is probably something to be improved on the GHC side, so I will hold off on including this in 0.8.1. Edit: Opened https://gitlab.haskell.org/ghc/ghc/-/work_items/27935 |
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: