haskell / haskell/containers

Flag adjustments for GHC-9.4 and tag inference.

Open
#827 2 comments 2 reactions 0 assignees View on GitHub
performance
Dominant language
Haskell
Stars
355
Forks
194
Avg merge
3d 4h
Merged PRs (30d)
4

Description

In ghc-9.4 the tag inference optimization finally landed. This is great news for containers as it was one of the main motivations for this optimization. And just by using the new GHC container performance should improve.

However in order to get the most out of this containers should enable `-fworker-wrapper-cbv` for most, or all of it's modules.

There are some edge cases around W/W + RULES why `-fworker-wrapper-cbv` can't be on by default in 9.4. but I think these are not very relevant for containers and even when they occur downstream users can fix any resulting RULE breakage by proper use of `INLINE[ABLE].`

* When I benchmarked it enabling this flag for all of containers was a benefit for ghc.
* In the container benchmarks it was giving a ~10% improvement on many operations when enabled.

9.4 isn't out yet. But to avoid this falling by the wayside I'm opening this issue now.

Contributor guide

Open the contributing guide

Research direction

Start by locating the repository’s GHC option or module configuration and the container benchmarks mentioned in the issue. Check how GHC 9.4 applies -fworker-wrapper-cbv, enable it for the relevant modules, and use the benchmarks to verify the expected performance change while checking for RULES breakage.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
performance
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.