| 335 | } |
| 336 | |
| 337 | static void ErrorSchemeStatusNoInline( |
| 338 | benchmark::State& state) { // NOLINT non-const reference |
| 339 | auto integers = RandomIntegers(); |
| 340 | |
| 341 | for (auto _ : state) { |
| 342 | int64_t total = 0; |
| 343 | for (const auto v : integers) { |
| 344 | int32_t value; |
| 345 | if (ARROW_PREDICT_TRUE(ErrorAsStatusNoInline(v, &value).ok())) { |
| 346 | total = Accumulate(total, value); |
| 347 | } |
| 348 | } |
| 349 | benchmark::DoNotOptimize(total); |
| 350 | } |
| 351 | |
| 352 | state.SetItemsProcessed(state.iterations() * integers.size()); |
| 353 | } |
| 354 | |
| 355 | static void ErrorSchemeResult(benchmark::State& state) { // NOLINT non-const reference |
| 356 | auto integers = RandomIntegers(); |
nothing calls this directly
no test coverage detected