Skip to content

testing: support pausing cpu profiling in benchmarks #8213

Closed

Description

@masiulaniec
The benchmarking part of the "testing" package supports stopping timers while
performing complex initialisation. Perhaps something analogous could be added for cpu
profiling, so that -cpuprofile can produce a data file that excludes samples for the
complex initialisation.

The current workaround is to avoid -cpuprofile in favour of calling
runtime.StartCPUProfile from within the benchmark.

Activity

  1. griesemer commented on Oct 1, 2014

    @griesemer
    Contributor

    Comment 1:

    Labels changed: added repo-main.

  2. rsc commented on Apr 10, 2015

    @rsc
    Contributor

    This is infeasible.

  3. locked and limited conversation to collaborators on Jun 25, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions