From: Khalid Aziz <khalid.aziz@oracle.com>
To: Andrea Arcangeli <aarcange@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Pravin Shelar <pshelar@nicira.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Ben Hutchings <bhutchings@solarflare.com>,
Christoph Lameter <cl@linux.com>,
Johannes Weiner <jweiner@redhat.com>,
Mel Gorman <mgorman@suse.de>, Rik van Riel <riel@redhat.com>,
Andi Kleen <andi@firstfloor.org>,
Minchan Kim <minchan@kernel.org>,
Linus Torvalds <torvalds@linux-foundation.org>
Subject: Re: [PATCH 0/3] mm: hugetlbfs: fix hugetlbfs optimization v2
Date: Mon, 18 Nov 2013 11:04:23 -0700 [thread overview]
Message-ID: <528A56A7.3020301@oracle.com> (raw)
In-Reply-To: <1384537668-10283-1-git-send-email-aarcange@redhat.com>
On 11/15/2013 10:47 AM, Andrea Arcangeli wrote:
> Hi,
>
> 1/3 is a bugfix so it should be applied more urgently. 1/3 is not as
> fast as the current upstream code in the hugetlbfs + directio extreme
> 8GB/sec benchmark (but 3/3 should fill the gap later). The code is
> identical to the one I posted in v1 just rebased on upstream and was
> developed in collaboration with Khalid who already tested it.
>
> 2/3 and 3/3 had very little testing yet, and they're incremental
> optimization. 2/3 is minor and most certainly worth applying later.
>
> 3/3 instead complicates things a bit and adds more branches to the THP
> fast paths, so it should only be applied if the benchmarks of
> hugetlbfs + directio show that it is very worthwhile (that has not
> been verified yet). If it's not worthwhile 3/3 should be dropped (and
> the gap should be filled in some other way if the gap is not caused by
> the _mapcount mangling as I guessed). Ideally this should bring even
> more performance than current upstream code, as current upstream code
> still increased the _mapcount in gup_fast by mistake, while this
> eliminates the locked op on the tail page cacheline in gup_fast too
> (which is required for correctness too).
Hi Andrea,
I ran directio benchmark and here are the performance numbers (MBytes/sec):
Block size 3.12 3.12+patch 1 3.12+patch 1,2,3
---------- ---- ------------ ----------------
1M 8467 8114 7648
64K 4049 4043 4175
Performance numbers with 64K reads look good but there is further
deterioration with 1M reads.
--
Khalid
--
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>
WARNING: multiple messages have this Message-ID (diff)
From: Khalid Aziz <khalid.aziz@oracle.com>
To: Andrea Arcangeli <aarcange@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Pravin Shelar <pshelar@nicira.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Ben Hutchings <bhutchings@solarflare.com>,
Christoph Lameter <cl@linux.com>,
Johannes Weiner <jweiner@redhat.com>,
Mel Gorman <mgorman@suse.de>, Rik van Riel <riel@redhat.com>,
Andi Kleen <andi@firstfloor.org>,
Minchan Kim <minchan@kernel.org>,
Linus Torvalds <torvalds@linux-foundation.org>
Subject: Re: [PATCH 0/3] mm: hugetlbfs: fix hugetlbfs optimization v2
Date: Mon, 18 Nov 2013 11:04:23 -0700 [thread overview]
Message-ID: <528A56A7.3020301@oracle.com> (raw)
In-Reply-To: <1384537668-10283-1-git-send-email-aarcange@redhat.com>
On 11/15/2013 10:47 AM, Andrea Arcangeli wrote:
> Hi,
>
> 1/3 is a bugfix so it should be applied more urgently. 1/3 is not as
> fast as the current upstream code in the hugetlbfs + directio extreme
> 8GB/sec benchmark (but 3/3 should fill the gap later). The code is
> identical to the one I posted in v1 just rebased on upstream and was
> developed in collaboration with Khalid who already tested it.
>
> 2/3 and 3/3 had very little testing yet, and they're incremental
> optimization. 2/3 is minor and most certainly worth applying later.
>
> 3/3 instead complicates things a bit and adds more branches to the THP
> fast paths, so it should only be applied if the benchmarks of
> hugetlbfs + directio show that it is very worthwhile (that has not
> been verified yet). If it's not worthwhile 3/3 should be dropped (and
> the gap should be filled in some other way if the gap is not caused by
> the _mapcount mangling as I guessed). Ideally this should bring even
> more performance than current upstream code, as current upstream code
> still increased the _mapcount in gup_fast by mistake, while this
> eliminates the locked op on the tail page cacheline in gup_fast too
> (which is required for correctness too).
Hi Andrea,
I ran directio benchmark and here are the performance numbers (MBytes/sec):
Block size 3.12 3.12+patch 1 3.12+patch 1,2,3
---------- ---- ------------ ----------------
1M 8467 8114 7648
64K 4049 4043 4175
Performance numbers with 64K reads look good but there is further
deterioration with 1M reads.
--
Khalid
next prev parent reply other threads:[~2013-11-18 18:04 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-15 17:47 [PATCH 0/3] mm: hugetlbfs: fix hugetlbfs optimization v2 Andrea Arcangeli
2013-11-15 17:47 ` Andrea Arcangeli
2013-11-15 17:47 ` [PATCH 1/3] mm: hugetlbfs: fix hugetlbfs optimization Andrea Arcangeli
2013-11-15 17:47 ` Andrea Arcangeli
2013-11-19 23:11 ` Andrew Morton
2013-11-19 23:11 ` Andrew Morton
2013-11-20 0:26 ` Andrea Arcangeli
2013-11-20 0:26 ` Andrea Arcangeli
2013-11-15 17:47 ` [PATCH 2/3] mm: hugetlb: use get_page_foll in follow_hugetlb_page Andrea Arcangeli
2013-11-15 17:47 ` Andrea Arcangeli
2013-11-19 21:27 ` Khalid Aziz
2013-11-19 21:27 ` Khalid Aziz
2013-11-15 17:47 ` [PATCH 3/3] mm: tail page refcounting optimization for slab and hugetlbfs Andrea Arcangeli
2013-11-15 17:47 ` Andrea Arcangeli
2013-11-19 21:27 ` Khalid Aziz
2013-11-19 21:27 ` Khalid Aziz
2013-11-19 23:14 ` Andrew Morton
2013-11-19 23:14 ` Andrew Morton
2013-11-20 0:20 ` Andrea Arcangeli
2013-11-20 0:20 ` Andrea Arcangeli
2013-11-18 18:04 ` Khalid Aziz [this message]
2013-11-18 18:04 ` [PATCH 0/3] mm: hugetlbfs: fix hugetlbfs optimization v2 Khalid Aziz
2013-11-19 20:27 ` Khalid Aziz
2013-11-19 20:27 ` Khalid Aziz
2013-11-19 22:52 ` Andrea Arcangeli
2013-11-19 22:52 ` Andrea Arcangeli
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=528A56A7.3020301@oracle.com \
--to=khalid.aziz@oracle.com \
--cc=aarcange@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=andi@firstfloor.org \
--cc=bhutchings@solarflare.com \
--cc=cl@linux.com \
--cc=gregkh@linuxfoundation.org \
--cc=jweiner@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mgorman@suse.de \
--cc=minchan@kernel.org \
--cc=pshelar@nicira.com \
--cc=riel@redhat.com \
--cc=torvalds@linux-foundation.org \
/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.