Re: [PATCH] erofs-utils: change temporal buffer to non static

2024-04-08 Thread Gao Xiang
Hi Yifan, On 2024/4/8 18:34, Yifan Zhao wrote: Hi Noboru, AFAIK, this `tryrecompress_trailing` is only used when `may_inline` is true, indicating that this segment is the last one in the file. In the current inner-file implementation, it means that only one worker will use the `tmp` buffer

Re: [PATCH] erofs-utils: change temporal buffer to non static

2024-04-08 Thread Gao Xiang
On 2024/4/8 17:16, Noboru Asai wrote: In multi-threaded mode, each thread must use a different buffer in tryrecompress_trailing function, so change this buffer to non static. Signed-off-by: Noboru Asai Thanks for catching this! Reviewed-by: Gao Xiang Thanks, Gao Xiang

Re: [PATCH] erofs-utils: change temporal buffer to non static

2024-04-08 Thread Yifan Zhao
Hi Noboru, AFAIK, this `tryrecompress_trailing` is only used when `may_inline` is true, indicating that this segment is the last one in the file. In the current inner-file implementation, it means that only one worker will use the `tmp` buffer at a given time. In fact, the `static` modif

[PATCH] erofs-utils: change temporal buffer to non static

2024-04-08 Thread Noboru Asai
In multi-threaded mode, each thread must use a different buffer in tryrecompress_trailing function, so change this buffer to non static. Signed-off-by: Noboru Asai --- lib/compress.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/compress.c b/lib/compress.c index 641fde