From: Thomas Huth <thuth@redhat.com>
To: Ilya Leoshkevich <iii@linux.ibm.com>,
Laurent Vivier <laurent@vivier.eu>,
Richard Henderson <richard.henderson@linaro.org>,
David Hildenbrand <david@redhat.com>
Cc: qemu-devel@nongnu.org, qemu-s390x@nongnu.org
Subject: Re: [PATCH 0/2] linux-user/s390x: Fix single-stepping SVC
Date: Wed, 31 May 2023 16:37:41 +0200 [thread overview]
Message-ID: <d12da5db-da30-b774-1ec7-8e23b9102e62@redhat.com> (raw)
In-Reply-To: <20230510230213.330134-1-iii@linux.ibm.com>
On 11/05/2023 01.02, Ilya Leoshkevich wrote:
> Hi,
>
> I noticed that single-stepping SVC runs two instructions instead of
> one. The reason is that EXCP_SVC masks EXCP_DEBUG.
> Patch 1 fixes this problem, patch 2 adds a test.
>
> Btw, there is at least one more problem in that area, namely
> single-stepping instructions that cause e.g. SIGILL. Using the
> existing signals-s390x test as an example:
>
> (gdb) x/i $pc
> => 0x1001740 <illegal_op>: .long 0x000007fe
>
> (gdb) si
> Program received signal SIGILL, Illegal instruction.
> (gdb) x/i $pc
> => 0x1001742 <after_illegal_op>: br %r14
> # So far so good.
>
> (gdb) si
> (gdb) x/i $pc
> => 0x10017b6 <handle_signal+6>: lay %r15,-344(%r15)
> # Missed the first signal handler instruction!
>
> I'm not sure what to do about it - the trivial fix to add
> gdb_handlesig(cpu, 0) to the end of handle_pending_signal() caused GDB
> to hang, and I haven't looked further yet.
>
> Best regards,
> Ilya
>
> Ilya Leoshkevich (2):
> linux-user/s390x: Fix single-stepping SVC
> tests/tcg/s390x: Test single-stepping SVC
If there are no disagreements, I can take this through my s390x tree. Queued
it for my next pull request now.
Thomas
prev parent reply other threads:[~2023-05-31 14:38 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-10 23:02 [PATCH 0/2] linux-user/s390x: Fix single-stepping SVC Ilya Leoshkevich
2023-05-10 23:02 ` [PATCH 1/2] " Ilya Leoshkevich
2023-05-11 10:55 ` Michael Tokarev
2023-05-11 11:20 ` Ilya Leoshkevich
2023-05-11 12:32 ` Michael Tokarev
2023-05-11 13:45 ` Ilya Leoshkevich
2023-05-11 13:50 ` Michael Tokarev
2023-05-10 23:02 ` [PATCH 2/2] tests/tcg/s390x: Test " Ilya Leoshkevich
2023-05-11 10:51 ` Alex Bennée
2023-07-07 8:37 ` Thomas Huth
2023-05-31 14:37 ` Thomas Huth [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d12da5db-da30-b774-1ec7-8e23b9102e62@redhat.com \
--to=thuth@redhat.com \
--cc=david@redhat.com \
--cc=iii@linux.ibm.com \
--cc=laurent@vivier.eu \
--cc=qemu-devel@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=richard.henderson@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).