bm_chttp2_transport.cc
Go to the documentation of this file.
1 /*
2  *
3  * Copyright 2015 gRPC authors.
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  */
18 
19 /* Microbenchmarks around CHTTP2 transport operations */
20 
21 #include <string.h>
22 
23 #include <memory>
24 #include <queue>
25 #include <sstream>
26 
27 #include <benchmark/benchmark.h>
28 
29 #include <grpc/support/alloc.h>
30 #include <grpc/support/log.h>
33 
42 
44  grpc_core::ResourceQuota::Default()->memory_quota()->CreateMemoryAllocator(
45  "test"));
46 
48 // Helper classes
49 //
50 
51 class PhonyEndpoint : public grpc_endpoint {
52  public:
54  static const grpc_endpoint_vtable my_vtable = {read,
55  write,
59  shutdown,
60  destroy,
61  get_peer,
63  get_fd,
65  grpc_endpoint::vtable = &my_vtable;
66  }
67 
69  if (read_cb_ == nullptr) {
72  have_slice_ = true;
73  return;
74  }
77  read_cb_ = nullptr;
78  }
79 
80  private:
81  grpc_closure* read_cb_ = nullptr;
83  bool have_slice_ = false;
85 
87  GPR_ASSERT(read_cb_ == nullptr);
88  if (have_slice_) {
89  have_slice_ = false;
92  return;
93  }
94  read_cb_ = cb;
95  slices_ = slices;
96  }
97 
99  grpc_closure* cb, bool /*urgent*/,
100  int /*min_progress_size*/) {
101  static_cast<PhonyEndpoint*>(ep)->QueueRead(slices, cb);
102  }
103 
104  static void write(grpc_endpoint* /*ep*/, grpc_slice_buffer* /*slices*/,
105  grpc_closure* cb, void* /*arg*/, int /*max_frame_size*/) {
107  }
108 
109  static void add_to_pollset(grpc_endpoint* /*ep*/, grpc_pollset* /*pollset*/) {
110  }
111 
112  static void add_to_pollset_set(grpc_endpoint* /*ep*/,
113  grpc_pollset_set* /*pollset*/) {}
114 
116  grpc_pollset_set* /*pollset*/) {}
117 
118  static void shutdown(grpc_endpoint* ep, grpc_error_handle why) {
120  static_cast<PhonyEndpoint*>(ep)->read_cb_, why);
121  }
122 
123  static void destroy(grpc_endpoint* ep) {
124  delete static_cast<PhonyEndpoint*>(ep);
125  }
126 
127  static absl::string_view get_peer(grpc_endpoint* /*ep*/) { return "test"; }
129  return "test";
130  }
131  static int get_fd(grpc_endpoint* /*ep*/) { return 0; }
132  static bool can_track_err(grpc_endpoint* /*ep*/) { return false; }
133 };
134 
135 class Fixture {
136  public:
138  grpc_channel_args c_args = args.c_channel_args();
139  ep_ = new PhonyEndpoint;
142  .PreconditionChannelArgs(&c_args)
143  .ToC();
144  t_ = grpc_create_chttp2_transport(final_args, ep_, client);
145  grpc_channel_args_destroy(final_args);
146  grpc_chttp2_transport_start_reading(t_, nullptr, nullptr, nullptr);
147  FlushExecCtx();
148  }
149 
151 
153 
155  return reinterpret_cast<grpc_chttp2_transport*>(t_);
156  }
157  grpc_transport* transport() { return t_; }
158 
160 
161  private:
164 };
165 
166 class TestClosure : public grpc_closure {
167  public:
168  virtual ~TestClosure() {}
169 };
170 
171 template <class F>
172 std::unique_ptr<TestClosure> MakeTestClosure(F f) {
173  struct C : public TestClosure {
174  explicit C(const F& f) : f_(f) {
175  GRPC_CLOSURE_INIT(this, Execute, this, nullptr);
176  }
177  F f_;
178  static void Execute(void* arg, grpc_error_handle error) {
179  static_cast<C*>(arg)->f_(error);
180  }
181  };
182  return std::unique_ptr<TestClosure>(new C(f));
183 }
184 
185 template <class F>
187  struct C : public grpc_closure {
188  explicit C(const F& f) : f_(f) {}
189  F f_;
190  static void Execute(void* arg, grpc_error_handle error) {
191  static_cast<C*>(arg)->f_(error);
192  delete static_cast<C*>(arg);
193  }
194  };
195  auto* c = new C{f};
196  return GRPC_CLOSURE_INIT(c, C::Execute, c, nullptr);
197 }
198 
199 class Stream {
200  public:
201  explicit Stream(Fixture* f) : f_(f) {
202  stream_size_ = grpc_transport_stream_size(f->transport());
205  }
206 
209  gpr_free(stream_);
210  arena_->Destroy();
211  }
212 
215  "test_stream");
218  if ((state.iterations() & 0xffff) == 0) {
219  arena_->Destroy();
221  }
223  static_cast<grpc_stream*>(stream_), &refcount_,
224  nullptr, arena_);
225  }
226 
229 #ifndef NDEBUG
230  grpc_stream_unref(&refcount_, "DestroyThen");
231 #else
233 #endif
234  }
235 
238  static_cast<grpc_stream*>(stream_), op);
239  }
240 
242  return static_cast<grpc_chttp2_stream*>(stream_);
243  }
244 
245  private:
246  static void FinishDestroy(void* arg, grpc_error_handle /*error*/) {
247  auto stream = static_cast<Stream*>(arg);
248  grpc_transport_destroy_stream(stream->f_->transport(),
249  static_cast<grpc_stream*>(stream->stream_),
250  stream->destroy_closure_);
251  gpr_event_set(&stream->done_, reinterpret_cast<void*>(1));
252  }
253 
257  size_t stream_size_;
258  void* stream_;
261 };
262 
264 // Benchmarks
265 //
266 std::vector<std::unique_ptr<gpr_event>> done_events;
267 
270  TrackCounters track_counters;
272  auto* s = new Stream(&f);
274  grpc_transport_stream_op_batch_payload op_payload(nullptr);
275  op = {};
276  op.cancel_stream = true;
277  op.payload = &op_payload;
279  std::unique_ptr<TestClosure> next =
280  MakeTestClosure([&, s](grpc_error_handle /*error*/) {
281  if (!state.KeepRunning()) {
282  delete s;
283  return;
284  }
285  s->Init(state);
286  s->Op(&op);
287  s->DestroyThen(next.get());
288  });
290  f.FlushExecCtx();
291  track_counters.Finish(state);
292 }
294 
296  public:
297  static void Prepare(grpc_metadata_batch* b) {
304  "/foo/bar/bm_chttp2_transport")));
307  "foo.test.google.fr:1234")));
308  b->Set(
317  "grpc-c/3.0.0-dev (linux; chttp2; green)")));
318  }
319 };
320 
321 template <class Metadata>
323  TrackCounters track_counters;
326  auto* s = new Stream(&f);
328  grpc_transport_stream_op_batch_payload op_payload(nullptr);
329  std::unique_ptr<TestClosure> start;
330  std::unique_ptr<TestClosure> done;
331 
332  auto reset_op = [&]() {
333  op = {};
334  op.payload = &op_payload;
335  };
336 
338  grpc_metadata_batch b(arena.get());
339  Metadata::Prepare(&b);
340 
341  f.FlushExecCtx();
342  gpr_event bm_done;
343  gpr_event_init(&bm_done);
344  start = MakeTestClosure([&, s](grpc_error_handle /*error*/) {
345  if (!state.KeepRunning()) {
346  delete s;
347  gpr_event_set(&bm_done, (void*)1);
348  return;
349  }
350  s->Init(state);
351  reset_op();
352  op.on_complete = done.get();
353  op.send_initial_metadata = true;
354  op.payload->send_initial_metadata.send_initial_metadata = &b;
355  s->Op(&op);
356  });
357  done = MakeTestClosure([&](grpc_error_handle /*error*/) {
358  reset_op();
359  op.cancel_stream = true;
360  op.payload->cancel_stream.cancel_error = GRPC_ERROR_CANCELLED;
361  s->Op(&op);
362  s->DestroyThen(start.get());
363  });
365  f.FlushExecCtx();
367  track_counters.Finish(state);
368 }
371 
373  TrackCounters track_counters;
376  auto* s = new Stream(&f);
377  s->Init(state);
379  grpc_transport_stream_op_batch_payload op_payload(nullptr);
380  auto reset_op = [&]() {
381  op = {};
382  op.payload = &op_payload;
383  };
384  std::unique_ptr<TestClosure> c =
385  MakeTestClosure([&](grpc_error_handle /*error*/) {
386  if (!state.KeepRunning()) return;
387  reset_op();
388  op.on_complete = c.get();
389  s->Op(&op);
390  });
392  f.FlushExecCtx();
393  reset_op();
394  op.cancel_stream = true;
396  gpr_event* stream_cancel_done = new gpr_event;
397  gpr_event_init(stream_cancel_done);
398  std::unique_ptr<TestClosure> stream_cancel_closure =
401  gpr_event_set(stream_cancel_done, reinterpret_cast<void*>(1));
402  });
403  op.on_complete = stream_cancel_closure.get();
404  s->Op(&op);
405  f.FlushExecCtx();
406  gpr_event_wait(stream_cancel_done, gpr_inf_future(GPR_CLOCK_REALTIME));
407  done_events.emplace_back(stream_cancel_done);
408  s->DestroyThen(
409  MakeOnceClosure([s](grpc_error_handle /*error*/) { delete s; }));
410  f.FlushExecCtx();
411  track_counters.Finish(state);
412 }
414 
415 // Some distros have RunSpecifiedBenchmarks under the benchmark namespace,
416 // and others do not. This allows us to support both modes.
417 namespace benchmark {
419 } // namespace benchmark
420 
421 int main(int argc, char** argv) {
422  grpc::testing::TestEnvironment env(&argc, argv);
423  LibraryInitializer libInit;
424  ::benchmark::Initialize(&argc, argv);
425  grpc::testing::InitTest(&argc, &argv, false);
427  return 0;
428 }
GRPC_CLOSURE_INIT
#define GRPC_CLOSURE_INIT(closure, cb, cb_arg, scheduler)
Definition: closure.h:115
PhonyEndpoint::PhonyEndpoint
PhonyEndpoint()
Definition: bm_chttp2_transport.cc:53
grpc::testing::InitTest
void InitTest(int *argc, char ***argv, bool remove_flags)
Definition: test_config_cc.cc:28
Stream
Definition: bm_chttp2_transport.cc:199
Fixture
Definition: bm_call_create.cc:359
grpc_core::MakeScopedArena
ScopedArenaPtr MakeScopedArena(size_t initial_size, MemoryAllocator *memory_allocator)
Definition: src/core/lib/resource_quota/arena.h:130
GRPC_COMPRESS_DEFLATE
@ GRPC_COMPRESS_DEFLATE
Definition: compression_types.h:62
grpc_endpoint_vtable
Definition: endpoint.h:39
Stream::~Stream
~Stream()
Definition: bm_chttp2_transport.cc:207
GRPC_ERROR_NONE
#define GRPC_ERROR_NONE
Definition: error.h:234
grpc_core::Arena::Create
static Arena * Create(size_t initial_size, MemoryAllocator *memory_allocator)
Definition: src/core/lib/resource_quota/arena.cc:58
log.h
PhonyEndpoint::have_slice_
bool have_slice_
Definition: bm_chttp2_transport.cc:83
benchmark
Definition: bm_alarm.cc:55
generate.env
env
Definition: generate.py:37
memset
return memset(p, 0, total)
grpc_event_engine::experimental::MemoryAllocator
Definition: memory_allocator.h:35
Fixture::transport
grpc_transport * transport()
Definition: bm_chttp2_transport.cc:157
Fixture::~Fixture
~Fixture()
Definition: bm_chttp2_transport.cc:152
grpc_core::CompressionAlgorithmSet
Definition: compression_internal.h:52
internal.h
grpc_create_chttp2_transport
grpc_transport * grpc_create_chttp2_transport(const grpc_channel_args *channel_args, grpc_endpoint *ep, bool is_client)
Definition: chttp2_transport.cc:3122
C
#define C(x)
Definition: abseil-cpp/absl/hash/internal/city_test.cc:49
grpc_core::HttpMethodMetadata
Definition: metadata_batch.h:136
PhonyEndpoint::PushInput
void PushInput(grpc_slice slice)
Definition: bm_chttp2_transport.cc:68
PhonyEndpoint::read
static void read(grpc_endpoint *ep, grpc_slice_buffer *slices, grpc_closure *cb, bool, int)
Definition: bm_chttp2_transport.cc:98
client
Definition: examples/python/async_streaming/client.py:1
grpc_core::Slice
Definition: src/core/lib/slice/slice.h:282
grpc_core::HttpPathMetadata
Definition: metadata_batch.h:262
grpc_pollset_set
struct grpc_pollset_set grpc_pollset_set
Definition: iomgr_fwd.h:23
Fixture::FlushExecCtx
void FlushExecCtx()
Definition: bm_chttp2_transport.cc:150
string.h
grpc_core::slice_detail::StaticConstructors< StaticSlice >::FromStaticString
static StaticSlice FromStaticString(const char *s)
Definition: src/core/lib/slice/slice.h:201
absl::string_view
Definition: abseil-cpp/absl/strings/string_view.h:167
gpr_event_set
GPRAPI void gpr_event_set(gpr_event *ev, void *value)
Definition: sync.cc:59
gpr_free
GPRAPI void gpr_free(void *ptr)
Definition: alloc.cc:51
grpc_endpoint::vtable
const grpc_endpoint_vtable * vtable
Definition: endpoint.h:106
error
grpc_error_handle error
Definition: retry_filter.cc:499
Stream::Stream
Stream(Fixture *f)
Definition: bm_chttp2_transport.cc:201
grpc_core::HttpSchemeMetadata::kHttp
@ kHttp
Definition: metadata_batch.h:117
gpr_malloc
GPRAPI void * gpr_malloc(size_t size)
Definition: alloc.cc:29
BENCHMARK
BENCHMARK(BM_StreamCreateDestroy)
closure.h
Fixture::ep_
PhonyEndpoint * ep_
Definition: bm_chttp2_transport.cc:162
gpr_inf_future
GPRAPI gpr_timespec gpr_inf_future(gpr_clock_type type)
Definition: src/core/lib/gpr/time.cc:55
PhonyEndpoint::get_fd
static int get_fd(grpc_endpoint *)
Definition: bm_chttp2_transport.cc:131
BENCHMARK_TEMPLATE
BENCHMARK_TEMPLATE(BM_StreamCreateSendInitialMetadataDestroy, RepresentativeClientInitialMetadata)
benchmark::RunTheBenchmarksNamespaced
void RunTheBenchmarksNamespaced()
Definition: bm_alarm.cc:56
Stream::destroy_closure_
grpc_closure * destroy_closure_
Definition: bm_chttp2_transport.cc:259
grpc_core::GrpcAcceptEncodingMetadata
Definition: metadata_batch.h:187
TrackCounters::Finish
virtual void Finish(benchmark::State &state)
Definition: helpers.cc:44
GRPC_ERROR_CANCELLED
#define GRPC_ERROR_CANCELLED
Definition: error.h:238
RepresentativeClientInitialMetadata::Prepare
static void Prepare(grpc_metadata_batch *b)
Definition: bm_chttp2_transport.cc:297
Stream::FinishDestroy
static void FinishDestroy(void *arg, grpc_error_handle)
Definition: bm_chttp2_transport.cc:246
GRPC_COMPRESS_NONE
@ GRPC_COMPRESS_NONE
Definition: compression_types.h:61
grpc_core::TeMetadata
Definition: metadata_batch.h:71
grpc_core::Arena
Definition: src/core/lib/resource_quota/arena.h:45
grpc_channel_args
Definition: grpc_types.h:132
grpc_transport_perform_stream_op
void grpc_transport_perform_stream_op(grpc_transport *transport, grpc_stream *stream, grpc_transport_stream_op_batch *op)
Definition: transport.cc:108
Stream::done_
gpr_event done_
Definition: bm_chttp2_transport.cc:260
arena
grpc_core::ScopedArenaPtr arena
Definition: binder_transport_test.cc:237
grpc_chttp2_stream
Definition: src/core/ext/transport/chttp2/transport/internal.h:456
BM_TransportEmptyOp
static void BM_TransportEmptyOp(benchmark::State &state)
Definition: bm_chttp2_transport.cc:372
TrackCounters
Definition: helpers.h:51
DEBUG_LOCATION
#define DEBUG_LOCATION
Definition: debug_location.h:41
benchmark::RunSpecifiedBenchmarks
size_t RunSpecifiedBenchmarks()
Definition: benchmark/src/benchmark.cc:437
string_util.h
Fixture::t_
grpc_transport * t_
Definition: bm_chttp2_transport.cc:163
PhonyEndpoint::buffered_slice_
grpc_slice buffered_slice_
Definition: bm_chttp2_transport.cc:84
start
static uint64_t start
Definition: benchmark-pound.c:74
TestClosure
Definition: bm_chttp2_transport.cc:166
Stream::Init
void Init(benchmark::State &state)
Definition: bm_chttp2_transport.cc:213
c
void c(T a)
Definition: miscompile_with_no_unique_address_test.cc:40
autogen_x86imm.f
f
Definition: autogen_x86imm.py:9
asyncio_get_stats.args
args
Definition: asyncio_get_stats.py:40
PhonyEndpoint::shutdown
static void shutdown(grpc_endpoint *ep, grpc_error_handle why)
Definition: bm_chttp2_transport.cc:118
done_events
std::vector< std::unique_ptr< gpr_event > > done_events
Definition: bm_chttp2_transport.cc:266
Stream::DestroyThen
void DestroyThen(grpc_closure *closure)
Definition: bm_chttp2_transport.cc:227
GPR_ASSERT
#define GPR_ASSERT(x)
Definition: include/grpc/impl/codegen/log.h:94
channel_arguments.h
PhonyEndpoint::destroy
static void destroy(grpc_endpoint *ep)
Definition: bm_chttp2_transport.cc:123
grpc_core::CoreConfiguration::Get
static const CoreConfiguration & Get()
Definition: core_configuration.h:82
grpc_core::ExecCtx::Flush
bool Flush()
Definition: exec_ctx.cc:69
RepresentativeClientInitialMetadata
Definition: bm_chttp2_transport.cc:295
grpc_core::HttpAuthorityMetadata
Definition: metadata_batch.h:256
slice
grpc_slice slice
Definition: src/core/lib/surface/server.cc:467
grpc_transport_destroy
void grpc_transport_destroy(grpc_transport *transport)
Definition: transport.cc:96
closure
grpc_closure closure
Definition: src/core/lib/surface/server.cc:466
grpc_transport_stream_op_batch_payload::cancel_error
grpc_error_handle cancel_error
Definition: transport.h:444
PhonyEndpoint::delete_from_pollset_set
static void delete_from_pollset_set(grpc_endpoint *, grpc_pollset_set *)
Definition: bm_chttp2_transport.cc:115
g_memory_allocator
static auto * g_memory_allocator
Definition: bm_chttp2_transport.cc:43
done
struct tab * done
Definition: bloaty/third_party/zlib/examples/enough.c:176
PhonyEndpoint::QueueRead
void QueueRead(grpc_slice_buffer *slices, grpc_closure *cb)
Definition: bm_chttp2_transport.cc:86
grpc_core::ChannelArgs::ToC
const grpc_channel_args * ToC() const
Definition: channel_args.cc:94
grpc_channel_args_destroy
void grpc_channel_args_destroy(grpc_channel_args *a)
Definition: channel_args.cc:360
arg
Definition: cmdline.cc:40
Stream::chttp2_stream
grpc_chttp2_stream * chttp2_stream()
Definition: bm_chttp2_transport.cc:241
grpc_slice
Definition: include/grpc/impl/codegen/slice.h:65
PhonyEndpoint::add_to_pollset
static void add_to_pollset(grpc_endpoint *, grpc_pollset *)
Definition: bm_chttp2_transport.cc:109
Fixture::PushInput
void PushInput(grpc_slice slice)
Definition: bm_chttp2_transport.cc:159
grpc_core::ResourceQuota::Default
static ResourceQuotaRefPtr Default()
Definition: resource_quota.cc:27
grpc_core::UserAgentMetadata
Definition: metadata_batch.h:214
grpc_core::TeMetadata::kTrailers
@ kTrailers
Definition: metadata_batch.h:77
gpr_event_init
GPRAPI void gpr_event_init(gpr_event *ev)
Definition: sync.cc:54
benchmark::Initialize
void Initialize(int *argc, char **argv)
Definition: benchmark/src/benchmark.cc:602
slice_internal.h
b
uint64_t b
Definition: abseil-cpp/absl/container/internal/layout_test.cc:53
helpers.h
PhonyEndpoint::slices_
grpc_slice_buffer * slices_
Definition: bm_chttp2_transport.cc:82
grpc_core::CoreConfiguration::channel_args_preconditioning
const ChannelArgsPreconditioning & channel_args_preconditioning() const
Definition: core_configuration.h:139
grpc_core::ExecCtx
Definition: exec_ctx.h:97
F
#define F(b, c, d)
Definition: md4.c:112
gpr_event_wait
GPRAPI void * gpr_event_wait(gpr_event *ev, gpr_timespec abs_deadline)
Definition: sync.cc:73
grpc_core::Arena::Destroy
size_t Destroy()
Definition: src/core/lib/resource_quota/arena.cc:73
LibraryInitializer
Definition: helpers.h:33
Stream::Op
void Op(grpc_transport_stream_op_batch *op)
Definition: bm_chttp2_transport.cc:236
main
int main(int argc, char **argv)
Definition: bm_chttp2_transport.cc:421
test_config.h
MakeOnceClosure
grpc_closure * MakeOnceClosure(F f)
Definition: bm_chttp2_transport.cc:186
grpc_transport_stream_op_batch_payload
Definition: transport.h:341
BM_StreamCreateSendInitialMetadataDestroy
static void BM_StreamCreateSendInitialMetadataDestroy(benchmark::State &state)
Definition: bm_chttp2_transport.cc:322
grpc::ChannelArguments
Definition: grpcpp/support/channel_arguments.h:39
grpc_slice_buffer_add
GPRAPI void grpc_slice_buffer_add(grpc_slice_buffer *sb, grpc_slice slice)
Definition: slice/slice_buffer.cc:170
gpr_event
Definition: impl/codegen/sync_generic.h:31
Fixture::chttp2_transport
grpc_chttp2_transport * chttp2_transport()
Definition: bm_chttp2_transport.cc:154
grpc_transport_stream_size
size_t grpc_transport_stream_size(grpc_transport *transport)
Definition: transport.cc:92
grpc_core::HttpSchemeMetadata
Definition: metadata_batch.h:114
PhonyEndpoint::write
static void write(grpc_endpoint *, grpc_slice_buffer *, grpc_closure *cb, void *, int)
Definition: bm_chttp2_transport.cc:104
exec_ctx
grpc_core::ExecCtx exec_ctx
Definition: end2end_binder_transport_test.cc:75
grpc_core::HttpMethodMetadata::kPost
@ kPost
Definition: metadata_batch.h:139
PhonyEndpoint::get_peer
static absl::string_view get_peer(grpc_endpoint *)
Definition: bm_chttp2_transport.cc:127
Stream::stream_
void * stream_
Definition: bm_chttp2_transport.cc:258
MakeTestClosure
std::unique_ptr< TestClosure > MakeTestClosure(F f)
Definition: bm_chttp2_transport.cc:172
benchmark::State
Definition: benchmark/include/benchmark/benchmark.h:503
alloc.h
next
AllocList * next[kMaxLevel]
Definition: abseil-cpp/absl/base/internal/low_level_alloc.cc:100
grpc::testing::TestEnvironment
Definition: test/core/util/test_config.h:54
GRPC_COMPRESS_GZIP
@ GRPC_COMPRESS_GZIP
Definition: compression_types.h:63
Stream::refcount_
grpc_stream_refcount refcount_
Definition: bm_chttp2_transport.cc:255
chttp2_transport.h
TestClosure::~TestClosure
virtual ~TestClosure()
Definition: bm_chttp2_transport.cc:168
slices
SliceBuffer * slices
Definition: retry_filter.cc:631
Stream::stream_size_
size_t stream_size_
Definition: bm_chttp2_transport.cc:257
PhonyEndpoint::can_track_err
static bool can_track_err(grpc_endpoint *)
Definition: bm_chttp2_transport.cc:132
grpc_chttp2_transport
Definition: src/core/ext/transport/chttp2/transport/internal.h:238
arg
struct arg arg
state
Definition: bloaty/third_party/zlib/contrib/blast/blast.c:41
closure
Definition: proxy.cc:59
PhonyEndpoint::get_local_address
static absl::string_view get_local_address(grpc_endpoint *)
Definition: bm_chttp2_transport.cc:128
test_config.h
grpc_core::ExecCtx::Run
static void Run(const DebugLocation &location, grpc_closure *closure, grpc_error_handle error)
Definition: exec_ctx.cc:98
GRPC_STREAM_REF_INIT
#define GRPC_STREAM_REF_INIT(rc, ir, cb, cb_arg, objtype)
Definition: transport.h:190
grpc_transport
Definition: transport_impl.h:89
grpc_stream
struct grpc_stream grpc_stream
Definition: transport.h:174
Stream::arena_
grpc_core::Arena * arena_
Definition: bm_chttp2_transport.cc:256
PhonyEndpoint::add_to_pollset_set
static void add_to_pollset_set(grpc_endpoint *, grpc_pollset_set *)
Definition: bm_chttp2_transport.cc:112
grpc_core::ContentTypeMetadata::kApplicationGrpc
@ kApplicationGrpc
Definition: metadata_batch.h:98
grpc_transport_destroy_stream
void grpc_transport_destroy_stream(grpc_transport *transport, grpc_stream *stream, grpc_closure *then_schedule_closure)
Definition: transport.cc:134
grpc_core::ContentTypeMetadata
Definition: metadata_batch.h:92
grpc_slice_buffer
Definition: include/grpc/impl/codegen/slice.h:83
BM_StreamCreateDestroy
static void BM_StreamCreateDestroy(benchmark::State &state)
Definition: bm_chttp2_transport.cc:268
grpc_error
Definition: error_internal.h:42
GPR_CLOCK_REALTIME
@ GPR_CLOCK_REALTIME
Definition: gpr_types.h:39
grpc_metadata_batch
Definition: metadata_batch.h:1259
grpc_pollset
Definition: bm_cq_multiple_threads.cc:37
PhonyEndpoint::read_cb_
grpc_closure * read_cb_
Definition: bm_chttp2_transport.cc:81
grpc_transport_stream_op_batch
Definition: transport.h:284
grpc_closure
Definition: closure.h:56
op
static grpc_op * op
Definition: test/core/fling/client.cc:47
Stream::f_
Fixture * f_
Definition: bm_chttp2_transport.cc:254
grpc_stream_unref
void grpc_stream_unref(grpc_stream_refcount *refcount, const char *reason)
Definition: transport.h:220
grpc_endpoint
Definition: endpoint.h:105
grpc_core::Closure::Run
static void Run(const DebugLocation &location, grpc_closure *closure, grpc_error_handle error)
Definition: closure.h:250
grpc_transport_init_stream
int grpc_transport_init_stream(grpc_transport *transport, grpc_stream *stream, grpc_stream_refcount *refcount, const void *server_data, grpc_core::Arena *arena)
Definition: transport.cc:100
grpc_core::ChannelArgsPreconditioning::PreconditionChannelArgs
ChannelArgs PreconditionChannelArgs(const grpc_channel_args *args) const
Definition: channel_args_preconditioning.cc:34
grpc_chttp2_transport_start_reading
void grpc_chttp2_transport_start_reading(grpc_transport *transport, grpc_slice_buffer *read_buffer, grpc_closure *notify_on_receive_settings, grpc_closure *notify_on_close)
Definition: chttp2_transport.cc:3128
cb
OPENSSL_EXPORT pem_password_cb * cb
Definition: pem.h:351
grpc_core::ExecCtx::Get
static ExecCtx * Get()
Definition: exec_ctx.h:205
grpc_stream_refcount
Definition: transport.h:178
PhonyEndpoint
Definition: bm_chttp2_transport.cc:51
grpc_transport_stream_op_batch_payload::cancel_stream
struct grpc_transport_stream_op_batch_payload::@46 cancel_stream
GRPC_ERROR_IS_NONE
#define GRPC_ERROR_IS_NONE(err)
Definition: error.h:241
api.h
Fixture::Fixture
Fixture(const grpc::ChannelArguments &args, bool client)
Definition: bm_chttp2_transport.cc:137
stream
voidpf stream
Definition: bloaty/third_party/zlib/contrib/minizip/ioapi.h:136


grpc
Author(s):
autogenerated on Fri May 16 2025 02:57:48