| 50 | }; |
| 51 | |
| 52 | struct RankRunner { |
| 53 | explicit RankRunner(benchmark::State& state) { |
| 54 | options = RankOptions::Defaults(); |
| 55 | options.tiebreaker = static_cast<RankOptions::Tiebreaker>(state.range(2)); |
| 56 | } |
| 57 | |
| 58 | RankOptions options; |
| 59 | |
| 60 | Status operator()(const std::shared_ptr<Array>& values) const { |
| 61 | return CallFunction("rank", {values}, &options).status(); |
| 62 | } |
| 63 | |
| 64 | Status operator()(const std::shared_ptr<ChunkedArray>& values) const { |
| 65 | return CallFunction("rank", {values}, &options).status(); |
| 66 | } |
| 67 | }; |
| 68 | |
| 69 | template <typename Runner, typename ArrayLike> |
| 70 | static void ArraySortFuncBenchmark(benchmark::State& state, const Runner& runner, |
no outgoing calls
no test coverage detected