[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a4ab4a2c-8b96-837d-d0a3-d06625eb484c@mellanox.com>
Date: Wed, 21 Feb 2018 11:47:56 +0200
From: Max Gurtovoy <maxg@...lanox.com>
To: Chuck Lever <chuck.lever@...cle.com>,
Bart Van Assche <Bart.VanAssche@....com>
CC: "jgg@...pe.ca" <jgg@...pe.ca>, "arnd@...db.de" <arnd@...db.de>,
"dledford@...hat.com" <dledford@...hat.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"leonro@...lanox.com" <leonro@...lanox.com>,
"linux-rdma@...r.kernel.org" <linux-rdma@...r.kernel.org>,
"sagi@...mberg.me" <sagi@...mberg.me>
Subject: Re: [PATCH] RDMA/core: reduce IB_POLL_BATCH constant
On 2/20/2018 11:47 PM, Chuck Lever wrote:
>
>
>> On Feb 20, 2018, at 4:14 PM, Bart Van Assche <Bart.VanAssche@....com> wrote:
>>
>> On Tue, 2018-02-20 at 21:59 +0100, Arnd Bergmann wrote:
>>> /* # of WCs to poll for with a single call to ib_poll_cq */
>>> -#define IB_POLL_BATCH 16
>>> +#define IB_POLL_BATCH 8
>>
>> The purpose of batch polling is to minimize contention on the cq spinlock.
>> Reducing the IB_POLL_BATCH constant may affect performance negatively. Has
>> the performance impact of this change been verified for all affected drivers
>> (ib_srp, ib_srpt, ib_iser, ib_isert, NVMeOF, NVMeOF target, SMB Direct, NFS
>> over RDMA, ...)?
>
> Only the users of the DIRECT polling method use an on-stack
> array of ib_wc's. This is only the SRP drivers.
>
> The other two modes have use of a dynamically allocated array
> of ib_wc's that hangs off the ib_cq. These shouldn't need any
> reduction in the size of this array, and they are the common
> case.
>
> IMO a better solution would be to change ib_process_cq_direct
> to use a smaller on-stack array, and leave IB_POLL_BATCH alone.
Yup, good idea.
you can define IB_DIRECT_POLL_BATCH to be 8 and use it in
ib_process_cq_direct. *but* please make sure to use the right value in
ib_poll_cq since the wcs array should be able to hold the requested
amount of wcs.
-Max.
>
> --
> Chuck Lever
>
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
Powered by blists - more mailing lists