| commit | 344498b67f42af38118cc250b0b1ec212f09d927 | [log] [tgz] |
|---|---|---|
| author | Yuxuan 'fishy' Wang <yuxuan.wang@reddit.com> | Mon Apr 29 15:16:39 2024 -0700 |
| committer | Yuxuan 'fishy' Wang <fishywang@gmail.com> | Tue Apr 30 10:54:50 2024 -0700 |
| tree | 08513ae4f9a9e16e2786b542d444acfba449c4da | |
| parent | c3d8a4ef61b439464cd2d5c417a6ceb03e6cafb1 [diff] |
go: Define a bytePool for TRichTransport Client: go TBinaryProtocol and TCompactProtocol (and as an extension, THeaderProtocol) use TRichTransport's ReadByte/WriteByte functions a lot under the hood, and in some extreme cases those ReadByte/WriteByte calls can generate a lot of allocations for the byte they used. Use a resource pool to help reduce the allocations.