aboutsummaryrefslogtreecommitdiff
path: root/reftable/block.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2024-05-08 10:18:43 -0700
committerJunio C Hamano <gitster@pobox.com>2024-05-08 10:18:43 -0700
commit5aec7231c8daabeca7cb2d3caa0ed0f88223f81e (patch)
treecfff1d955d7081ff68c3e383fcd9c8436004c893 /reftable/block.h
parentd4cc1ec35f3bcce816b69986ca41943f6ce21377 (diff)
parentfa74f32291d0e2b642345d25e16724567f9b881f (diff)
downloadgit-5aec7231c8daabeca7cb2d3caa0ed0f88223f81e.tar.xz
Merge branch 'ps/reftable-write-optim'
Code to write out reftable has seen some optimization and simplification. * ps/reftable-write-optim: reftable/block: reuse compressed array reftable/block: reuse zstream when writing log blocks reftable/writer: reset `last_key` instead of releasing it reftable/writer: unify releasing memory reftable/writer: refactorings for `writer_flush_nonempty_block()` reftable/writer: refactorings for `writer_add_record()` refs/reftable: don't recompute committer ident reftable: remove name checks refs/reftable: skip duplicate name checks refs/reftable: perform explicit D/F check when writing symrefs refs/reftable: fix D/F conflict error message on ref copy
Diffstat (limited to 'reftable/block.h')
-rw-r--r--reftable/block.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/reftable/block.h b/reftable/block.h
index ea4384a7e2..e91f3d2790 100644
--- a/reftable/block.h
+++ b/reftable/block.h
@@ -18,6 +18,10 @@ https://developers.google.com/open-source/licenses/bsd
* allocation overhead.
*/
struct block_writer {
+ z_stream *zstream;
+ unsigned char *compressed;
+ size_t compressed_cap;
+
uint8_t *buf;
uint32_t block_size;