)]}'
{
  "commit": "92a5deefea02c813133c84024828e780777efcf5",
  "tree": "c4865e2a933cfa379576cdf25f89177c3a6d9cc1",
  "parents": [
    "fa1f2e1637a140a84f08fa51f44e6e1add54ff7e"
  ],
  "author": {
    "name": "Mike Blume",
    "email": "mikeblume@google.com",
    "time": "Wed Dec 02 12:47:50 2026 -0800"
  },
  "committer": {
    "name": "Copybara-Service",
    "email": "copybara-worker@google.com",
    "time": "Wed Dec 02 12:48:54 2026 -0800"
  },
  "message": "Simplify private BalsaHeaders lookup helpers to use indices\n\nThe private header-line lookup helpers returned `HeaderLines` iterators, which callers then compared against `end()` or converted back to an index with `i - header_lines_.begin()`. The const and non-const lookups also duplicated the same search loop.\n\nReturn a `HeaderLines::size_type` index instead, with `header_lines_.size()` meaning \"not found\". `GetConstHeaderLinesIterator` and `GetHeaderLinesIterator` merge into one const `GetHeaderLineIndex`. `GetHeaderLinesIteratorForLastMultivaluedHeader` becomes the const `GetHeaderLineIndexForLastMultivaluedHeader`, which also replaces a hand-written walk to the last matching line at one call site. `RemoveAllOfHeaderStartingAt` takes a start index. No behavior change is intended.\n\nLookups now go through `header_lines_[i]`, which libc++ hardening bounds-checks against `size()`.\n\nWhy now: we are preparing to enable bounds-checked `std::vector` iterators in libc++. Those iterators are larger and are checked on every dereference, and these helpers showed up as a hotspot in GFE2 arcadia_http loadtests with them enabled (n\u003d3-4 per arm). This change cuts the dereference check from 0.23% to 0.02% of GFE2 CPU and the total bounded-iterator overhead from +0.93% to +0.35%. Without bounded iterators, we measured no regression.\n\nPiperOrigin-RevId: 1034709243\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "ee946a0985eed83e147b6d21841beb094224aa33",
      "old_mode": 33188,
      "old_path": "quiche/balsa/balsa_headers.cc",
      "new_id": "b4ee0e6f2a63587a182b7998ef31540d2bb4ae56",
      "new_mode": 33188,
      "new_path": "quiche/balsa/balsa_headers.cc"
    },
    {
      "type": "modify",
      "old_id": "7536f74d06b28b48db8d032ca2077908bfac4253",
      "old_mode": 33188,
      "old_path": "quiche/balsa/balsa_headers.h",
      "new_id": "727e96424d953a7786f008bfe421767997e61dfa",
      "new_mode": 33188,
      "new_path": "quiche/balsa/balsa_headers.h"
    }
  ]
}
