From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gabriele Svelto Subject: Re: RDMA and memory ordering Date: Wed, 13 Nov 2013 19:23:46 +0100 Message-ID: <5283C3B2.6010106@gmail.com> References: <5281FFF9.5070705@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Sender: linux-rdma-owner-u79uwXL29TY76Z2rM5mHXA@public.gmane.org To: Anuj Kalia Cc: "linux-rdma-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" List-Id: linux-rdma@vger.kernel.org On 12/11/2013 11:31, Anuj Kalia wrote: > I believe the atomic operations would be a lot more expensive than > reads/writes. I'm targetting maximum performance so I don't want to > look that way yet. This sounds like premature optimization to me which as you know is the root of all evil :) Try using the atomic primitives, they have been designed specifically for this kind of scenario, and then measure their performance in the real world before spending time on optimizing something that might just be fast enough for your purposes (and far more robust). If you're already polling your CQs those operations will be *very* fast. Gabriele -- To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org More majordomo info at http://vger.kernel.org/majordomo-info.html