Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-20 Thread Vlastimil Babka
On 03/13/2018 08:04 AM, Aaron Lu wrote: > On Tue, Mar 13, 2018 at 11:35:19AM +0800, Aaron Lu wrote: >> On Mon, Mar 12, 2018 at 10:32:32AM -0700, Dave Hansen wrote: >>> On 03/09/2018 12:24 AM, Aaron Lu wrote: + /* + * We are going to put the page back to

Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-13 Thread Aaron Lu
On Tue, Mar 13, 2018 at 11:35:19AM +0800, Aaron Lu wrote: > On Mon, Mar 12, 2018 at 10:32:32AM -0700, Dave Hansen wrote: > > On 03/09/2018 12:24 AM, Aaron Lu wrote: > > > + /* > > > + * We are going to put the page back to the global > > > + * pool,

Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-12 Thread Aaron Lu
On Mon, Mar 12, 2018 at 10:32:32AM -0700, Dave Hansen wrote: > On 03/09/2018 12:24 AM, Aaron Lu wrote: > > + /* > > +* We are going to put the page back to the global > > +* pool, prefetch its buddy to speed up later access > > +

Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-12 Thread Dave Hansen
On 03/09/2018 12:24 AM, Aaron Lu wrote: > + /* > + * We are going to put the page back to the global > + * pool, prefetch its buddy to speed up later access > + * under zone->lock. It is believed the overhead of > +

Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-12 Thread Vlastimil Babka
On 03/09/2018 10:58 PM, Andrew Morton wrote: >> >> When a page is freed back to the global pool, its buddy will be checked >> to see if it's possible to do a merge. This requires accessing buddy's >> page structure and that access could take a long time if it's cache cold. >> >> This patch adds a p

Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-10 Thread Aaron Lu
On Fri, Mar 09, 2018 at 01:58:32PM -0800, Andrew Morton wrote: > > > > When a page is freed back to the global pool, its buddy will be checked > > to see if it's possible to do a merge. This requires accessing buddy's > > page structure and that access could take a long time if it's cache cold. > >

Re: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-09 Thread Andrew Morton
> > When a page is freed back to the global pool, its buddy will be checked > to see if it's possible to do a merge. This requires accessing buddy's > page structure and that access could take a long time if it's cache cold. > > This patch adds a prefetch to the to-be-freed page's buddy outside of

[PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock

2018-03-09 Thread Aaron Lu
as an upper limit itself. From: Aaron Lu Subject: [PATCH v4 3/3 update] mm/free_pcppages_bulk: prefetch buddy while not holding lock When a page is freed back to the global pool, its buddy will be checked to see if it's possible to do a merge. This requires accessing buddy's page structure and tha