From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:37824) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1br5uS-0005bj-NB for qemu-devel@nongnu.org; Mon, 03 Oct 2016 12:16:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1br5uO-0005pI-5t for qemu-devel@nongnu.org; Mon, 03 Oct 2016 12:16:08 -0400 Received: from mail-wm0-x233.google.com ([2a00:1450:400c:c09::233]:38827) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1br5uN-0005ov-MG for qemu-devel@nongnu.org; Mon, 03 Oct 2016 12:16:04 -0400 Received: by mail-wm0-x233.google.com with SMTP id p138so159799870wmb.1 for ; Mon, 03 Oct 2016 09:16:03 -0700 (PDT) References: <20160930213106.20186-1-alex.bennee@linaro.org> <20160930213106.20186-4-alex.bennee@linaro.org> <3cb98ad6-1832-57af-e06d-450a031c15f1@redhat.com> <87h98tu69k.fsf@linaro.org> <20161003153107.GA4319@flamenco> From: Alex =?utf-8?Q?Benn=C3=A9e?= In-reply-to: <20161003153107.GA4319@flamenco> Date: Mon, 03 Oct 2016 17:16:01 +0100 Message-ID: <878tu5tnlq.fsf@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Subject: Re: [Qemu-devel] [PATCH v3 03/15] exec-all.h: revert tb_page_addr_t to target_ulong List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Emilio G. Cota" Cc: Paolo Bonzini , qemu-devel@nongnu.org, mttcg@greensocs.com, fred.konrad@greensocs.com, a.rigo@virtualopensystems.com, bobby.prani@gmail.com, nikunj@linux.vnet.ibm.com, mark.burton@greensocs.com, jan.kiszka@siemens.com, serge.fdrv@gmail.com, rth@twiddle.net, peter.maydell@linaro.org, claudio.fontana@huawei.com, Peter Crosthwaite Emilio G. Cota writes: > On Mon, Oct 03, 2016 at 10:32:55 +0100, Alex Bennée wrote: > (snip) >> However the series as a whole does have value. As you can see from the >> other patches there are some real races being picked up by the sanitizer >> which only really become visible when a) you remove the noise of the >> "false" positives and b) run the test many many times. For example this >> one: >> >> ================== >> WARNING: ThreadSanitizer: data race (pid=24906) >> Read of size 8 at 0x7db4000261f0 by thread T3 (mutexes: write M8203): >> #0 do_tb_flush /home/alex/lsrc/qemu/qemu.git/translate-all.c:872 (qemu-arm+0x00006000ce68) >> #1 process_queued_cpu_work /home/alex/lsrc/qemu/qemu.git/cpus-common.c:337 (qemu-arm+0x000060116712) >> #2 cpu_loop /home/alex/lsrc/qemu/qemu.git/linux-user/main.c:654 (qemu-arm+0x000060052213) >> #3 clone_func /home/alex/lsrc/qemu/qemu.git/linux-user/syscall.c:6070 (qemu-arm+0x0000600686fb) >> #4 (libtsan.so.0+0x0000000230d9) >> >> Previous write of size 8 at 0x7db4000261f0 by main thread (mutexes: write M8): >> #0 cpu_list_add /home/alex/lsrc/qemu/qemu.git/cpus-common.c:87 (qemu-arm+0x000060115b7a) >> #1 cpu_exec_init /home/alex/lsrc/qemu/qemu.git/exec.c:641 (qemu-arm+0x000060009900) >> #2 arm_cpu_initfn /home/alex/lsrc/qemu/qemu.git/target-arm/cpu.c:447 (qemu-arm+0x0000600f833b) > [..] > > Nice! Which patch fixes this--patch 10? It would be cool to have this > report in the corresponding commit message. This particular one only actually showed up after I sent the last series - I'd kicked off 1000 repeating tests just before I boarded my flight back home :-) However patch 10 fixes another rare case which is in the class of races caused by creating or destroying a thread just as we flush. > > Thanks, > > Emilio -- Alex Bennée