|
|
Log in / Subscribe / Register

Positive to negative ratio

Positive to negative ratio

Posted Jul 10, 2026 10:36 UTC (Fri) by neilbrown (subscriber, #359)
In reply to: Positive to negative ratio by paulj
Parent article: Limiting negative dentries

The number of negative dentries is not the problem. The problems are:
- iterating over positive children can be slow
- refcount on parent from negative children can exceed 32bits
- freeing a large number of (negative) dentries may not free much memory due to fragmentation, and may cause excessive memory bus traffic (if I've understood that one properly)

Reducing the number of negative dentries is a large and inappropriate hammer.

Negative dentries can be on a separate list. They can have an indirect ref on the parent. They can, on second reference, be moved to a separate pool of pages of negative dentries (negative dentries do not have ling term references so ate relatively easy to move). These pages can be freed whole, reducing fragmentation.

So we can address each actual problem rather addressing something that loosely correlates with the problems.


to post comments


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds