From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:45587) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b7qG4-0005ja-08 for qemu-devel@nongnu.org; Tue, 31 May 2016 16:27:24 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1b7qFz-0002pX-VJ for qemu-devel@nongnu.org; Tue, 31 May 2016 16:27:23 -0400 Received: from mail-qg0-x232.google.com ([2607:f8b0:400d:c04::232]:33957) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1b7qFz-0002pS-Qx for qemu-devel@nongnu.org; Tue, 31 May 2016 16:27:19 -0400 Received: by mail-qg0-x232.google.com with SMTP id p34so28043605qgp.1 for ; Tue, 31 May 2016 13:27:19 -0700 (PDT) Sender: Richard Henderson References: <20160531183928.29406-1-bobby.prani@gmail.com> <20160531183928.29406-3-bobby.prani@gmail.com> From: Richard Henderson Message-ID: <6f2b3338-e5cd-3d4c-354b-0997a9fd6bd9@twiddle.net> Date: Tue, 31 May 2016 13:27:16 -0700 MIME-Version: 1.0 In-Reply-To: <20160531183928.29406-3-bobby.prani@gmail.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC v2 PATCH 02/13] tcg/i386: Add support for fence List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Pranith Kumar , "open list:i386 target" Cc: alex.bennee@linaro.org, serge.fdrv@linaro.org On 05/31/2016 11:39 AM, Pranith Kumar wrote: > + case INDEX_op_mb: > + tcg_out_mb(s); You need to look at the barrier type and DTRT. In particular, the Linux smp_rmb and smp_wmb types need not emit any code. > + { INDEX_op_mb, { "r" } }, You certainly do *not* need the constant argument loaded into a register. This should remain { }. r~