Sort out "bytes allocated" runtime metric fluctuations in compiler
Currently we need to tweak compiler perf test results constantly because of fluctuation in "bytes allocated" metric. Examples:
- d46a72e1 is a comments-only change that updates perf numbers of 8 tests
!1747 (closed) is a change in compacting GC (the only change is in
Compact.c) that causes different "bytes allocated" in compiler perf tests. On CI compiler allocates more than before, locally I observe that it allocates less than before. This change should not effect mutators at all and "bytes allocated" should remain the same.
!2842 (comment 261785) (8822bbc1) suffers from a commit landing on master that apparently improved some tests (like
T5837), so that all folowing commits regress again.
- (add more here)
We should find out why the numbers are changing in compiler itself and fix it.
Some related issues:
- #17654 shows that same invocation of GHC results in different "bytes allocated" numbers
- #8611 (closed) a nofib program with changing allocations in each run.
- #16065 (closed) stack squeezing in context switch causing different "bytes allocated" numbers
-V0(disables timer, makes context switches more deterministic)
-Z(disables stack squeezing on context switch, see this for how this effects allocations)
- Account for stack space (or more generally, RTS allocations) separately from mutator allocations.
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information