Classes | Macros | Typedefs | Functions | Variables
benchmark-ping-pongs.c File Reference
#include "uv.h"
#include "task.h"
#include <stdlib.h>
#include <stdio.h>
Include dependency graph for benchmark-ping-pongs.c:

Go to the source code of this file.

Classes

struct  buf_s
 
struct  pinger_t
 

Macros

#define TIME   5000
 

Typedefs

typedef struct buf_s buf_t
 

Functions

 BENCHMARK_IMPL (ping_pongs)
 
static void buf_alloc (uv_handle_t *tcp, size_t size, uv_buf_t *buf)
 
static void buf_free (const uv_buf_t *buf)
 
static void pinger_close_cb (uv_handle_t *handle)
 
static void pinger_connect_cb (uv_connect_t *req, int status)
 
static void pinger_new (void)
 
static void pinger_read_cb (uv_stream_t *tcp, ssize_t nread, const uv_buf_t *buf)
 
static void pinger_shutdown_cb (uv_shutdown_t *req, int status)
 
static void pinger_write_cb (uv_write_t *req, int status)
 
static void pinger_write_ping (pinger_t *pinger)
 

Variables

static buf_tbuf_freelist = NULL
 
static int completed_pingers = 0
 
static uv_loop_tloop
 
static char PING [] = "PING\n"
 
static int pinger_shutdown_cb_called
 
static int64_t start_time
 

Macro Definition Documentation

◆ TIME

#define TIME   5000

Definition at line 29 of file benchmark-ping-pongs.c.

Typedef Documentation

◆ buf_t

typedef struct buf_s buf_t

Function Documentation

◆ BENCHMARK_IMPL()

BENCHMARK_IMPL ( ping_pongs  )

Definition at line 209 of file benchmark-ping-pongs.c.

◆ buf_alloc()

static void buf_alloc ( uv_handle_t tcp,
size_t  size,
uv_buf_t buf 
)
static

Definition at line 56 of file benchmark-ping-pongs.c.

◆ buf_free()

static void buf_free ( const uv_buf_t buf)
static

Definition at line 72 of file benchmark-ping-pongs.c.

◆ pinger_close_cb()

static void pinger_close_cb ( uv_handle_t handle)
static

Definition at line 79 of file benchmark-ping-pongs.c.

◆ pinger_connect_cb()

static void pinger_connect_cb ( uv_connect_t req,
int  status 
)
static

Definition at line 166 of file benchmark-ping-pongs.c.

◆ pinger_new()

static void pinger_new ( void  )
static

Definition at line 179 of file benchmark-ping-pongs.c.

◆ pinger_read_cb()

static void pinger_read_cb ( uv_stream_t tcp,
ssize_t  nread,
const uv_buf_t buf 
)
static

Definition at line 124 of file benchmark-ping-pongs.c.

◆ pinger_shutdown_cb()

static void pinger_shutdown_cb ( uv_shutdown_t req,
int  status 
)
static

Definition at line 112 of file benchmark-ping-pongs.c.

◆ pinger_write_cb()

static void pinger_write_cb ( uv_write_t req,
int  status 
)
static

Definition at line 92 of file benchmark-ping-pongs.c.

◆ pinger_write_ping()

static void pinger_write_ping ( pinger_t pinger)
static

Definition at line 99 of file benchmark-ping-pongs.c.

Variable Documentation

◆ buf_freelist

buf_t* buf_freelist = NULL
static

Definition at line 50 of file benchmark-ping-pongs.c.

◆ completed_pingers

int completed_pingers = 0
static

Definition at line 52 of file benchmark-ping-pongs.c.

◆ loop

uv_loop_t* loop
static

Definition at line 48 of file benchmark-ping-pongs.c.

◆ PING

char PING[] = "PING\n"
static

Definition at line 46 of file benchmark-ping-pongs.c.

◆ pinger_shutdown_cb_called

int pinger_shutdown_cb_called
static

Definition at line 51 of file benchmark-ping-pongs.c.

◆ start_time

int64_t start_time
static

Definition at line 53 of file benchmark-ping-pongs.c.



grpc
Author(s):
autogenerated on Fri May 16 2025 03:01:04