linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* About refault distance
@ 2014-07-16  1:53 Zhang, Tianfei
  2014-07-18 15:14 ` Johannes Weiner
  0 siblings, 1 reply; 3+ messages in thread
From: Zhang, Tianfei @ 2014-07-16  1:53 UTC (permalink / raw)
  To: hannes@cmpxchg.org; +Cc: linux-mm@kvack.org

[-- Attachment #1: Type: text/plain, Size: 1393 bytes --]

Hi Johannes,

May I ask you a question about refault distance?

Is it supposed the distance of the first and second time to access the a faulted page cache is the same? In reality how about the
ratio will be the same?

            Refault Distance1 = Refault Distance2

On the first refault, We supposed that:
            Refault Distance = A
            NR_INACTIVE_FILE = B
            NR_ACTIVE_FILE = C

*                  fault page add to inactive list tail
                    The Refault Distance  = A
                          |
 *                   B     |        |            C
*              +--------------+   |            +-------------+
*   reclaim <- |   inactive   | <-+-- demotion |    active   | <--+
*              +--------------+                +-------------+    |
*                     |                                           |
*                     +-------------- promotion ------------------+


Why we use A <= C to add faulted page to ACTIVE LIST?

Your patch is want to solve "A workload is thrashing when its pages are frequently used
but they are evicted from the inactive list every time before another access would have
promoted them to the active list." ?

so when a First Refault page add to INACTIVE LIST, it is a Distance B before eviction.
So I am confuse the condition on workingset_refault().


Best,
Figo.zhang

[-- Attachment #2: Type: text/html, Size: 8202 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-07-21  3:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-07-16  1:53 About refault distance Zhang, Tianfei
2014-07-18 15:14 ` Johannes Weiner
2014-07-21  3:27   ` Zhang, Tianfei

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).