bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: poke_pages function in ext2fs:truncate.c


From: Sergio López
Subject: Re: poke_pages function in ext2fs:truncate.c
Date: Sat, 8 Oct 2011 01:37:07 +0200

2011/9/13 Sergio López <slpml@sinrega.org>:
> Hi,
>
> Does somebody know the reasoning behind the function "poke_pages" in
> ext2fs:truncate.c? I suppose it's there to work around some kind of
> memory object paging error in GNU Mach, but I'm not sure about it's
> real purpose, or if it's still needed nowadays.
>

Answering to myself, poke_pages is there to force an emancipation of
delayed copy objects (CoW) before truncating node contents. I think
this should be dealt in m_o_lock_request when flushing pages.

Until then, I think an easy optimization like annotating if an object
has been mmap'ed sometime in its lifetime to decide if poking pages is
really needed could be really useful. Knowing it's just a workaround,
a patch like this would be accepted or is better to aim directly for
the costly (but better) solution?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]