Reflow some wording. NFC

This commit is contained in:
Eric Fiselier 2016-05-24 15:21:41 -06:00
parent bdeb38718e
commit 924b8cee7a
2 changed files with 11 additions and 10 deletions

View File

@ -311,11 +311,12 @@ BENCHMARK_REGISTER_F(MyFixture, BarTest)->Threads(2);
## Exiting Benchmarks in Error
When external influences such as file I/O and network errors occur within
a benchmark the `State::SkipWithError(const char* msg)` function can be used
to skip that run of benchmark and report the error. Note that only future
iterations of the `KeepRunning()` are skipped. Users may explicitly return
to exit the benchmark immediately.
When errors caused by external influences, such as file I/O and network
communication, occur within a benchmark the
`State::SkipWithError(const char* msg)` function can be used to skip that run
of benchmark and report the error. Note that only future iterations of the
`KeepRunning()` are skipped. Users may explicitly return to exit the
benchmark immediately.
The `SkipWithError(...)` function may be used at any point within the benchmark,
including before and after the `KeepRunning()` loop.

View File

@ -269,7 +269,7 @@ public:
}
// REQUIRES: timer is running and 'SkipWithError(...)' has not been called
// in the current thread.
// by the current thread.
// Stop the benchmark timer. If not called, the timer will be
// automatically stopped after KeepRunning() returns false for the first time.
//
@ -284,7 +284,7 @@ public:
void PauseTiming();
// REQUIRES: timer is not running and 'SkipWithError(...)' has not been called
// in the current thread.
// by the current thread.
// Start the benchmark timer. The timer is NOT running on entrance to the
// benchmark function. It begins running after the first call to KeepRunning()
//
@ -298,15 +298,15 @@ public:
// within each benchmark iteration, if possible.
void ResumeTiming();
// REQUIRES: 'SkipWithError(...)' has not been called previously in the
// REQUIRES: 'SkipWithError(...)' has not been called previously by the
// current thread.
// Skip any future iterations of the 'KeepRunning()' loop in the current
// thread and report an error with the specified 'msg'. After this call
// the user may explicitly 'return' from the benchmark.
//
// For threaded benchmarks only the current thread stops executing. If
// multiple threads report an error only the first error message will be used.
// The current thread is no longer considered 'active' thread by
// multiple threads report an error only the first error message is used.
// The current thread is no longer considered 'active' by
// 'PauseTiming()' and 'ResumingTiming()'.
//
// NOTE: Calling 'SkipWithError(...)' does not cause the benchmark to exit