[PATCH RFC 0/1] linux-user/s390x: save/restore condition code state during signal handling

Jonathan Albrecht posted 1 patch 2 years, 10 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/next-importer-push tags/patchew/20210610185823.14817-1-jonathan.albrecht@linux.vnet.ibm.com
Maintainers: Thomas Huth <thuth@redhat.com>, Cornelia Huck <cohuck@redhat.com>, Laurent Vivier <laurent@vivier.eu>
linux-user/s390x/signal.c | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)
[PATCH RFC 0/1] linux-user/s390x: save/restore condition code state during signal handling
Posted by Jonathan Albrecht 2 years, 10 months ago
Peter Bao <ruixin.bao@ibm.com> and I have been looking at some issues with
qemu user mode x86_64 host/s390x guest when running go1.14+ executables.
From the qemu cpu traces, it looks like the condition code is not restored
after a signal handler is run. This affects go1.14+ because it uses signals
heavily to implement the async preempt feature in the goroutine scheduler
that was added in go1.14.

This patch tries save and restore the condition code related fields when
handling a signal. We're submitting it as an RFC since we're new to qemu and
not sure if this is s390x specific. We have some C code (s390x specific)
that reproduces the issue and can try to add it as a unit test.

Jonathan Albrecht (1):
  linux-user/s390x: save/restore condition code state during signal
    handling

 linux-user/s390x/signal.c | 35 +++++++++++++++++++++++++++++++++++
 1 file changed, 35 insertions(+)

-- 
2.31.1