| 1 |
// Copyright 2022 gRPC authors. |
| 2 |
// |
| 3 |
// Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 |
// you may not use this file except in compliance with the License. |
| 5 |
// You may obtain a copy of the License at |
| 6 |
// |
| 7 |
// http://www.apache.org/licenses/LICENSE-2.0 |
| 8 |
// |
| 9 |
// Unless required by applicable law or agreed to in writing, software |
| 10 |
// distributed under the License is distributed on an "AS IS" BASIS, |
| 11 |
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 |
// See the License for the specific language governing permissions and |
| 13 |
// limitations under the License. |
| 14 |
|
| 15 |
// Automatically generated by tools/codegen/core/gen_experiments.py |
| 16 |
|
| 17 |
#include <grpc/support/port_platform.h> |
| 18 |
|
| 19 |
#include "src/core/lib/experiments/experiments.h" |
| 20 |
|
| 21 |
namespace { |
| 22 |
const char* const description_tcp_frame_size_tuning = |
| 23 |
"If set, enables TCP to use RPC size estimation made by higher layers. TCP " |
| 24 |
"would not indicate completion of a read operation until a specified " |
| 25 |
"number of bytes have been read over the socket. Buffers are also " |
| 26 |
"allocated according to estimated RPC sizes."; |
| 27 |
const char* const description_tcp_read_chunks = |
| 28 |
"Allocate only 8kb or 64kb chunks for TCP reads to reduce pressure on " |
| 29 |
"malloc to recycle arbitrary large blocks."; |
| 30 |
const char* const description_tcp_rcv_lowat = |
| 31 |
"Use SO_RCVLOWAT to avoid wakeups on the read path."; |
| 32 |
const char* const description_peer_state_based_framing = |
| 33 |
"If set, the max sizes of frames sent to lower layers is controlled based " |
| 34 |
"on the peer's memory pressure which is reflected in its max http2 frame " |
| 35 |
"size."; |
| 36 |
const char* const description_flow_control_fixes = |
| 37 |
"Various fixes for flow control, max frame size setting."; |
| 38 |
const char* const description_memory_pressure_controller = |
| 39 |
"New memory pressure controller"; |
| 40 |
const char* const description_periodic_resource_quota_reclamation = |
| 41 |
"Periodically return memory to the resource quota"; |
| 42 |
const char* const description_unconstrained_max_quota_buffer_size = |
| 43 |
"Discard the cap on the max free pool size for one memory allocator"; |
| 44 |
const char* const description_new_hpack_huffman_decoder = |
| 45 |
"New HPACK huffman decoder - should be much faster than the existing " |
| 46 |
"implementation."; |
| 47 |
const char* const description_event_engine_client = |
| 48 |
"Use EventEngine clients instead of iomgr's grpc_tcp_client"; |
| 49 |
const char* const description_monitoring_experiment = |
| 50 |
"Placeholder experiment to prove/disprove our monitoring is working"; |
| 51 |
const char* const description_promise_based_client_call = |
| 52 |
"If set, use the new gRPC promise based call code when it's appropriate " |
| 53 |
"(ie when all filters in a stack are promise based)"; |
| 54 |
const char* const description_posix_event_engine_enable_polling = |
| 55 |
"If set, enables polling on the default posix event engine."; |
| 56 |
#ifdef NDEBUG |
| 57 |
const bool kDefaultForDebugOnly = false; |
| 58 |
#else |
| 59 |
const bool kDefaultForDebugOnly = true; |
| 60 |
#endif |
| 61 |
} // namespace |
| 62 |
|
| 63 |
namespace grpc_core { |
| 64 |
|
| 65 |
const ExperimentMetadata g_experiment_metadata[] = { |
| 66 |
{"tcp_frame_size_tuning", description_tcp_frame_size_tuning, false}, |
| 67 |
{"tcp_read_chunks", description_tcp_read_chunks, true}, |
| 68 |
{"tcp_rcv_lowat", description_tcp_rcv_lowat, false}, |
| 69 |
{"peer_state_based_framing", description_peer_state_based_framing, false}, |
| 70 |
{"flow_control_fixes", description_flow_control_fixes, false}, |
| 71 |
{"memory_pressure_controller", description_memory_pressure_controller, |
| 72 |
false}, |
| 73 |
{"periodic_resource_quota_reclamation", |
| 74 |
description_periodic_resource_quota_reclamation, true}, |
| 75 |
{"unconstrained_max_quota_buffer_size", |
| 76 |
description_unconstrained_max_quota_buffer_size, false}, |
| 77 |
{"new_hpack_huffman_decoder", description_new_hpack_huffman_decoder, |
| 78 |
kDefaultForDebugOnly}, |
| 79 |
{"event_engine_client", description_event_engine_client, false}, |
| 80 |
{"monitoring_experiment", description_monitoring_experiment, true}, |
| 81 |
{"promise_based_client_call", description_promise_based_client_call, false}, |
| 82 |
{"posix_event_engine_enable_polling", |
| 83 |
description_posix_event_engine_enable_polling, kDefaultForDebugOnly}, |
| 84 |
}; |
| 85 |
|
| 86 |
} // namespace grpc_core |