Fix zlib + lzma memory usage inefficiency
authorNick Terrell <terrelln@fb.com>
Wed, 12 Apr 2017 19:44:56 +0000 (12:44 -0700)
committerFacebook Github Bot <facebook-github-bot@users.noreply.github.com>
Wed, 12 Apr 2017 19:49:59 +0000 (12:49 -0700)
commit6bb90698a194d181f9e0d962cd4eb622a1a5290a
tree2fa7eccd342f76d674a46856eaec5157e01a2ef4
parent6dbd9e9722682f4cb4a44aea4cadadd85ddd78fb
Fix zlib + lzma memory usage inefficiency

Summary:
Since IOBuf rounds to a good malloc size, zlib and lzma waste space.
For a 4 MiB `length`, about 1 MiB of the IOBuf is wasted.

Reviewed By: yfeldblum

Differential Revision: D4872830

fbshipit-source-id: 42fc83277b2dae22b75403e0e71c43e8f2b19f21
folly/io/Compression.cpp