Deprecate --gfe2_reloadable_flag_quic_better_qpack_compression. PiperOrigin-RevId: 650315447
diff --git a/quiche/common/quiche_feature_flags_list.h b/quiche/common/quiche_feature_flags_list.h index 2718143..bbdfcb7 100755 --- a/quiche/common/quiche_feature_flags_list.h +++ b/quiche/common/quiche_feature_flags_list.h
@@ -16,7 +16,6 @@ QUICHE_FLAG(bool, quiche_reloadable_flag_quic_bbr2_extra_acked_window, false, true, "When true, the BBR4 copt sets the extra_acked window to 20 RTTs and BBR5 sets it to 40 RTTs.") QUICHE_FLAG(bool, quiche_reloadable_flag_quic_bbr2_probe_two_rounds, true, true, "When true, the BB2U copt causes BBR2 to wait two rounds with out draining the queue before exiting PROBE_UP and BB2S has the same effect in STARTUP.") QUICHE_FLAG(bool, quiche_reloadable_flag_quic_bbr2_simplify_inflight_hi, true, true, "When true, the BBHI copt causes QUIC BBRv2 to use a simpler algorithm for raising inflight_hi in PROBE_UP.") -QUICHE_FLAG(bool, quiche_reloadable_flag_quic_better_qpack_compression, true, true, "If true, use improved QPACK compression algorithm.") QUICHE_FLAG(bool, quiche_reloadable_flag_quic_block_until_settings_received_copt, true, true, "If enabled and a BSUS connection is received, blocks server connections until SETTINGS frame is received.") QUICHE_FLAG(bool, quiche_reloadable_flag_quic_can_send_ack_frequency, true, true, "If true, ack frequency frame can be sent from server to client.") QUICHE_FLAG(bool, quiche_reloadable_flag_quic_conservative_bursts, false, false, "If true, set burst token to 2 in cwnd bootstrapping experiment.")
diff --git a/quiche/quic/core/qpack/qpack_encoder.cc b/quiche/quic/core/qpack/qpack_encoder.cc index 4433861..61996a5 100644 --- a/quiche/quic/core/qpack/qpack_encoder.cc +++ b/quiche/quic/core/qpack/qpack_encoder.cc
@@ -177,14 +177,6 @@ // Match cannot be used. - if (!better_compression_) { - // Encode entry as string literals. - representations.push_back(EncodeLiteralHeaderField(name, value)); - break; - } - - QUIC_RELOADABLE_FLAG_COUNT(quic_better_qpack_compression); - QpackEncoderHeaderTable::MatchResult match_result_name_only = header_table_.FindHeaderName(name);
diff --git a/quiche/quic/core/qpack/qpack_encoder.h b/quiche/quic/core/qpack/qpack_encoder.h index ae1d440..201f623 100644 --- a/quiche/quic/core/qpack/qpack_encoder.h +++ b/quiche/quic/core/qpack/qpack_encoder.h
@@ -155,10 +155,6 @@ uint64_t maximum_blocked_streams_; QpackBlockingManager blocking_manager_; int header_list_count_; - - // Latched value of reloadable_flag_quic_better_qpack_compression. - const bool better_compression_ = - GetQuicReloadableFlag(quic_better_qpack_compression); }; // QpackEncoder::DecoderStreamErrorDelegate implementation that does nothing.
diff --git a/quiche/quic/core/qpack/qpack_encoder_test.cc b/quiche/quic/core/qpack/qpack_encoder_test.cc index c8ed462..d38e90c 100644 --- a/quiche/quic/core/qpack/qpack_encoder_test.cc +++ b/quiche/quic/core/qpack/qpack_encoder_test.cc
@@ -542,54 +542,28 @@ // Stream 3 is blocked. Stream 4 is not allowed to block, but it can // reference already acknowledged dynamic entry 0. std::string expected2; - if (GetQuicReloadableFlag(quic_better_qpack_compression)) { - if (HuffmanEnabled()) { - ASSERT_TRUE( - absl::HexStringToBytes("0200" // prefix - "80" // dynamic entry 0 - "2a94e7" // literal name "foo" - "0362617a" // with literal value "baz" - "55" // name of static entry 5 - "0362617a" // with literal value "baz" - "23626172" // literal name "bar" - "0362617a", // with literal value "baz" - &expected2)); - } else { - ASSERT_TRUE( - absl::HexStringToBytes("0200" // prefix - "80" // dynamic entry 0 - "23666f6f" // literal name "foo" - "0362617a" // with literal value "baz" - "55" // name of static entry 5 - "0362617a" // with literal value "baz" - "23626172" // literal name "bar" - "0362617a", // with literal value "baz" - &expected2)); - } + if (HuffmanEnabled()) { + ASSERT_TRUE( + absl::HexStringToBytes("0200" // prefix + "80" // dynamic entry 0 + "2a94e7" // literal name "foo" + "0362617a" // with literal value "baz" + "55" // name of static entry 5 + "0362617a" // with literal value "baz" + "23626172" // literal name "bar" + "0362617a", // with literal value "baz" + &expected2)); } else { - if (HuffmanEnabled()) { - ASSERT_TRUE( - absl::HexStringToBytes("0200" // prefix - "80" // dynamic entry 0 - "2a94e7" // literal name "foo" - "0362617a" // with literal value "baz" - "2c21cfd4c5" // literal name "cookie" - "0362617a" // with literal value "baz" - "23626172" // literal name "bar" - "0362617a", // with literal value "baz" - &expected2)); - } else { - ASSERT_TRUE( - absl::HexStringToBytes("0200" // prefix - "80" // dynamic entry 0 - "23666f6f" // literal name "foo" - "0362617a" // with literal value "baz" - "26636f6f6b6965" // literal name "cookie" - "0362617a" // with literal value "baz" - "23626172" // literal name "bar" - "0362617a", // with literal value "baz" - &expected2)); - } + ASSERT_TRUE( + absl::HexStringToBytes("0200" // prefix + "80" // dynamic entry 0 + "23666f6f" // literal name "foo" + "0362617a" // with literal value "baz" + "55" // name of static entry 5 + "0362617a" // with literal value "baz" + "23626172" // literal name "bar" + "0362617a", // with literal value "baz" + &expected2)); } EXPECT_EQ(expected2, encoder_.EncodeHeaderList(/* stream_id = */ 4, header_list2, @@ -999,27 +973,11 @@ // Streams 1 and 2 are blocked, therefore stream 3 is not allowed to refer to // the existing dynamic table entry, nor to add a new entry to the dynamic // table. - if (GetQuicReloadableFlag(quic_better_qpack_compression)) { - ASSERT_TRUE(absl::HexStringToBytes( - "0000" // prefix - "5f00" // name reference to static table entry 15 - "03626172", // literal value "bar" - &expected_output)); - } else { - if (HuffmanEnabled()) { - ASSERT_TRUE(absl::HexStringToBytes( - "0000" // prefix - "2db9495339e4" // Huffman-encoded literal name ":method" - "03626172", // literal value "bar" - &expected_output)); - } else { - ASSERT_TRUE( - absl::HexStringToBytes("0000" // prefix - "27003a6d6574686f64" // literal name ":method" - "03626172", // literal value "bar" - &expected_output)); - } - } + ASSERT_TRUE( + absl::HexStringToBytes("0000" // prefix + "5f00" // name reference to static table entry 15 + "03626172", // literal value "bar" + &expected_output)); EXPECT_EQ(expected_output, encoder_.EncodeHeaderList(/* stream_id = */ 3, header_list, &encoder_stream_sent_byte_count_)); @@ -1088,39 +1046,21 @@ spdy::Http2HeaderBlock header_list3; header_list3["one"] = "foo"; - if (GetQuicReloadableFlag(quic_better_qpack_compression)) { - // Entry matches name and value of oldest dynamic table entry, which cannot - // be used. Use the name of the most recent dynamic table entry instead, and - // encode value as string literal. - if (HuffmanEnabled()) { - ASSERT_TRUE(absl::HexStringToBytes( - "0c00" // prefix - "40" // name as dynamic table entry 0 - "8294e7", // Huffman-encoded literal value "foo" - &expected_output)); - } else { - ASSERT_TRUE( - absl::HexStringToBytes("0c00" // prefix - "40" // name as dynamic table entry 0 - "03666f6f", // literal value "foo" - &expected_output)); - } + // Entry matches name and value of oldest dynamic table entry, which cannot be + // used. Use the name of the most recent dynamic table entry instead, and + // encode value as string literal. + if (HuffmanEnabled()) { + ASSERT_TRUE( + absl::HexStringToBytes("0c00" // prefix + "40" // name as dynamic table entry 0 + "8294e7", // Huffman-encoded literal value "foo" + &expected_output)); } else { - // Entry matches name and value of oldest dynamic table entry, which cannot - // be used. Encode both name and value as string literal instead. - if (HuffmanEnabled()) { - ASSERT_TRUE( - absl::HexStringToBytes("0000" // prefix - "2a3d45" // literal name "one" - "8294e7", // literal value "foo" - &expected_output)); - } else { - ASSERT_TRUE( - absl::HexStringToBytes("0000" // prefix - "236f6e65" // literal name "one" - "03666f6f", // literal value "foo" - &expected_output)); - } + ASSERT_TRUE( + absl::HexStringToBytes("0c00" // prefix + "40" // name as dynamic table entry 0 + "03666f6f", // literal value "foo" + &expected_output)); } EXPECT_EQ(expected_output, Encode(header_list3)); }