Skip to content

Only one function out of first 100 functions has location info in eventlog2html display of a test run of a program

Summary

Only one function out of first 100 functions has location info in eventlog2html display of a test run of a program.

This only happens when -fspecialise-aggressively is disabled, so possibly the bug affects not specialized functions (which in this compilation mode leak memory like crazy and so take up the first 100 spots and more).

Steps to reproduce

With this package version

https://hackage.haskell.org/package/LambdaHack-0.11.0.0

or equivalently this repo's tag

https://github.com/LambdaHack/LambdaHack/tree/v0.11.0.0

build

cabal build -w ghc-9.2.1 --allow-newer=sdl2:bytestring --ghc-options="-finfo-table-map -fdistinct-constructor-tables -eventlog -fexpose-all-unfoldings -fsimpl-tick-factor=200" -f-with_costly_optimizations

(the only effect of the last three flags is to disable -fspecialise-aggressively)

and run

dist-newstyle/build/x86_64-linux/ghc-9.2.1/LambdaHack-0.11.0.0/x/LambdaHack/build/LambdaHack/LambdaHack  --dbgMsgSer --logPriority 4 --newGame 1 --noAnim --maxFps 100000 --frontendLazy --benchmark --dumpInitRngs --automateAll --keepAutomated --gameMode crawl --assertExplored 5 --setDungeonRng "SMGen 3028264503 3585941247" --setMainRng "SMGen 3578503194 2338645091"  --stopAfterFrames 4000 +RTS -s -hi -l-aug
eventlog2html LambdaHack.eventlog

See that only one function of dozens of initial functions has any location information.

Expected behavior

Lots of functions have location information, just as when compiling without the last three flags (and so with -fspecialise-aggressively active and so specializing all functions and eliminating the memory leaks).

Environment

  • GHC version used: 9.2.1

Optional:

  • Operating System: Ubuntu
  • System Architecture: amd64
Edited by Mikolaj Konarski
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information