A question about user guide README -> Customer Counter

16 views
Skip to first unread message

Jigao Luo

unread,
Nov 5, 2021, 11:52:00 PM11/5/21
to benchmark-discuss
My question arises from https://github.com/google/benchmark/blob/main/docs/user_guide.md#custom-counters

```
// This says that we process with the rate of state.range(0) bytes every iteration: state.counters["BytesProcessed"] = Counter(state.range(0), benchmark::Counter::kIsIterationInvariantRate, benchmark::Counter::OneK::kIs1024);
```

I don't get why state.range(0) is related to the number of bytes. It seems a input parameter.
Reply all
Reply to author
Forward
0 new messages