On 11/15/17, 9:30 AM, "David Sterba" <dste...@suse.com> wrote:
> * ZSTD_inBuffer in_buf
> * ZSTD_outBuffer out_buf
>
> are used in all functions to pass the compression parameters and the
> local variables consume some space. We can move them to the workspace
> and reduce the stack consumption:
>
> zstd.c:zstd_decompress                        -24 (136 -> 112)
> zstd.c:zstd_decompress_bio                    -24 (144 -> 120)
> zstd.c:zstd_compress_pages                    -24 (264 -> 240)

It looks good to me, and I ran my btrfs zstd compression and
decompression test and everything worked.

Is there a case where these 24 bytes matter, or is this just an easy
optimization?

Reviewed-by: Nick Terrell <terre...@fb.com>


Reply via email to