• alexbiehl's avatar
    Abstract over the way eventlogs are flushed · 4dfc6d1c
    alexbiehl authored
    Currently eventlog data is always written to a file `progname.eventlog`.
    This patch introduces the `flushEventLog` field in `RtsConfig` which
    allows to customize the writing of eventlog data.
    One possible scenario is the ongoing live-profile-monitor effort by
    @NCrashed which slurps all eventlog data through `fluchEventLog`.
    `flushEventLog` takes a buffer with eventlog data and its size and
    returns `false` (0) in case eventlog data could not be procesed.
    Reviewers: simonmar, austin, erikd, bgamari
    Reviewed By: simonmar, bgamari
    Subscribers: qnikst, thomie, NCrashed
    Differential Revision: https://phabricator.haskell.org/D2934
Trace.c 22.4 KB