From: Sergey Senozhatsky <senozhatsky@chromium.org>
To: Sergey Senozhatsky <senozhatsky@chromium.org>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Minchan Kim <minchan@kernel.org>,
linux-kernel@vger.kernel.org, linux-block@vger.kernel.org
Subject: Re: [PATCH 13/14] zram: add dictionary support to zstd backend
Date: Sat, 4 May 2024 15:02:11 +0900 [thread overview]
Message-ID: <20240504060211.GG14947@google.com> (raw)
In-Reply-To: <20240503091823.3616962-14-senozhatsky@chromium.org>
On (24/05/03 18:17), Sergey Senozhatsky wrote:
> This adds support for pre-trained zstd dictionaries [1]
> Dictionary is loaded once (per-config) and then loaded to Cctx
> and Dctx by reference, so we don't allocate extra memory.
>
> The patch is a little non-trivial, as it seems that noone
> ever attempted to use dictionaries in the linux kernel
> port of zstd.
>
> It also uses GFP_KERNEL gfp in Cctx customAlloc(). We probably
> would want to do something about it. Either make sure that we
> always (somehow) fully setup all Cctx contexts from non-atomic
> context before we attempt to use them, come up with some sort
> of custom allocator or stop calling zcomp_compress() from atomic
> context.
>
> [1] https://github.com/facebook/zstd/blob/dev/programs/zstd.1.md#dictionary-builder
JFI
I reworked this patch quite significantly in v2 of the series.
I guess I'll post it soon.
next prev parent reply other threads:[~2024-05-04 6:02 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-03 9:17 [PATCH 00/14] zram: convert to custom comp API and allow algorithms configuration Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 01/14] zram: move from crypto API to custom comp backends API Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 02/14] zram: add lzo and lzorle compression backends support Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 03/14] zram: add lz4 compression backend support Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 04/14] zram: add lz4hc " Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 05/14] zram: add zstd " Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 06/14] zram: pass estimated src size hint to zstd Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 07/14] zram: add zlib compression backend support Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 08/14] zram: check that backends array has at least one backend Sergey Senozhatsky
2024-05-04 6:54 ` kernel test robot
2024-05-04 7:14 ` Sergey Senozhatsky
2024-05-04 23:10 ` Andrew Morton
2024-05-05 4:39 ` Sergey Senozhatsky
2024-05-05 5:13 ` Sergey Senozhatsky
2024-05-05 6:48 ` Sergey Senozhatsky
2024-05-06 3:22 ` Sergey Senozhatsky
2024-05-06 5:20 ` Masahiro Yamada
2024-05-06 6:43 ` Sergey Senozhatsky
2024-05-04 7:15 ` kernel test robot
2024-05-03 9:17 ` [PATCH 09/14] zram: introduce zcomp_config structure Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 10/14] zram: extend comp_algorithm attr write handling Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 11/14] zram: support compression level comp config Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 12/14] zram: add support for dict " Sergey Senozhatsky
2024-05-03 9:17 ` [PATCH 13/14] zram: add dictionary support to zstd backend Sergey Senozhatsky
2024-05-04 6:02 ` Sergey Senozhatsky [this message]
2024-05-03 9:17 ` [PATCH 14/14] Documentation/zram: add documentation for algorithm parameters Sergey Senozhatsky
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240504060211.GG14947@google.com \
--to=senozhatsky@chromium.org \
--cc=akpm@linux-foundation.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=minchan@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox