[PATCH v3] erofs-utils: lib: name worker threads erofs_compress
Gao Xiang
hsiangkao at linux.alibaba.com
Tue Mar 17 04:05:41 AEDT 2026
On 2026/3/17 01:02, Nithurshen wrote:
..
> @@ -1427,6 +1430,12 @@ void *z_erofs_mt_wq_tls_alloc(struct erofs_workqueue *wq, void *ptr)
> {
> struct erofs_compress_wq_tls *tls;
>
> +#if defined(__linux__)
> + prctl(PR_SET_NAME, "erofs_compress");
> +#elif defined(__APPLE__)
> + pthread_setname_np("erofs_compress");
> +#endif
Why not call them as `erofs_compressor`?
and could we wrap it up as a new function like:
erofs_set_thread_name() somewhere instead so that
users can use it easier instead?
Thanks,
Gao Xiang
> +
> tls = calloc(1, sizeof(*tls));
> if (!tls)
> return NULL;
More information about the Linux-erofs
mailing list