[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 1/2] linux-user/s390x: signal with SIGFPE on compare-and-t

From: Richard Henderson
Subject: Re: [PATCH v3 1/2] linux-user/s390x: signal with SIGFPE on compare-and-trap
Date: Fri, 9 Jul 2021 09:50:37 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0

On 7/9/21 9:04 AM, Jonathan Albrecht wrote:
Currently when a compare-and-trap instruction is executed, qemu will
always raise a SIGILL signal. On real hardware, a SIGFPE is raised.

Change the PGM_DATA case in cpu_loop to follow the behavior in
linux kernel /arch/s390/kernel/traps.c.
  * Only raise SIGILL if DXC == 0
  * If DXC matches a non-simulated IEEE exception, raise SIGFPE with
    correct si_code
  * Raise SIGFPE with si_code == 0 for everything else

When applied on20210705210434.45824-2-iii@linux.ibm.com, this fixes
crashes in the java jdk such as the linked bug.

Signed-off-by: Jonathan Albrecht<jonathan.albrecht@linux.vnet.ibm.com>
  linux-user/s390x/cpu_loop.c | 54 +++++++++++++++++++++++--------------
  1 file changed, 34 insertions(+), 20 deletions(-)

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>


reply via email to

[Prev in Thread] Current Thread [Next in Thread]