From: Peter Zijlstra <a.p.zijlstra@chello.nl>
To: Marcelo Tosatti <marcelo.tosatti@cyclades.com>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
Rik van Riel <riel@redhat.com>
Subject: Re: [RFC 1/3] non-resident page tracking
Date: Tue, 09 Aug 2005 21:15:26 +0200 [thread overview]
Message-ID: <1123614926.17222.19.camel@twins> (raw)
In-Reply-To: <20050809182517.GA20644@dmt.cnet>
On Tue, 2005-08-09 at 15:25 -0300, Marcelo Tosatti wrote:
> Hi Rik,
>
> Two hopefully useful comments:
>
> i) ARC and its variants requires additional information about page
> replacement (namely whether the page has been reclaimed from the L1 or
> L2 lists).
>
> How costly would it be to add this information to the hash table?
>
I've been thinking on reserving another word in the cache-line and use
that as a bit-array to keep that information; the only problems with
that would be atomicy of the {bucket,bit} tuple and very large
cachelines where NUM_NR > 32.
> ii) From my reading of the patch, the provided "distance" information is
> relative to each hash bucket. I'm unable to understand the distance metric
> being useful if measured per-hash-bucket instead of globally?
The assumption is that IFF the hash function has good distribution
properties the per bucket distance is a good approximation of
(distance >> nonres_shift).
>
> PS: Since remember_page() is always called with the zone->lru_lock held,
> the preempt_disable/enable pair is unecessary at the moment... still,
> might be better to leave it there for safety reasons.
>
There being multiple zones; owning zone->lru_lock does not guarantee
uniqueness on the remember_page() path as its a global structure.
--
Peter Zijlstra <a.p.zijlstra@chello.nl>
WARNING: multiple messages have this Message-ID (diff)
From: Peter Zijlstra <a.p.zijlstra@chello.nl>
To: Marcelo Tosatti <marcelo.tosatti@cyclades.com>
Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org,
Rik van Riel <riel@redhat.com>
Subject: Re: [RFC 1/3] non-resident page tracking
Date: Tue, 09 Aug 2005 21:15:26 +0200 [thread overview]
Message-ID: <1123614926.17222.19.camel@twins> (raw)
In-Reply-To: <20050809182517.GA20644@dmt.cnet>
On Tue, 2005-08-09 at 15:25 -0300, Marcelo Tosatti wrote:
> Hi Rik,
>
> Two hopefully useful comments:
>
> i) ARC and its variants requires additional information about page
> replacement (namely whether the page has been reclaimed from the L1 or
> L2 lists).
>
> How costly would it be to add this information to the hash table?
>
I've been thinking on reserving another word in the cache-line and use
that as a bit-array to keep that information; the only problems with
that would be atomicy of the {bucket,bit} tuple and very large
cachelines where NUM_NR > 32.
> ii) From my reading of the patch, the provided "distance" information is
> relative to each hash bucket. I'm unable to understand the distance metric
> being useful if measured per-hash-bucket instead of globally?
The assumption is that IFF the hash function has good distribution
properties the per bucket distance is a good approximation of
(distance >> nonres_shift).
>
> PS: Since remember_page() is always called with the zone->lru_lock held,
> the preempt_disable/enable pair is unecessary at the moment... still,
> might be better to leave it there for safety reasons.
>
There being multiple zones; owning zone->lru_lock does not guarantee
uniqueness on the remember_page() path as its a global structure.
--
Peter Zijlstra <a.p.zijlstra@chello.nl>
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2005-08-09 19:15 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-08 20:14 [RFC 0/3] non-resident page tracking Rik van Riel
2005-08-08 20:14 ` Rik van Riel
2005-08-08 20:14 ` [RFC 1/3] " Rik van Riel
2005-08-08 20:14 ` Rik van Riel
2005-08-08 20:26 ` David S. Miller
2005-08-08 20:26 ` David S. Miller, Rik van Riel
2005-08-08 20:30 ` Rik van Riel
2005-08-08 20:30 ` Rik van Riel
2005-08-09 18:25 ` Marcelo Tosatti
2005-08-09 18:25 ` Marcelo Tosatti
2005-08-09 19:15 ` Peter Zijlstra [this message]
2005-08-09 19:15 ` Peter Zijlstra
2005-08-09 21:13 ` Marcelo Tosatti
2005-08-09 21:13 ` Marcelo Tosatti
2005-08-10 8:40 ` Rik van Riel
2005-08-10 8:40 ` Rik van Riel
2005-08-09 23:52 ` Rik van Riel
2005-08-09 23:52 ` Rik van Riel
2005-08-08 20:14 ` [RFC 2/3] " Rik van Riel
2005-08-08 20:14 ` Rik van Riel
2005-08-08 20:14 ` [RFC 3/3] " Rik van Riel
2005-08-08 20:14 ` Rik van Riel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1123614926.17222.19.camel@twins \
--to=a.p.zijlstra@chello.nl \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=marcelo.tosatti@cyclades.com \
--cc=riel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.