Re: [PATCH v4] f2fs: obsolete free nid list approach

From: Chao Yu
Date: Mon Dec 18 2017 - 06:56:31 EST


On 2017/12/15 3:21, Jaegeuk Kim wrote:
> On 12/11, Chao Yu wrote:
>> Hi Jaegeuk,
>>
>> On 2017/12/1 15:36, Jaegeuk Kim wrote:
>>> Hi Chao,
>>>
>>> This is really hard to review and risky a lot to apply it shortly. Do we have a
>>
>> I can understand your concern.
>>
>>> strong reason we have to do this? The original design goal was to minimize
>>> allocation delay which is almost zero for now. Of course, I agreed that there'd
>>
>> I agreed, For nid allocation performance there will be no room to improve since
>> we have already used memory to exchange performance there.
>>
>> After applying this patch, I can encounter slight regression in scenario of
>> continuous file creation.
>>
>> Anyway, goal of this patch is not aiming at performance, instead, it intends to
>> reduce code complexity, and maybe, slightly improving performance of allocation
>> in low-memory environment. So actually, this is a trade-off problem.
>>
>> If we decide to use old approach, I think what can be improved is that if we run
>> out-of-memory, we can switch to nid bitmap searching in alloc_nid rather than
>> preloading free nid entry in build_free_nid whose performance is memory sensitive.
>> Thoughts?
>
> Hmm, in terms of performance, do we really suffer from memory pressure when
> preloading free nids?

Sorry for late reply, I'm on trip now. I guess it will, let me emulate low
memory environment, and do intensive allocation test, will report to you if
there is any progress.

Thanks,