[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <YrEiwHGs4vY+wLsx@ziqianlu-Dell-Optiplex7000>
Date: Tue, 21 Jun 2022 09:45:36 +0800
From: Aaron Lu <aaron.lu@...el.com>
To: Luis Chamberlain <mcgrof@...nel.org>
CC: Davidlohr Bueso <dave@...olabs.net>, Song Liu <song@...nel.org>,
<linux-kernel@...r.kernel.org>, <bpf@...r.kernel.org>,
<linux-mm@...ck.org>, <ast@...nel.org>, <daniel@...earbox.net>,
<peterz@...radead.org>, <torvalds@...ux-foundation.org>,
<rick.p.edgecombe@...el.com>, <kernel-team@...com>
Subject: Re: [PATCH v4 bpf-next 0/8] bpf_prog_pack followup
On Mon, Jun 20, 2022 at 11:31:39AM -0700, Luis Chamberlain wrote:
> On Mon, Jun 20, 2022 at 07:11:45PM +0800, Aaron Lu wrote:
> > Hi Song,
> >
> > On Fri, May 20, 2022 at 04:57:50PM -0700, Song Liu wrote:
> >
> > ... ...
> >
> > > The primary goal of bpf_prog_pack is to reduce iTLB miss rate and reduce
> > > direct memory mapping fragmentation. This leads to non-trivial performance
> > > improvements.
> > >
> > > For our web service production benchmark, bpf_prog_pack on 4kB pages
> > > gives 0.5% to 0.7% more throughput than not using bpf_prog_pack.
> > > bpf_prog_pack on 2MB pages 0.6% to 0.9% more throughput than not using
> > > bpf_prog_pack. Note that 0.5% is a huge improvement for our fleet. I
> > > believe this is also significant for other companies with many thousand
> > > servers.
> > >
> >
> > I'm evaluationg performance impact due to direct memory mapping
> > fragmentation
>
> BTW how exactly are you doing this?
Right now I'm mostly collecting materials from the web :-)
Zhengjun has run some extensive microbenmarks with different page size
for direct mapping and on different server machines a while ago, here
is his report:
https://lore.kernel.org/linux-mm/213b4567-46ce-f116-9cdf-bbd0c884eb3c@linux.intel.com/
Quoting part of the conclusion:
"
This leads us to conclude that although 1G mappings are a
good default choice, there is no compelling evidence that it must be the
only choice, or that folks deriving benefits (like hardening) from
smaller mapping sizes should avoid the smaller mapping sizes.
"
I searched the archive and found there is performance problem when
kernel text huge mapping gets splitted:
https://lore.kernel.org/lkml/20190823052335.572133-1-songliubraving@fb.com/
But I haven't found a report complaining direct mapping fragmentation yet.
Powered by blists - more mailing lists