| 349 | } |
| 350 | |
| 351 | static void ErrorSchemeStatusNoInline( |
| 352 | benchmark::State& state) { // NOLINT non-const reference |
| 353 | auto integers = RandomIntegers(); |
| 354 | |
| 355 | for (auto _ : state) { |
| 356 | int64_t total = 0; |
| 357 | for (const auto v : integers) { |
| 358 | int32_t value; |
| 359 | if (ARROW_PREDICT_TRUE(ErrorAsStatusNoInline(v, &value).ok())) { |
| 360 | total = Accumulate(total, value); |
| 361 | } |
| 362 | } |
| 363 | benchmark::DoNotOptimize(total); |
| 364 | } |
| 365 | |
| 366 | state.SetItemsProcessed(state.iterations() * integers.size()); |
| 367 | } |
| 368 | |
| 369 | static void ErrorSchemeResult(benchmark::State& state) { // NOLINT non-const reference |
| 370 | auto integers = RandomIntegers(); |
nothing calls this directly
no test coverage detected