Skip to content

Program.Benchmark should take a testing.B #1907

@ti-mo

Description

@ti-mo

Let's go ahead with converting Program.Benchmark() to take a testing.B instead, since it feels pointless to break API twice if we're planning on doing that anyway. When we make this conversion, we can hide Reset() from the caller and report our own metric, e.g. retries to both make sure retries don't go unnoticed and don't need to be handled explicitly by the user.

Then the retries argument also becomes unnecessary as we can take b.N as the value to RunOptions.Repeat.

Originally posted by @ti-mo in #1894 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions