HORIZON HASKELLDocslts/ghc-9.10.x248f8f02026-10-05Search names, modules, packages, or :: a typeCtrl K

GHC 9.10.3 · lts/ghc-9.10.x · 248f8f0 · 2026-10-05

Modulebase-4.20.2.0Haskell2010

GHC.Stats

This module provides access to internal garbage collection and memory usage statistics. These statistics are not available unless a program is run with the -T RTS flag.

The API of this module is unstable and is tightly coupled to GHC's internals. If depend on it, make sure to use a tight upper bound, e.g., base < 4.X rather than base < 5, because the interface can change rapidly without much warning.

  • 3 types
  • 2 values
  • Packagebase-4.20.2.0
  • Exports5
  • LanguageHaskell2010
  • LicenceBSD-3-Clause
  • SourceStats.hs

Runtime statistics

5 declarations
datadata RTSStats
#

Statistics about runtime activity since the start of the program. This is a mirror of the C struct RTSStats in RtsAPI.h

Constructors

Instances4Read, Show, Generic, Rep
datadata GCDetails
#

Statistics about a single GC. This is a mirror of the C struct GCDetails in RtsAPI.h, with the field prefixed with gc_ to avoid collisions with RTSStats.

Constructors

Instances4Read, Show, Generic, Rep
typetype RtsTime = Int64
#

Time values from the RTS, using a fixed resolution of nanoseconds.