summaryrefslogtreecommitdiffstats
path: root/eval
diff options
context:
space:
mode:
authorTor Egge <Tor.Egge@yahooinc.com>2023-09-04 15:33:40 +0200
committerTor Egge <Tor.Egge@yahooinc.com>2023-09-04 15:33:40 +0200
commit6a4f2f7454ea93bfefd457c4feee3f8203b461a2 (patch)
tree6e8b4a8d84a6731231c0254d19453e667be58d47 /eval
parent0c7951d53ae1a2724f6740431708c302bbdd876f (diff)
Avoid operator<=> (libc++ std::vector limitation).
Diffstat (limited to 'eval')
-rw-r--r--eval/src/tests/instruction/sparse_join_reduce_plan/sparse_join_reduce_plan_test.cpp8
-rw-r--r--eval/src/tests/instruction/universal_dot_product/universal_dot_product_test.cpp2
2 files changed, 7 insertions, 3 deletions
diff --git a/eval/src/tests/instruction/sparse_join_reduce_plan/sparse_join_reduce_plan_test.cpp b/eval/src/tests/instruction/sparse_join_reduce_plan/sparse_join_reduce_plan_test.cpp
index e101487ff59..cfc2277278f 100644
--- a/eval/src/tests/instruction/sparse_join_reduce_plan/sparse_join_reduce_plan_test.cpp
+++ b/eval/src/tests/instruction/sparse_join_reduce_plan/sparse_join_reduce_plan_test.cpp
@@ -40,7 +40,9 @@ struct Event {
res_addr.push_back(make_handle(label));
}
}
- auto operator<=>(const Event &rhs) const = default;
+ bool operator==(const Event& rhs) const noexcept {
+ return lhs_idx == rhs.lhs_idx && rhs_idx == rhs.rhs_idx && res_addr == rhs.res_addr;
+ }
};
struct Trace {
@@ -55,7 +57,9 @@ struct Trace {
events.emplace_back(lhs_idx, rhs_idx, res_addr);
return *this;
}
- auto operator<=>(const Trace &rhs) const = default;
+ bool operator==(const Trace& rhs) const noexcept {
+ return estimate == rhs.estimate && events == rhs.events;
+ }
};
std::ostream &
diff --git a/eval/src/tests/instruction/universal_dot_product/universal_dot_product_test.cpp b/eval/src/tests/instruction/universal_dot_product/universal_dot_product_test.cpp
index 95eb7b406e6..e3393dc2de7 100644
--- a/eval/src/tests/instruction/universal_dot_product/universal_dot_product_test.cpp
+++ b/eval/src/tests/instruction/universal_dot_product/universal_dot_product_test.cpp
@@ -206,7 +206,7 @@ void benchmark(const vespalib::string &desc, const vespalib::string &expr, std::
for (size_t i = 0; i < ctf_meta.steps.size(); ++i) {
auto name = strip_ns(ctf_meta.steps[i].class_name);
if (name.find("Inject") > name.size() && name.find("ConstValue") > name.size()) {
- fprintf(stderr, " %s: %zu ns\n", name.c_str(), count_ns(min_time[i]));
+ fprintf(stderr, " %s: %zu ns\n", name.c_str(), (size_t)count_ns(min_time[i]));
fprintf(stderr, " +-- %s\n", strip_ns(ctf_meta.steps[i].symbol_name).c_str());
}
}