lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAE1zotKvDHX8XoPKfAfA7rpiZcRE2XC_fEyTc1LPShPP1XfGeg@mail.gmail.com>
Date:	Tue, 18 Jun 2013 22:32:36 +0300
From:	Octavian Purdila <octavian.purdila@...el.com>
To:	Benjamin LaHaise <bcrl@...ck.org>
Cc:	Zach Brown <zab@...hat.com>,
	Kent Overstreet <koverstreet@...gle.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org, linux-aio@...ck.org,
	linux-s390@...r.kernel.org, schwidefsky@...ibm.com,
	"Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
	Andi Kleen <ak@...ux.intel.com>
Subject: Re: [PATCH v3 next/akpm] aio: convert the ioctx list to radix tree

On Tue, Jun 18, 2013 at 10:08 PM, Benjamin LaHaise <bcrl@...ck.org> wrote:
> On Tue, Jun 18, 2013 at 10:05:22PM +0300, Octavian Purdila wrote:
>> On Fri, Jun 14, 2013 at 5:20 PM, Octavian Purdila
>> <octavian.purdila@...el.com> wrote:
>> > I picked up Ben's patch and incorporated Zach's idea and the first
>> > results look promising, as expected. I am going to do a full test with
>> > the same workload I've used for rbtree and come back with the results
>> > and the patch in a day or so.
>> >
>>
>> Unfortunately, I still see performance degradation for the one ioctx
>> case even when using IDR. I am using the same fio benchmark as before.
>
> How much of a regression?
>

Hi Ben,

It is even worse then radix, I've seen between 1% to even 4%
degradation. I have tried to profile it and so far the culprit seems
to be the hint code in idr_find. perf top -e dTLB-load-misses shows:

       â     static inline void *idr_find(struct idr *idr, int id)
       â     {
       â             struct idr_layer *hint = rcu_dereference_raw(idr->hint);
       â
       â             if (hint && (id & ~IDR_MASK) == hint->prefix)
       â                     return rcu_dereference_raw(hint->ary[id &
IDR_MASK]);
 49.42 â d0:   movzbl %r12b,%edx
       â       add    $0x4,%rdx
       â       mov    0x8(%rax,%rdx,8),%rax


I should say that I am using kvm for testing this. Hopefully this is
not a side effect of virtualization. I have attached the patch I am
testing with.

Thanks,
Tavi

Download attachment "0001-aio-use-ring-id-and-IDR-to-speed-up-lookps.patch" of type "application/octet-stream" (8008 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ