https://bugs.kde.org/show_bug.cgi?id=273489

Andreas Arnez <ar...@linux.ibm.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REPORTED                    |RESOLVED
                 CC|                            |ar...@linux.ibm.com
         Resolution|---                         |FIXED

--- Comment #4 from Andreas Arnez <ar...@linux.ibm.com> ---
(In reply to Christian Borntraeger from comment #1)
> We will need to issue SIGSEGV/SIGBUS from some instructions (e.g. crypto for
> wrong function codes will cause a specification exception that causes Linux
> to deliver a SIGSEGV).
That's not quite correct.  Instead, specification exceptions lead to SIGILL. 
For a full overview of how architectural exceptions are translated to Linux
signals, see the section "Exception Interface" in the s390x ABI:
https://github.com/ibm/s390x-abi

In the meantime we added lots of checks in the translator, to yield SIGILL via
Ijk_NoDecode in cases where the hardware would generate specification
exceptions.  See, e.g. the many invocations of s390_insn_assert() in
guest_s390_toIR.c.
Similarly, the extension handlers in extension-s390x.c yield SIGILL by
returning ExtErr_Illop when they recognize inputs that would generate a
specification exception.
These two mechanisms cover almost all relevant cases where we like to
synthesize signals for bad instructions.  A few special cases might be missing,
particularly those that require run-time checks such as for the "load and add"
operand alignment.  If the need arises, those should be addressed with separate
Bugs.

SIGSEGV/SIGBUS, on the other hand, are generated for translation exceptions
only.  This should not be specific to s390x.

With this, I consider this Bug "fixed".

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to