Deprecate gfe2_reloadable_flag_http2_use_fast_huffman_encoder.
PiperOrigin-RevId: 354306985
Change-Id: I49d59683e9c2dc49eed4ef629b43a7f0ca0f6eb2
diff --git a/quic/core/quic_flags_list.h b/quic/core/quic_flags_list.h
index b30410b..a79d6cc 100644
--- a/quic/core/quic_flags_list.h
+++ b/quic/core/quic_flags_list.h
@@ -4,7 +4,6 @@
// This file is autogenerated by the QUICHE Copybara export script.
-QUIC_FLAG(FLAGS_quic_reloadable_flag_http2_use_fast_huffman_encoder, true)
QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_abort_qpack_on_stream_reset, true)
QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_accept_empty_stream_frame_with_no_fin, true)
QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_ack_delay_alarm_granularity, false)
diff --git a/spdy/core/hpack/hpack_encoder.cc b/spdy/core/hpack/hpack_encoder.cc
index 0187d79..b6715c3 100644
--- a/spdy/core/hpack/hpack_encoder.cc
+++ b/spdy/core/hpack/hpack_encoder.cc
@@ -79,14 +79,11 @@
HpackEncoder::HpackEncoder()
: output_stream_(),
- huffman_table_(ObtainHpackHuffmanTable()),
min_table_size_setting_received_(std::numeric_limits<size_t>::max()),
listener_(NoOpListener),
should_index_(DefaultPolicy),
enable_compression_(true),
- should_emit_table_size_(false),
- use_fast_huffman_encoder_(
- GetSpdyReloadableFlag(http2_use_fast_huffman_encoder)) {}
+ should_emit_table_size_(false) {}
HpackEncoder::~HpackEncoder() = default;
@@ -130,7 +127,6 @@
}
size_t HpackEncoder::EstimateMemoryUsage() const {
- // |huffman_table_| is a singleton. It's accounted for in spdy_session_pool.cc
return SpdyEstimateMemoryUsage(header_table_) +
SpdyEstimateMemoryUsage(output_stream_);
}
@@ -201,22 +197,13 @@
void HpackEncoder::EmitString(absl::string_view str) {
size_t encoded_size =
- enable_compression_
- ? (use_fast_huffman_encoder_ ? http2::HuffmanSize(str)
- : huffman_table_.EncodedSize(str))
- : str.size();
+ enable_compression_ ? http2::HuffmanSize(str) : str.size();
if (encoded_size < str.size()) {
SPDY_DVLOG(2) << "Emitted Huffman-encoded string of length "
<< encoded_size;
output_stream_.AppendPrefix(kStringLiteralHuffmanEncoded);
output_stream_.AppendUint32(encoded_size);
- if (use_fast_huffman_encoder_) {
- SPDY_CODE_COUNT(http2_use_fast_huffman_encoder);
- http2::HuffmanEncodeFast(str, encoded_size,
- output_stream_.MutableString());
- } else {
- huffman_table_.EncodeString(str, &output_stream_);
- }
+ http2::HuffmanEncodeFast(str, encoded_size, output_stream_.MutableString());
} else {
SPDY_DVLOG(2) << "Emitted literal string of length " << str.size();
output_stream_.AppendPrefix(kStringLiteralIdentityEncoded);
diff --git a/spdy/core/hpack/hpack_encoder.h b/spdy/core/hpack/hpack_encoder.h
index adf8cd8..b1b7741 100644
--- a/spdy/core/hpack/hpack_encoder.h
+++ b/spdy/core/hpack/hpack_encoder.h
@@ -25,8 +25,6 @@
namespace spdy {
-class HpackHuffmanTable;
-
namespace test {
class HpackEncoderPeer;
} // namespace test
@@ -141,14 +139,11 @@
HpackHeaderTable header_table_;
HpackOutputStream output_stream_;
- const HpackHuffmanTable& huffman_table_;
size_t min_table_size_setting_received_;
HeaderListener listener_;
IndexingPolicy should_index_;
bool enable_compression_;
bool should_emit_table_size_;
- // Latched value of gfe2_reloadable_flag_http2_use_fast_huffman_encoder.
- const bool use_fast_huffman_encoder_;
};
} // namespace spdy