diff --git a/protos/protos.h b/protos/protos.h index 2813eaa8b9..d1134340a9 100644 --- a/protos/protos.h +++ b/protos/protos.h @@ -25,10 +25,7 @@ using hpb::internal::PrivateAccess; using hpb::internal::Serialize; using hpb::internal::SetExtension; } // namespace internal -using hpb::ClearMessage; -using hpb::CloneMessage; using hpb::CreateMessage; -using hpb::DeepCopy; using hpb::Parse; using hpb::Serialize; diff --git a/rust/test/benchmarks/BUILD b/rust/test/benchmarks/BUILD index fa40d0ddec..6a1e2294a9 100644 --- a/rust/test/benchmarks/BUILD +++ b/rust/test/benchmarks/BUILD @@ -48,6 +48,7 @@ cc_test( ":bench_data_upb_cc_proto", ":benchmarks", ":proto_benchmarks_cpp", # build_cleaner: keep + "//hpb", "//hpb:repeated_field", "//protos", "//src/google/protobuf:protobuf_lite", @@ -69,6 +70,7 @@ cc_test( ":bench_data_upb_cc_proto", ":benchmarks", ":proto_benchmarks_upb", # build_cleaner: keep + "//hpb", "//hpb:repeated_field", "//protos", "//src/google/protobuf:protobuf_lite", diff --git a/rust/test/benchmarks/rust_protobuf_benchmarks.cc b/rust/test/benchmarks/rust_protobuf_benchmarks.cc index 50001a0057..1a1bcf04f9 100644 --- a/rust/test/benchmarks/rust_protobuf_benchmarks.cc +++ b/rust/test/benchmarks/rust_protobuf_benchmarks.cc @@ -5,6 +5,7 @@ #include #include "absl/log/absl_check.h" +#include "google/protobuf/hpb/hpb.h" #include "google/protobuf/repeated_ptr_field.h" #include "google/protobuf/rust/test/benchmarks/bench_data.pb.h" #include "google/protobuf/rust/test/benchmarks/bench_data.upb.proto.h" @@ -142,7 +143,7 @@ BENCHMARK(BM_add_100_ints_cpp); void BM_add_100_ints_upb(benchmark::State& state) { for (auto s : state) { ::protos::Arena arena; - auto data = ::protos::CreateMessage(arena); + auto data = ::hpb::CreateMessage(arena); for (int i = 0; i < 100; ++i) { data.add_nums(i); } @@ -184,12 +185,12 @@ BENCHMARK(BM_copy_from_100_ints_cpp); void BM_copy_from_100_ints_upb(benchmark::State& state) { ::protos::Arena arena; - auto source = ::protos::CreateMessage(arena); + auto source = ::hpb::CreateMessage(arena); for (int i = 0; i < 100; ++i) { source.add_nums(i); } for (auto s : state) { - auto data = ::protos::CreateMessage(arena); + auto data = ::hpb::CreateMessage(arena); data.resize_nums(source.nums_size()); std::copy(source.nums().begin(), source.nums().end(), data.mutable_nums()->begin()); @@ -228,7 +229,7 @@ BENCHMARK(BM_sum_1000_ints_cpp); void BM_sum_1000_ints_upb(benchmark::State& state) { ::protos::Arena arena; - auto data = ::protos::CreateMessage(arena); + auto data = ::hpb::CreateMessage(arena); for (int i = 0; i < 1000; ++i) { data.add_nums(i); }