From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from zen.linaro.local ([81.128.185.34]) by smtp.gmail.com with ESMTPSA id a13sm2539194wma.13.2017.02.03.03.30.07 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 03 Feb 2017 03:30:07 -0800 (PST) Received: from zen (localhost [127.0.0.1]) by zen.linaro.local (Postfix) with ESMTPS id 25D683E00E9; Fri, 3 Feb 2017 11:30:12 +0000 (GMT) References: <20170201150553.9381-1-alex.bennee@linaro.org> <20170201150553.9381-22-alex.bennee@linaro.org> User-agent: mu4e 0.9.19; emacs 25.1.91.7 From: Alex =?utf-8?Q?Benn=C3=A9e?= To: Peter Maydell Cc: MTTCG Devel , QEMU Developers , KONRAD =?utf-8?B?RnLDqWTDqXJpYw==?= , Alvise Rigo , "Emilio G. Cota" , Pranith Kumar , Nikunj A Dadhania , Mark Burton , Paolo Bonzini , Jan Kiszka , Fedorov Sergey , Richard Henderson , Bamvor Zhang Jian , "open list\:ARM" Subject: Re: [PATCH v9 21/25] target-arm: don't generate WFE/YIELD calls for MTTCG In-reply-to: Date: Fri, 03 Feb 2017 11:30:12 +0000 Message-ID: <87tw8bfr5n.fsf@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-TUID: 8HA6aNENxDYM Peter Maydell writes: > On 1 February 2017 at 15:05, Alex Bennée wrote: >> The WFE and YIELD instructions are really only hints and in TCG's case >> they were useful to move the scheduling on from one vCPU to the next. In >> the parallel context (MTTCG) this just causes an unnecessary cpu_exit >> and contention of the BQL. >> >> Signed-off-by: Alex Bennée >> Reviewed-by: Richard Henderson >> --- >> target/arm/op_helper.c | 7 +++++++ >> target/arm/translate-a64.c | 8 ++++++-- >> target/arm/translate.c | 20 ++++++++++++++++---- >> 3 files changed, 29 insertions(+), 6 deletions(-) > > Reviewed-by: Peter Maydell > > though I'm not much of a fan of yet another global variable :-( It's unfortunate but I think justified in the case. parallel_cpus is a global state that controls the emission of barriers and generation of atomics. It does sometime get turned off for the EXCP_ATOMIC processing (but only in a temporary exclusive region). > > thanks > -- PMM -- Alex Bennée