It appear that there is no problem on Intel 64-bit hosts.
Perhaps the problem is manifested on all 32-bit hosts. I currently don't
have access to any other 320bit host due to remote work.
The arm is the only target were I noticed this happens. I checked hppa,
mips, mipsel, m68k, ppc, and sh4, the
I just want to stress once again that the test was performed on a 32-bit
Intel host.
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1880225
Title:
Emulation of some arm programs fail with "Assertion
Using bisection, it can be deduced that this behavior appears to be
caused by this commit:
commit ee94743034bfb443cf246eda4971bdc15d8ee066 (HEAD)
Author: Alex Bennée
Date: Wed May 13 18:51:28 2020 +0100
linux-user: completely re-write init_guest_space
First we ensure all guest sp
23.05.2020 00:33, Eric Blake wrote:
On 5/22/20 11:19 AM, Vladimir Sementsov-Ogievskiy wrote:
Most of coroutine wrappers already follow this notation:
s/of/of our/
s/notation/convention/
We have coroutine_fn bdrv_co_(), which
is the core functions, and wrapper, which does polling loope is ca
On Fri, 22 May 2020 at 22:33, Robert Foley wrote:
> On Fri, 22 May 2020 at 13:44, Peter Maydell wrote:
> > Every target's has_work function seems to access
> > cs->interrupt_request without using atomic_read() :
> > why does Arm need to do something special here?
> >
> > More generally, the only
On Fri, 22 May 2020 at 15:55, Peter Maydell wrote:
>
> Convert the Neon narrowing shifts where op==8 to decodetree:
> * VSHRN
> * VRSHRN
> * VQSHRUN
> * VQRSHRUN
>
> Signed-off-by: Peter Maydell
> ---
> +// todo expand out the shift-narrow and the narrow-op
Oops. I fixed this todo item
On 5/22/20 11:19 AM, Vladimir Sementsov-Ogievskiy wrote:
We are going to keep coroutine-wrappers code (structure-packing
parameters, BDRV_POLL wrapper functions) in a separate auto-generated
files. So, we'll need a header with declaration of original _co_
functions, for those which are static now
On Fri, 22 May 2020 at 13:44, Peter Maydell wrote:
>
> On Fri, 22 May 2020 at 17:15, Robert Foley wrote:
> >
> > For example:
> > WARNING: ThreadSanitizer: data race (pid=11134)
> > Atomic write of size 4 at 0x7bbce0ac by main thread (mutexes: write
> > M875):
> > #0 __tsan_atomic32_st
On 5/22/20 11:19 AM, Vladimir Sementsov-Ogievskiy wrote:
Most of coroutine wrappers already follow this notation:
s/of/of our/
s/notation/convention/
We have coroutine_fn bdrv_co_(), which
is the core functions, and wrapper, which does polling loope is called
bdrv_().
We have 'coroutine_fn
Patchew URL:
https://patchew.org/QEMU/20200522161950.2839-1-vsement...@virtuozzo.com/
Hi,
This series failed the docker-mingw@fedora build test. Please find the testing
commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.
=== TEST SCRIPT BEGIN
Patchew URL:
https://patchew.org/QEMU/20200522161950.2839-1-vsement...@virtuozzo.com/
Hi,
This series failed the asan build test. Please find the testing commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.
=== TEST SCRIPT BEGIN ===
#!/bin/bash
Patchew URL:
https://patchew.org/QEMU/20200522161950.2839-1-vsement...@virtuozzo.com/
Hi,
This series failed the docker-quick@centos7 build test. Please find the testing
commands and
their output below. If you have Docker installed, you can probably reproduce it
locally.
=== TEST SCRIPT BEGI
Patchew URL:
https://patchew.org/QEMU/20200522160755.886-1-robert.fo...@linaro.org/
Hi,
This series seems to have some coding style problems. See output below for
more information:
Message-id: 20200522160755.886-1-robert.fo...@linaro.org
Subject: [PATCH 00/19] Add Thread Sanitizer support to
On Wed, 20 May 2020 12:23:24 -0400
"Michael S. Tsirkin" wrote:
> On Fri, May 15, 2020 at 12:11:55AM +0200, Halil Pasic wrote:
> > The virtio specification tells that the device is to present
> > VIRTIO_F_ACCESS_PLATFORM (a.k.a. VIRTIO_F_IOMMU_PLATFORM) when the
> > device "can only access certain
On Fri, 22 May 2020 at 12:31, Alex Bennée wrote:
>
>
> Robert Foley writes:
>
> I think you need to look at adding:
>
> [sendemail]
> cccmd = scripts/get_maintainer.pl --nogit-fallback
>
> to your .git/config to ensure maintainers get pinged when you touch
> their subsystems. Eduardo and
On 5/22/20 4:32 AM, haris iqbal wrote:
> Hi,
>
> I am having some trouble with spinning up a VM using qemu. The
> description is below. Can someone please point me in the right
> direction?
>
> --
>
> Regards
> -Haris
>
>
> -- Forwarded message -
> From: haris iqbal
> Date:
On Fri, May 22, 2020 at 02:53:33PM -0500, Reza Arbab wrote:
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -889,10 +889,16 @@ static int spapr_dt_rng(void *fdt)
static void spapr_dt_rtas(SpaprMachineState *spapr, void *fdt)
{
MachineState *ms = MACHINE(spapr);
+SpaprMachineClass *smc = SPAP
NUMA nodes corresponding to GPU memory currently have the same
affinity/distance as normal memory nodes. Add a third NUMA associativity
reference point enabling us to give GPU nodes more distance.
This is guest visible information, which shouldn't change under a
running guest across migration betw
On Fri, 22 May 2020 at 11:59, Alex Bennée wrote:
>
>
> Robert Foley writes:
>
> > centos.aarch64 creates a CentOS 8 image.
> > Also added a new kickstart script used to build the centos.aarch64 image.
> >
> > Signed-off-by: Robert Foley
> > Reviewed-by: Peter Puhov
> > ---
>
> > --- /dev/null
Ok, thanks for checking again! So I'm closing this ticket now.
** Changed in: qemu
Status: Incomplete => Fix Released
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1693649
Title:
x86 pause
** Tags added: testcase
--
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1880225
Title:
Emulation of some arm programs fail with "Assertion `have_guest_base'
failed."
Status in QEMU:
New
Bug des
On 4/30/20 6:10 AM, Vladimir Sementsov-Ogievskiy wrote:
We are generally moving to int64_t for both offset and bytes parameters
on all io paths.
Main motivation is realization of 64-bit write_zeroes operation for
fast zeroing large disk chunks, up to the whole disk.
We chose signed type, to be
On Fri, 22 May 2020 at 11:34, Alex Bennée wrote:
>
>
> Robert Foley writes:
> >
> > +
> > +# efi-aarch64 probe
> > +# Check for efi files needed by aarch64 VMs.
> > +# By default we will use the efi included with QEMU.
> > +# Allow user to override the
> From: "Stefan Hajnoczi"
> Sent: Friday, May 22, 2020 7:17:22 PM
>
> The libqos VIRTIO code does not implement the packed virtqueue layout
> yet. Mask out the feature bit for now because tests have a habit of
> enabling all device feature
Sounds like we should rather fix these tests in the long
Patchew URL:
https://patchew.org/QEMU/20200522145520.6778-1-peter.mayd...@linaro.org/
Hi,
This series seems to have some coding style problems. See output below for
more information:
Message-id: 20200522145520.6778-1-peter.mayd...@linaro.org
Subject: [PATCH v2 0/9] target/arm: Convert 2-reg-s
Aleksandar Markovic <1880...@bugs.launchpad.net> writes:
> Public bug reported:
>
> This issue is observer with QEMU ToT, checked out around May 15th (but I
> believe it is present in current master too), and wasn't present in QEMU
> v5.0.0.
>
> I am using 32-bit Intel(R) Pentium(R) M processor
On 4/30/20 6:10 AM, Vladimir Sementsov-Ogievskiy wrote:
We are generally moving to int64_t for both offset and bytes parameters
on all io paths.
Main motivation is realization of 64-bit write_zeroes operation for
fast zeroing large disk chunks, up to the whole disk.
We chose signed type, to be
Confirming that I can no longer reproduce the bug with the latest master
(ae3aa5da96f4ccf0c2a28851449d92db9fcfad71). I have not bisected the bug,
though; at the moment I am not quite able to afford the time.
--
You received this bug notification because you are a member of qemu-
devel-ml, which i
Hi,
These changes all seem like a good idea. I will add them in the next
version of the patch.
Thanks & Regards,
-Rob
On Fri, 22 May 2020 at 10:40, Alex Bennée wrote:
>
>
> Robert Foley writes:
>
> > Added a new special variable QEMU_LOCAL=1, which
> > will indicate to take the QEMU binary from
Public bug reported:
This issue is observer with QEMU ToT, checked out around May 15th (but I
believe it is present in current master too), and wasn't present in QEMU
v5.0.0.
I am using 32-bit Intel(R) Pentium(R) M processor 1.73GHz host.
Arm cross-compiler is a standard cross-compiler that come
From: Mansour Ahmadi
When updating the PFLASH file contents, we should check for a
possible failure of blk_pwrite(). Similar to commit 3a688294e.
Reported-by: Coverity (CID 1357678 CHECKED_RETURN)
Signed-off-by: Mansour Ahmadi
Message-Id: <20200408003552.58095-1-mansour...@gmail.com>
[PMD: Add
The command 0x00 is used by this model since its origin (commit
05ee37ebf630). In this commit the command is described with a
amusing '/* ??? */' comment, probably meaning 'FIXME'.
switch (cmd) {
case 0x00: /* ??? */
...
This comment survived 12 years because the 0x00
flash-next-20200522
for you to fetch changes up to 1857b9db49770590483be44eb90993c42b2a5a99:
hw/block/pflash: Check return value of blk_pwrite() (2020-05-22 19:38:14 +0=
200)
- Remove unused timer in CFI01 flash,
- Cle
Rename the 'reset_flash' as 'mode_read_array' to make explicit we
do not reset the device, we simply set its internal state machine
in the READ_ARRAY mode. We do not reset the status register error
bits, as a device reset would do.
Reviewed-by: John Snow
Reviewed-by: Alistair Francis
Message-Id:
The 'CFI02' NOR flash was introduced in commit 29133e9a0fff, with
timing modelled. One year later, the CFI01 model was introduced
(commit 05ee37ebf630) based on the CFI02 model. As noted in the
header, "It does not support timings". 12 years later, we never
had to model the device timings. Time to
On Fri, 22 May 2020 at 17:15, Robert Foley wrote:
>
> For example:
> WARNING: ThreadSanitizer: data race (pid=11134)
> Atomic write of size 4 at 0x7bbce0ac by main thread (mutexes: write
> M875):
> #0 __tsan_atomic32_store (qemu-system-aarch64+0x394d84)
> #1 cpu_reset_interrupt hw/
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
target/i386/cpu.c | 6 +-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index 7a4a8e3847..dd31c1de5f 100644
--
In Makefile.objs, the ui/ directory is restricted to system-mode:
43 ifeq ($(CONFIG_SOFTMMU),y)
...
65 common-obj-y += ui/
66 common-obj-m += ui/
...
82 endif # CONFIG_SOFTMMU
Restrict the ui/ stub added in commit 2df9f5718df to only build
it for system-mode emulation.
Signed-off-by: Phili
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
include/hw/core/cpu.h | 7 ++-
hw/core/cpu.c | 2 ++
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/include/hw/core/cpu.h b/include/hw/core/
Commit ffaee83bcb2 moved qmp_query_target but forgot to remove
this include.
Reviewed-by: Alistair Francis
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
arch_init.c | 1 -
1 file changed, 1 deletion(-)
diff --g
Reviewed-by: Richard Henderson
Reviewed-by: Alistair Francis
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
exec.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/exec.c b/exec.c
index 5162f0d12f..6dfd314469 100644
--- a/
Reviewed-by: Richard Henderson
Reviewed-by: Cornelia Huck
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
target/s390x/cpu.c | 12 +---
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c
Reviewed-by: Alistair Francis
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
target/riscv/cpu.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/target/riscv/cpu.c b/target/riscv/cpu.c
ind
These objects are not required when configured with --disable-system.
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
util/Makefile.objs | 59 +-
1 file changed, 38 inser
Avoid building TCG when building only tools:
./configure --enable-tools --disable-system --disable-user
This saves us from running the soft-float tests enabled since
commit 76170102508.
Reviewed-by: Richard Henderson
Reviewed-by: Alistair Francis
Reviewed-by: Laurent Vivier
Tested-by: Laure
These stubs are not required when configured with --disable-system.
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
stubs/Makefile.objs | 52 ++---
1 file changed, 30 inserti
Reviewed-by: Alistair Francis
Reviewed-by: Richard Henderson
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
tests/Makefile.include | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/Makefile.include b/tests/Makefile.include
index 03a74
In the next commit we are going to remove some objects from the
util-obj-y variable (objects which are not used by user-mode,
when configured with --disable-system).
Then some system-mode tests are going to fail, due to the missing
objects:
$ make check-unit -k
LINKtests/test-iov
/usr/
Do not build the virtiofsd helper when configured with
--disable-system.
Reviewed-by: Richard Henderson
Acked-by: Dr. David Alan Gilbert
Reviewed-by: Laurent Vivier
Tested-by: Laurent Vivier
Signed-off-by: Philippe Mathieu-Daudé
---
Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion
This is the first part of a series reducing user-mode
dependencies. By stripping out unused code, the build
and testing time is reduced (as is space used by objects).
Part 1 (generic):
- reduce user-mode object list
- remove some migration code from user-mode
- remove cpu_get_crash_info()
Patches
The packed virtqueue layout was introduced in VIRTIO 1.1. It is a single
ring instead of a split avail/used ring design. There are CPU cache
advantages to this layout and it is also suited better to hardware
implementation.
The vhost-net backend has already supported packed virtqueues for some
tim
Vhost devices have a list of feature bits that the device backend is
allowed to control. The VIRTIO_F_RING_PACKED feature is a feature that
must be negotiated through all the way to the device backend. Add it so
the device backend can declare whether or not it supports the packed
ring layout.
Sign
Let vhost-scsi and vhost-user-scsi device backends determine whether
VIRTIO 1.0 and packed virtqueues are supported. It doesn't make sense to
handle these feature bits in QEMU since the device backend needs to
support them if we want to use them.
Signed-off-by: Stefan Hajnoczi
---
hw/scsi/vhost-
The VIRTIO 1.1 packed virtqueue layout improves performance and guest driver
support has been available since Linux v5.0. virtio-blk benchmarks show it is
beneficial for non-net devices too so I wrote patches to enable it for all
devices.
It turned out to be trickier than I expected because vhost
The libqos VIRTIO code does not implement the packed virtqueue layout
yet. Mask out the feature bit for now because tests have a habit of
enabling all device feature bits and we don't want packed virtqueues to
be enabled.
Later patches will enable VIRTIO_F_RING_PACKED so prepare libqos now.
Cc: T
Many vhost devices in QEMU currently do not involve the device backend
in feature negotiation. This seems fine at first glance for device types
without their own feature bits (virtio-net has many but other device
types have none).
This overlooks the fact that QEMU's virtqueue implementation and th
On 5/20/20 10:43 AM, Gerd Hoffmann wrote:
> From: Volker Rümelin
>
> Import win32 keyboard hooking code from project spice-gtk. This
> patch removes the extra left control key up/down input events
> inserted by Windows for the right alt key up/down input events
> with international keyboard layou
refactoring of cpus.c continues with two new modules extracted from it.
cpu-timers: responsible for the cpu timers state, and for access to
cpu clocks and ticks.
icount: counts the TCG instructions executed. As such it is specific to
the TCG accelerator. Therefore, it is built only under CONFIG_T
move the vcpu throttling functionality into its own module.
This functionality is not specific to any accelerator,
and it is used currently by migration to slow down guests to try to
have migrations converge, and by the cocoa MacOS UI to throttle speed.
cpu-throttle contains the controls to adjus
Motivation and higher level steps:
https://lists.gnu.org/archive/html/qemu-devel/2020-05/msg04628.html
v1 -> v2:
* 1/3 (cpu-throttle): provide a description in the commit message
* 2/3 (cpu-timers, icount): in this v2 separate icount from cpu-timers,
as icount is actually TCG-specific. Only b
each accelerator registers a new "CpusAccelInterface"
on initialization, providing functions for starting a vcpu,
kicking a vcpu, and sychronizing state.
This way the code in cpus.cc is now all general softmmu code,
nothing (or almost nothing) accelerator-specific anymore.
Signed-off-by: Claudio
I made the change discussed below.
> #ifdef fGEN_TCG_
> fGEN_TCG_();
> #else
> gen_helper_();
> #endif
In addition, here's a list of changes since I submitted v2 of the patch series
- Use Laurent's gensyscall.sh script to generate linux-user/hexagon/syscall_nr.h
- Handle mem_noshuf
- Help
From: Philippe Mathieu-Daudé
The TCG helpers where added in b92e5a22ec3 in softmmu_template.h.
probe_write() was added in there in 3b4afc9e75a to be moved out
to accel/tcg/cputlb.c in 3b08f0a9254, and was later refactored
as probe_access() in c25c283df0f.
Since it is a TCG specific helper, add a
On 5/22/20 6:37 PM, Philippe Mathieu-Daudé wrote:
> Signed-off-by: Philippe Mathieu-Daudé
> ---
> Cc: Sergio Andres Gomez Del Real
> Cc: Vincent Palatin
> Cc: Yu Ning
> Cc: Tao Wu
> Cc: haxm-t...@intel.com
> Cc: Colin Xu
> Cc: Hang Yuan
> Cc: David Chou
FYI Hang Yuan and David Chou emails
Move the accel selectors from the global Kconfig.host to their
own Kconfig file.
Reviewed-by: Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé
---
Makefile | 1 +
Kconfig.host | 7 ---
accel/Kconfig | 6 ++
3 files changed, 7 insertions(+), 7 deletions(-)
create mode 10064
Allow use of target-specific Kconfig file.
Reviewed-by: Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé
---
v3: Use base-arch() to include TARGET_BASE_ARCH/Kconfig
---
Makefile | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
index f8a45e1379..d
Expose the CONFIG_TCG selector to let minikconf.py uses it.
When building with --disable-tcg build, this helps to deselect
devices that are TCG-dependent.
Reviewed-by: Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé
---
Makefile | 1 +
accel/Kconfig | 3 +++
2 files changed, 4 ins
Signed-off-by: Philippe Mathieu-Daudé
---
Cc: Sergio Andres Gomez Del Real
Cc: Vincent Palatin
Cc: Yu Ning
Cc: Tao Wu
Cc: haxm-t...@intel.com
Cc: Colin Xu
Cc: Hang Yuan
Cc: David Chou
Cc: Wenchao Wang
---
MAINTAINERS | 6 ++
1 file changed, 6 insertions(+)
diff --git a/MAINTAINERS b/
Add a rule to return the base architecture for a QEMU target.
The current list of TARGET_BASE_ARCH is:
$ git grep TARGET_BASE_ARCH configure
configure:7785:TARGET_BASE_ARCH=""
configure:7795:TARGET_BASE_ARCH=i386
configure:7813:TARGET_BASE_ARCH=arm
configure:7846:TARGET_BAS
Having one entry per line helps reviews/refactors. As we are
going to modify the MINIKCONF variables, split them now to
ease further review.
Reviewed-by: Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé
---
Makefile | 9 ++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --g
The KVM files has been moved from target-ARCH to the target/ARCH/
folder in commit fcf5ef2a. Fix the pathname expansion.
Fixes: fcf5ef2a ("Move target-* CPU file into a target/ folder")
Reviewed-by: Richard Henderson
Reviewed-by: Thomas Huth
Signed-off-by: Philippe Mathieu-Daudé
---
MAINTAINER
Reviewed-by: Richard Henderson
Signed-off-by: Philippe Mathieu-Daudé
---
Cc: Paolo Bonzini
v2: Cover accel/accel.c & accel/Makefile.objs (thuth)
---
MAINTAINERS | 11 +++
1 file changed, 11 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 00c1c1ed8b..f7ee0c77f1 100644
--- a/
Add a rule to test if a string starts with a substring.
Signed-off-by: Philippe Mathieu-Daudé
---
rules.mak | 7 +++
1 file changed, 7 insertions(+)
diff --git a/rules.mak b/rules.mak
index 694865b63e..e39bee93d5 100644
--- a/rules.mak
+++ b/rules.mak
@@ -191,6 +191,13 @@ ne = $(if $(subst
Missing review:
- patch #4 'rules.mak: Add startwith rule'
- patch #5 'rules.mak: Add base-arch rule'.
This series include generic patches I took of the KVM/ARM
specific series which will follow.
- List orphan accelerators in MAINTAINERS
- Add accel/Kconfig
- Allow targets to use their how Kconfi
One might get caught trying to understand unexpected Makefile
behavior. Trailing backslash can help to split very long lines,
but are rather dangerous when nothing follow. Preserve other
developers debugging time by removing this one.
Reviewed-by: Thomas Huth
Reviewed-by: Alistair Francis
Signed
Robert Foley writes:
I think you need to look at adding:
[sendemail]
cccmd = scripts/get_maintainer.pl --nogit-fallback
to your .git/config to ensure maintainers get pinged when you touch
their subsystems. Eduardo and Cleber CC'd
> The ConsoleSocket object provides a socket interfac
For example:
WARNING: ThreadSanitizer: data race (pid=11134)
Atomic write of size 4 at 0x7bbce0ac by main thread (mutexes: write M875):
#0 __tsan_atomic32_store (qemu-system-aarch64+0x394d84)
#1 cpu_reset_interrupt hw/core/cpu.c:107:5 (qemu-system-aarch64+0x842f90)
#2 arm_cpu_set
We have a very frequent pattern of creating coroutine from function
with several arguments:
- create structure to pack parameters
- create _entry function to call original function taking parameters
from struct
- do different magic to handle completion: set ret to NOT_DONE or
EINPROG
This includes details on how to build and test with TSan
both inside a docker and outside.
Signed-off-by: Robert Foley
---
docs/devel/testing.rst | 72 ++
1 file changed, 72 insertions(+)
diff --git a/docs/devel/testing.rst b/docs/devel/testing.rst
index
This allows us to see the name of the thread in tsan
warning reports such as this:
Thread T7 'CPU 1/TCG' (tid=24317, running) created by main thread at:
Signed-off-by: Robert Foley
---
util/qemu-thread-posix.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/util/qemu-thread-posix.c b/ut
We are going to keep coroutine-wrappers code (structure-packing
parameters, BDRV_POLL wrapper functions) in a separate auto-generated
files. So, we'll need a header with declaration of original _co_
functions, for those which are static now. As well, we'll need
declarations for wrapper functions. D
Most of coroutine wrappers already follow this notation:
We have coroutine_fn bdrv_co_(), which
is the core functions, and wrapper, which does polling loope is called
bdrv_().
The only outsiders are bdrv_prwv_co and bdrv_common_block_status_above
wrappers. Let's refactor the to behave as the othe
For example:
WARNING: ThreadSanitizer: data race (pid=23406)
Atomic read of size 4 at 0x7b13e3c8 by thread T7:
#0 __tsan_atomic32_load (qemu-system-aarch64+0x39a36c)
#1 qht_do_lookup util/qht.c:495:17 (qemu-system-aarch64+0xd82f7a)
#2 qht_lookup_custom util/qht.c:539:11 (qemu-sys
From: "Emilio G. Cota"
Signed-off-by: Robert Foley
---
util/qht.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/util/qht.c b/util/qht.c
index aa51be3c52..67e5d5b916 100644
--- a/util/qht.c
+++ b/util/qht.c
@@ -348,6 +348,7 @@ static inline void qht_chain_destroy(const struct
qht_bucket *
Hi all!
After a long delay (~year) here is a v3.
The aim of the series is to reduce code-duplication and writing
parameters structure-packing by hand around coroutine function wrappers.
It's an alternative to "[PATCH v3] block: Factor out bdrv_run_co()"
patch.
Benefits:
- no code duplication
Initially put several files into blacklist that were
causing the most problems, namely bitops.c and bitmap.c.
Signed-off-by: Robert Foley
---
configure | 3 ++-
tests/tsan/blacklist.tsan | 5 +
2 files changed, 7 insertions(+), 1 deletion(-)
create mode 100644 tests/tsan/bla
For example:
WARNING: ThreadSanitizer: data race (pid=14665)
Write of size 4 at 0x7b1c7890 by thread T99:
#0 worker_thread util/thread-pool.c:112:20 (qemu-system-aarch64+0xd52108)
#1 qemu_thread_start util/qemu-thread-posix.c:519:9
(qemu-system-aarch64+0xd5be30)
Previous read of s
For example:
WARNING: ThreadSanitizer: data race (pid=35425)
Write of size 4 at 0x7bbc00ac by main thread (mutexes: write M875):
#0 cpu_reset_interrupt hw/core/cpu.c:107:28 (qemu-system-aarch64+0x843790)
#1 arm_cpu_set_irq target/arm/cpu.c (qemu-system-aarch64+0x616265)
#2 qemu_se
For example:
Atomic write of size 8 at 0x7b4800113c28 by main thread (mutexes: write M30):
#0 __tsan_atomic64_exchange (qemu-system-aarch64+0x386f85)
#1 aio_bh_poll util/async.c:146:5 (qemu-system-aarch64+0xcd1f61)
#2 aio_dispatch util/aio-posix.c:380:5 (qemu-system-aarch64+0xcd8abb)
These annotations will allow us to give tsan
additional hints. For example, we can inform
tsan about reads/writes to ignore to silence certain
classes of warnings.
We can also annotate threads so that the proper thread
naming shows up in tsan warning results.
Signed-off-by: Robert Foley
---
inc
Added a new docker for ubuntu 20.04.
This docker has support for Thread Sanitizer
including one patch we need in one of the header files.
https://github.com/llvm/llvm-project/commit/a72dc86cd
This command will build with tsan enabled:
make docker-test-build-ubuntu2004 V=1 TSAN=1
Also added the TS
From: "Emilio G. Cota"
The radix tree is append-only, but we can fail to insert
a PageDesc if the insertion races with another thread.
Signed-off-by: Emilio G. Cota
Signed-off-by: Robert Foley
---
accel/tcg/translate-all.c | 9 +
1 file changed, 9 insertions(+)
diff --git a/accel/tcg
From: "Emilio G. Cota"
Instead of open-coding it.
While at it, make sure that all accesses to the list are
performed while holding the list's lock.
Reviewed-by: Richard Henderson
Reviewed-by: Alex Bennée
Signed-off-by: Emilio G. Cota
Signed-off-by: Robert Foley
---
cpus-common.c |
From: "Emilio G. Cota"
Signed-off-by: Emilio G. Cota
Signed-off-by: Robert Foley
[RF: Minor changes to fix some checkpatch errors]
---
accel/tcg/translate-all.c | 10 +-
include/tcg/tcg.h | 3 ++-
tcg/tcg.c | 19 ---
3 files changed, 27 insertio
From: "Emilio G. Cota"
Signed-off-by: Emilio G. Cota
Signed-off-by: Robert Foley
---
include/qemu/thread.h | 39 ---
1 file changed, 36 insertions(+), 3 deletions(-)
diff --git a/include/qemu/thread.h b/include/qemu/thread.h
index e50a073889..43fc094b96 100
Fixed several tsan warnings. e.g.
WARNING: ThreadSanitizer: data race (pid=35425)
Read of size 1 at 0x557cd83aee28 by thread T7:
#0 curr_cflags include/exec/exec-all.h:460:13 (qemu-system-aarch64+0x4b7f27)
#1 cpu_exec accel/tcg/cpu-exec.c:730:26 (qemu-system-aarch64+0x4b7f27)
#2 tcg_
From: Lingfeng Yang
We tried running QEMU under tsan in 2016, but tsan's lack of support for
longjmp-based fibers was a blocker:
https://groups.google.com/forum/#!topic/thread-sanitizer/se0YuzfWazw
Fortunately, thread sanitizer gained fiber support in early 2019:
https://reviews.llvm.org/D54
From: "Emilio G. Cota"
I was after adding qemu_spin_destroy calls, but while at
it I noticed that we are leaking some memory.
Signed-off-by: Emilio G. Cota
Signed-off-by: Robert Foley
---
accel/tcg/cputlb.c | 15 +++
exec.c | 1 +
include/exec/exec-all.h |
From: "Emilio G. Cota"
It will be used for TSAN annotations.
Signed-off-by: Emilio G. Cota
Signed-off-by: Robert Foley
---
include/qemu/thread.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/include/qemu/thread.h b/include/qemu/thread.h
index d22848138e..e50a073889 100644
--- a/inclu
This patch series continues the work done by Emilio Cota and others to add
Thread Sanitizer (TSan) support to QEMU.
The starting point for this work was Emilio's branch here:
https://github.com/cota/qemu/commits/tsan
specifically this commit: 0be125fc0afd47218b34d2019abdd19b644f3199
The purpose o
1 - 100 of 181 matches
Mail list logo