aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/zhack.c
diff options
context:
space:
mode:
authorRich Ercolani <[email protected]>2024-01-12 15:17:26 -0500
committerBrian Behlendorf <[email protected]>2024-01-29 14:53:29 -0800
commit4d4972ed98a83a4b3a404f53782d5b351b8ef8cf (patch)
tree2cd86a5ec16e7b28dd4dc51d3c6f0f2711882af2 /cmd/zhack.c
parent3425484eb907d489c315cced2a1fdea08ef03fc4 (diff)
Stop wasting time on malloc in snprintf_zstd_header
Profiling zdb -vvvvv on datasets with a lot of zstd blocks, we find ourselves spending quite a lot of time on malloc/free, because we allocate a 16M abd each call, and never free it, so we're leaking 16M per call as well. This seems sub-optimal. So let's just keep the buffer around and reuse it. Reviewed-by: Brian Behlendorf <[email protected]> Reviewed-by: Rob Norris <[email protected]> Signed-off-by: Rich Ercolani <[email protected]> Closes #15721
Diffstat (limited to 'cmd/zhack.c')
0 files changed, 0 insertions, 0 deletions