MCPcopy Create free account
hub / github.com/apache/arrow / BinaryMathOpAggregate

Function BinaryMathOpAggregate

cpp/src/arrow/util/decimal_benchmark.cc:129–144  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

127}
128
129static void BinaryMathOpAggregate(
130 benchmark::State& state) { // NOLINT non-const reference
131 std::vector<BasicDecimal128> v;
132 for (int x = 0; x < kValueSize; x++) {
133 v.emplace_back(100 + x, 100 + x);
134 }
135
136 for (auto _ : state) {
137 BasicDecimal128 result;
138 for (int x = 0; x < kValueSize; x++) {
139 result += v[x];
140 }
141 benchmark::DoNotOptimize(result);
142 }
143 state.SetItemsProcessed(state.iterations() * kValueSize);
144}
145
146static void BinaryMathOpAdd128(benchmark::State& state) { // NOLINT non-const reference
147 std::vector<BasicDecimal128> v1, v2;

Callers

nothing calls this directly

Calls 1

emplace_backMethod · 0.80

Tested by

no test coverage detected