[Git][ghc/ghc][master] rts: eras profiling mode

Marge Bot (@marge-bot) gitlab at gitlab.haskell.org
Sat Feb 10 19:30:54 UTC 2024



Marge Bot pushed to branch master at Glasgow Haskell Compiler / GHC


Commits:
b0293f78 by Matthew Pickering at 2024-02-10T14:29:28-05:00
rts: eras profiling mode

The eras profiling mode is useful for tracking the life-time of
closures. When a closure is written, the current era is recorded in the
profiling header. This records the era in which the closure was created.

* Enable with -he
* User mode: Use functions ghc-experimental module GHC.Profiling.Eras to modify the era
* Automatically: --automatic-era-increment, increases the user era on major
  collections
* The first era is era 1
* -he<era> can be used with other profiling modes to select a specific
  era

If you just want to record the era but not to perform heap profiling you
can use `-he --no-automatic-heap-samples`.

https://well-typed.com/blog/2024/01/ghc-eras-profiling/

Fixes #24332

- - - - -


30 changed files:

- compiler/GHC/Cmm/Parser.y
- compiler/GHC/StgToCmm/Prof.hs
- docs/users_guide/profiling.rst
- libraries/ghc-experimental/ghc-experimental.cabal
- − libraries/ghc-experimental/src/Dummy.hs
- + libraries/ghc-experimental/src/GHC/Profiling/Eras.hs
- libraries/ghc-internal/src/GHC/Profiling.hs
- rts/CloneStack.c
- rts/Continuation.c
- rts/Heap.c
- rts/Interpreter.c
- rts/LdvProfile.h
- rts/Messages.c
- rts/PrimOps.cmm
- rts/ProfHeap.c
- rts/ProfHeap.h
- rts/Profiling.c
- rts/RaiseAsync.c
- rts/RtsAPI.c
- rts/RtsFlags.c
- rts/RtsFlags.h
- rts/RtsSymbols.c
- rts/STM.c
- rts/Schedule.c
- rts/ThreadLabels.c
- rts/Threads.c
- rts/Updates.h
- rts/Weak.c
- rts/eventlog/EventLog.c
- rts/include/rts/EventLogFormat.h


The diff was not included because it is too large.


View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/b0293f78cb6acf2540389e22bdda420d0ab874da

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/commit/b0293f78cb6acf2540389e22bdda420d0ab874da
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20240210/2de4da1d/attachment-0001.html>


More information about the ghc-commits mailing list