Compile fix

pull/12357/head
Craig Tiller 8 years ago
parent ba69d282f5
commit 520d76d698
  1. 6
      src/core/lib/debug/stats_data.h
  2. 27
      src/core/lib/debug/stats_data.yaml
  3. 1
      tools/codegen/core/gen_stats_data.py

@ -69,8 +69,6 @@ typedef enum {
double _hist_val = (double)(value); \
if (_hist_val < 0) _hist_val = 0; \
uint64_t _hist_idx = *(uint64_t *)&_hist_val; \
gpr_log(GPR_DEBUG, "tcp_write_size %lf %" PRId64 " %" PRId64, _hist_val, \
_hist_idx, 4715268809856909312ull); \
if (_hist_val < 5.000000) { \
GRPC_STATS_INC_HISTOGRAM( \
(exec_ctx), GRPC_STATS_HISTOGRAM_TCP_WRITE_SIZE, (int)_hist_val); \
@ -92,8 +90,6 @@ typedef enum {
double _hist_val = (double)(value); \
if (_hist_val < 0) _hist_val = 0; \
uint64_t _hist_idx = *(uint64_t *)&_hist_val; \
gpr_log(GPR_DEBUG, "tcp_write_iov_size %lf %" PRId64 " %" PRId64, \
_hist_val, _hist_idx, 4652218415073722368ull); \
if (_hist_val < 12.000000) { \
GRPC_STATS_INC_HISTOGRAM((exec_ctx), \
GRPC_STATS_HISTOGRAM_TCP_WRITE_IOV_SIZE, \
@ -116,8 +112,6 @@ typedef enum {
double _hist_val = (double)(value); \
if (_hist_val < 0) _hist_val = 0; \
uint64_t _hist_idx = *(uint64_t *)&_hist_val; \
gpr_log(GPR_DEBUG, "tcp_read_size %lf %" PRId64 " %" PRId64, _hist_val, \
_hist_idx, 4715268809856909312ull); \
if (_hist_val < 5.000000) { \
GRPC_STATS_INC_HISTOGRAM((exec_ctx), GRPC_STATS_HISTOGRAM_TCP_READ_SIZE, \
(int)_hist_val); \

@ -1,19 +1,10 @@
# Stats data declaration
# use tools/codegen/core/gen_stats_data.py to turn this into stats_data.h
#Stats data declaration
#use tools / codegen / core / gen_stats_data.py to turn this into stats_data.h
- counter: client_calls_created
- counter: server_calls_created
- counter: syscall_write
- counter: syscall_read
- counter: syscall_poll
- counter: syscall_wait
- counter: histogram_slow_lookups
- histogram: tcp_write_size
max: 16777216 # 16 meg max write tracked
buckets: 64
- histogram: tcp_write_iov_size
max: 1024
buckets: 64
- histogram: tcp_read_size
max: 16777216
buckets: 64
- counter:client_calls_created -
counter:server_calls_created - counter:syscall_write -
counter:syscall_read - counter:syscall_poll - counter:syscall_wait -
counter:histogram_slow_lookups -
histogram:tcp_write_size max:16777216 #16 meg max write tracked buckets:64 -
histogram:tcp_write_iov_size max:1024 buckets:64 -
histogram:tcp_read_size max:16777216 buckets:64

@ -130,7 +130,6 @@ def gen_bucket_code(histogram):
code += 'if (_hist_val < 0) _hist_val = 0;\\\n'
code += 'uint64_t _hist_idx = *(uint64_t*)&_hist_val;\\\n'
map_table = gen_map_table(code_bounds[first_nontrivial:], shift_data)
code += 'gpr_log(GPR_DEBUG, "' + histogram.name + ' %lf %"PRId64 " %"PRId64, _hist_val, _hist_idx, ' + str((map_table[-1] << shift_data[0]) + first_nontrivial_code) + 'ull);\\\n'
if first_nontrivial is None:
code += ('GRPC_STATS_INC_HISTOGRAM((exec_ctx), GRPC_STATS_HISTOGRAM_%s, (int)_hist_val);\\\n'
% histogram.name.upper())

Loading…
Cancel
Save