PARQUET-909: Reduce buffer allocations (mallocs) on critical path
PARQUET-909: Reduce buffer allocations (mallocs) on critical path

Author: Deepak Majeti <deepak.majeti@hpe.com>

Closes #268 from majetideepak/ReuseBuffers and squashes the following commits:

bbf5453 [Deepak Majeti] Review comments
4d93d4b [Deepak Majeti] Improve example
3a3e2bb [Deepak Majeti] Fix Resize shrink_to_fit
53c8ac1 [Deepak Majeti] Improve API
22f422f [Deepak Majeti] clang format
8ae02cc [Deepak Majeti] optimize for uncompressed data
3190cef [Deepak Majeti] change fit_to_size of InMemoryOutputStream
03d4862 [Deepak Majeti] clang format
261aa1c [Deepak Majeti] Rewrite Compress API
b09c4a8 [Deepak Majeti] Reuse uncompressed_data buffer
6b9a81b [Deepak Majeti] Clang fromat
31af602 [Deepak Majeti] Reuse levels rle buffer
82eabfb [Deepak Majeti] Re-use def and rep levels sink
edc8e3c [Deepak Majeti] Add API to InMemoryOutputStream

Change-Id: I77483a383043d590936b42c06d425fbdc1edf9fc

xhochy/arrow,cpcloud/arrow,icexelloss/arrow,tebeka/arrow,apache/arrow,kou/arrow,laurentgo/arrow,xhochy/arrow,majetideepak/arrow,laurentgo/arrow,renesugar/arrow,xhochy/arrow,wesm/arrow,tebeka/arrow,tebeka/arrow,laurentgo/arrow,icexelloss/arrow,itaiin/arrow,icexelloss/arrow,cpcloud/arrow,kou/arrow,tebeka/arrow,wesm/arrow,laurentgo/arrow,itaiin/arrow,xhochy/arrow,cpcloud/arrow,renesugar/arrow,apache/arrow,wesm/arrow,apache/arrow,laurentgo/arrow,kou/arrow,pcmoritz/arrow,itaiin/arrow,wesm/arrow,xhochy/arrow,icexelloss/arrow,pcmoritz/arrow,icexelloss/arrow,apache/arrow,laurentgo/arrow,xhochy/arrow,wesm/arrow,majetideepak/arrow,tebeka/arrow,xhochy/arrow,apache/arrow,apache/arrow,renesugar/arrow,renesugar/arrow,renesugar/arrow,pcmoritz/arrow,wesm/arrow,apache/arrow,cpcloud/arrow,xhochy/arrow,majetideepak/arrow,xhochy/arrow,renesugar/arrow,pcmoritz/arrow,kou/arrow,cpcloud/arrow,pcmoritz/arrow,laurentgo/arrow,xhochy/arrow,cpcloud/arrow,wesm/arrow,wesm/arrow,apache/arrow,itaiin/arrow,majetideepak/arrow,cpcloud/arrow,apache/arrow,icexelloss/arrow,kou/arrow,itaiin/arrow,cpcloud/arrow,cpcloud/arrow,pcmoritz/arrow,majetideepak/arrow,apache/arrow,kou/arrow,majetideepak/arrow,pcmoritz/arrow,itaiin/arrow,majetideepak/arrow,wesm/arrow,xhochy/arrow,majetideepak/arrow,majetideepak/arrow,itaiin/arrow,xhochy/arrow,wesm/arrow,icexelloss/arrow,tebeka/arrow,laurentgo/arrow,apache/arrow,kou/arrow,icexelloss/arrow,laurentgo/arrow,icexelloss/arrow,kou/arrow,kou/arrow,laurentgo/arrow,itaiin/arrow,majetideepak/arrow,pcmoritz/arrow,itaiin/arrow,laurentgo/arrow,tebeka/arrow,renesugar/arrow,pcmoritz/arrow,kou/arrow,renesugar/arrow,tebeka/arrow,tebeka/arrow,kou/arrow,icexelloss/arrow,wesm/arrow,apache/arrow,tebeka/arrow,renesugar/arrow,itaiin/arrow,majetideepak/arrow,pcmoritz/arrow,cpcloud/arrow,cpcloud/arrow,renesugar/arrow,majetideepak/arrow,pcmoritz/arrow,laurentgo/arrow,icexelloss/arrow,renesugar/arrow,itaiin/arrow,wesm/arrow,xhochy/arrow,icexelloss/arrow,laurentgo/arrow,wesm/arrow,itaiin/arrow,apache/arrow,itaiin/arrow,pcmoritz/arrow,icexelloss/arrow,pcmoritz/arrow,wesm/arrow,itaiin/arrow,kou/arrow,pcmoritz/arrow,majetideepak/arrow,xhochy/arrow,apache/arrow,kou/arrow,laurentgo/arrow,majetideepak/arrow,kou/arrow,itaiin/arrow,renesugar/arrow,icexelloss/arrow,majetideepak/arrow,xhochy/arrow,cpcloud/arrow,laurentgo/arrow,cpcloud/arrow,cpcloud/arrow,pcmoritz/arrow,renesugar/arrow,renesugar/arrow,renesugar/arrow