Henderson
Signed-off-by: Ilya Leoshkevich
---
linux-user/strace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/linux-user/strace.c b/linux-user/strace.c
index 660f942f599..54169096aa4 100644
--- a/linux-user/strace.c
+++ b/linux-user/strace.c
@@ -701,7 +701,7 @@
Add a small test to prevent regressions.
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/linux/linux-shmat-null.c | 38
1 file changed, 38 insertions(+)
create mode 100644 tests/tcg/multiarch/linux/linux-shmat-null.c
diff --git
ues, and adds a test.
Best regards,
Ilya
Ilya Leoshkevich (4):
linux-user: Fix semctl() strace
linux-user: Fix shmat() strace
linux-user: Fix shmat(NULL) for h != g
tests/tcg: Test shmat(NULL)
linux-user/mmap.c| 2 +-
linux-user/strace.c |
t;Fix warnings that would be caused by gcc flag
-Wwrite-strings")
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
linux-user/strace.c | 8 ++--
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/linux-user/strace.c b/linux-user/strace.c
index 9934e2208e2..6
", which is set after
mmap_find_vma(), is true.
Fixes: 78bc8ed9a8f0 ("linux-user: Rewrite target_shmat")
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
linux-user/mmap.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/linux-user/mmap.c b
Hi,
I noticed that while shmat() now works with /proc/self/maps,
shmat(NULL) got broken. This series fixes that along with two related
strace issues, and adds a test.
Best regards,
Ilya
Ilya Leoshkevich (4):
linux-user: Fix semctl() strace
linux-user: Fix shmat() strace
linux-user: Fix
The indices of arguments passed to print_shmat() are all off-by-1,
because arg1 is the ipc() command. Fix them.
New output for linux-shmat-maps test:
3501769 shmat(4784214,0x0080,SHM_RND) = 0
Fixes: 9f7c97324c27 ("linux-user: Add strace for shmat")
Signed-of
t;Fix warnings that would be caused by gcc flag
-Wwrite-strings")
Signed-off-by: Ilya Leoshkevich
---
linux-user/strace.c | 8 +++-
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/linux-user/strace.c b/linux-user/strace.c
index 9934e2208e2..9be71af4016 100644
--- a/linux-use
Add a small test to prevent regressions.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/linux/linux-shmat-null.c | 38
1 file changed, 38 insertions(+)
create mode 100644 tests/tcg/multiarch/linux/linux-shmat-null.c
diff --git a/tests/tcg/multiarch/linux/linux
", which is set after
mmap_find_vma(), is true.
Fixes: 78bc8ed9a8f0 ("linux-user: Rewrite target_shmat")
Signed-off-by: Ilya Leoshkevich
---
linux-user/mmap.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/linux-user/mmap.c b/linux-user/mmap.c
index e88faf1ab3d.
From: Ido Plat
Otherwise TCG would assume the register that holds t1 would be constant
and reuse whenever it needs the value within it.
Cc: qemu-sta...@nongnu.org
Fixes: f1ea739bd598 ("target/s390x: Use tcg_constant_* in local contexts")
Reviewed-by: Ilya Leoshkevich
Reviewed-b
Add a small test to prevent regressions.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/ts.c| 35 +
2 files changed, 36 insertions(+)
create mode 100644 tests/tcg/s390x/ts.c
diff --git a/tests/tcg/s390x
Add a small test to prevent regressions.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/ts.c| 35 +
2 files changed, 36 insertions(+)
create mode 100644 tests/tcg/s390x/ts.c
diff --git a/tests/tcg/s390x
From: Ido Plat
Otherwise TCG would assume the register that holds t1 would be constant
and reuse whenever it needs the value within it.
Reviewed-by: Ilya Leoshkevich
[iii: Adjust a newline and capitalization]
Signed-off-by: Ido Plat
---
target/s390x/tcg/translate.c | 3 ++-
1 file changed, 2
Currently DEBUG_REMAP is a macro that needs to be manually #defined to
be activated, which makes it hard to have separate build directories
dedicated to testing the code with it. Promote it to a meson option.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/qemu.h | 6 ++
linux
returning - instead.
Fixes: Coverity CID 1539966
Fixes: d547e711a8a5 ("gdbstub: Implement follow-fork-mode child")
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/gdbstub/user.c b/gdbstub/user.c
index 7f9f19a1249..0
On Wed, Jan 31, 2024 at 02:10:55PM +0100, Philippe Mathieu-Daudé wrote:
> On 31/1/24 01:18, Ilya Leoshkevich wrote:
> > Like TARGET_NR_setuid, TARGET_NR_setgroups should affect only the
> > calling thread, and not the entire process. Therefore, implement it
> > using a syscall
) unless the address is sufficiently
> + * aligned for the host, we'll need to check both.
> + * TODO: Could be fixed with softmmu.
> + */
Are there any plans to introduce softmmu to qemu-user?
[...]
Reviewed-by: Ilya Leoshkevich
Please consider adding the reproducer to the series:
&
Currently ts_tid contains the parent tid after fork(), which is not
correct. So far it has not affected anything, but the upcoming
follow-fork-mode child support relies on the correct value, so fix it.
Reviewed-by: Alex Bennée
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c | 1 +
linux
A CPU's TaskState is stored in the CPUState's void *opaque field,
accessing which is somewhat awkward due to having to use a cast.
Introduce a wrapper and use it everywhere.
Suggested-by: Alex Bennée
Signed-off-by: Ilya Leoshkevich
---
bsd-user/bsd-file.h | 2 +-
bsd-user/qemu.h
past exec() though). Patches 1-10
are preliminary refactorings, patch 11 is the implementation, and patch
12 is the test.
[1] https://lists.gnu.org/archive/html/qemu-devel/2024-01/msg06424.html
Best regards,
Ilya
Ilya Leoshkevich (12):
gdbstub: Support disablement in a multi-threaded process
{
that is initialized on fork(),
decides the current owner of the gdbserver socket, and is terminated
when one of the two processes is detached. The logic for the parent and
the child is the same, only the initial state is different.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 212
The upcoming follow-fork-mode child support needs to perform certain
actions when GDB switches between the stopped parent and the stopped
child. Introduce a user-specific hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 11 +--
gdbstub/internals.h | 1 +
gdbstub
On Mon, 2024-02-19 at 14:05 +0100, Ilya Leoshkevich wrote:
> On Sat, 2024-02-17 at 10:21 -1000, Richard Henderson wrote:
> > On 2/16/24 03:05, Ilya Leoshkevich wrote:
> > > The upcoming follow-fork-mode child support will require
> > > disabling
> > > gdbstub i
The upcoming follow-fork-mode child support requires knowing the child
pid. Pass it down.
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 2 +-
gdbstub/user.c | 2 +-
include/gdbstub/user.h | 2 +-
linux-user/main.c | 2 +-
4 files
The upcoming follow-fork-mode child support needs to perform certain
actions when GDB detaches from the stopped parent or the stopped child.
Introduce a user-specific hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 6 ++
gdbstub/internals.h | 1 +
gdbstub/user.c
Add follow-fork-mode child and and follow-fork-mode parent tests.
Check for the obvious pitfalls, such as lingering breakpoints,
catchpoints, and single-step mode.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/Makefile.target | 17 +-
tests/tcg/multiarch/follow-fork
The upcoming follow-fork-mode child support requires post-fork message
exchange between the parent and the child. Prepare gdbserver_fork() for
this purpose. Rename it to gdbserver_fork_end() to better reflect its
purpose.
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
bsd
The upcoming follow-fork-mode child support requires knowing when
fork() is about to happen in order to initialize its state. Add a hook
for that.
Reviewed-by: Alex Bennée
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 1 +
gdbstub/user.c | 4
include/gdbstub/user.h
.
Reviewed-by: Alex Bennée
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 19 +++
1 file changed, 15 insertions(+), 4 deletions(-)
diff --git a/gdbstub/user.c b/gdbstub/user.c
index 14918d1a217..3ce20b7bbfc 100644
--- a/gdbstub/user.c
+++ b/gdbstub
The upcoming follow-fork-mode child support requires knowing the child
pid. Pass it down.
Reviewed-by: Alex Bennée
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
bsd-user/freebsd/os-proc.h | 6 +++---
bsd-user/main.c | 4 +++-
bsd-user/qemu.h | 2
The upcoming follow-fork-mode child support requires advertising the
fork-events feature, which is user-specific. Introduce a user-specific
hook for this.
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 12 +---
gdbstub/internals.h | 1
On Sat, 2024-02-17 at 10:21 -1000, Richard Henderson wrote:
> On 2/16/24 03:05, Ilya Leoshkevich wrote:
> > The upcoming follow-fork-mode child support will require disabling
> > gdbstub in the parent process, which may have multiple threads
> > (which
> > are represen
that is initialized on fork(),
decides the current owner of the gdbserver socket, and is terminated
when one of the two processes is detached. The logic for the parent and
the child is the same, only the initial state is different.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 212
Add follow-fork-mode child and and follow-fork-mode parent tests.
Check for the obvious pitfalls, such as lingering breakpoints,
catchpoints, and single-step mode.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/Makefile.target | 17 +-
tests/tcg/multiarch/follow-fork
The upcoming follow-fork-mode child support requires post-fork message
exchange between the parent and the child. Prepare gdbserver_fork() for
this purpose. Rename it to gdbserver_fork_end() to better reflect its
purpose.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 3
The upcoming follow-fork-mode child support needs to perform certain
actions when GDB switches between the stopped parent and the stopped
child. Introduce a user-specific hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 11 +--
gdbstub/internals.h | 1 +
gdbstub
The upcoming follow-fork-mode child support requires knowing the child
pid. Pass it down.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/freebsd/os-proc.h | 6 +++---
bsd-user/main.c | 4 +++-
bsd-user/qemu.h | 2 +-
linux-user/main.c | 4 +++-
linux-user
The upcoming follow-fork-mode child support needs to perform certain
actions when GDB detaches from the stopped parent or the stopped child.
Introduce a user-specific hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 6 ++
gdbstub/internals.h | 1 +
gdbstub/user.c
t exec() though). Patches 1-9
are preliminary refactorings, patch 10 is the implementation, and patch
11 is the test.
[1] https://lists.gnu.org/archive/html/qemu-devel/2024-01/msg06424.html
Best regards,
Ilya
Ilya Leoshkevich (11):
gdbstub: Support disablement in a multi-threaded process
{lin
The upcoming follow-fork-mode child support requires knowing the child
pid. Pass it down.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 2 +-
gdbstub/user.c | 2 +-
include/gdbstub/user.h | 2 +-
linux-user/main.c | 2 +-
4 files changed, 4 insertions(+), 4 deletions
The upcoming follow-fork-mode child support requires knowing when
fork() is about to happen in order to initialize its state. Add a hook
for that.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 1 +
gdbstub/user.c | 4
include/gdbstub/user.h | 5 +
linux-user
-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 19 +++
1 file changed, 15 insertions(+), 4 deletions(-)
diff --git a/gdbstub/user.c b/gdbstub/user.c
index 14918d1a217..e17f7ece908 100644
--- a/gdbstub/user.c
+++ b/gdbstub/user.c
@@ -356,16 +356,27 @@ int gdbserver_start(const char
The upcoming follow-fork-mode child support requires advertising the
fork-events feature, which is user-specific. Introduce a user-specific
hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 12 +---
gdbstub/internals.h | 1 +
gdbstub/user.c | 4
3
Currently ts_tid contains the parent tid after fork(), which is not
correct. So far it has not affected anything, but the upcoming
follow-fork-mode child support relies on the correct value, so fix it.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c | 1 +
linux-user/main.c | 1 +
2 files
On Fri, 2024-02-16 at 11:44 +, Alex Bennée wrote:
> Ilya Leoshkevich writes:
>
> > v4:
> > https://lists.gnu.org/archive/html/qemu-devel/2024-01/msg05857.html
> > v4 -> v5: Fix the probe_proc_self_mem vs probe_proc_self_mem()
> > typo.
> > A
On Tue, 2024-02-13 at 09:54 -1000, Richard Henderson wrote:
> On 1/29/24 05:26, Ilya Leoshkevich wrote:
> > On Tue, Jan 02, 2024 at 12:57:57PM +1100, Richard Henderson wrote:
> > > Work much harder to get alignment and mapping beyond the end
> > > of the file correct. B
Test the lowest and the highest real-time signals.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/linux/linux-sigrtminmax.c | 41 +++
1 file changed, 41 insertions(+)
create mode 100644 tests/tcg/multiarch/linux/linux-sigrtminmax.c
diff --git a/tests/tcg/multiarch
will need it.
Signed-off-by: Ilya Leoshkevich
---
linux-user/signal.c | 18 +-
1 file changed, 13 insertions(+), 5 deletions(-)
diff --git a/linux-user/signal.c b/linux-user/signal.c
index d3e62ab030f..a81533b563a 100644
--- a/linux-user/signal.c
+++ b/linux-user/signal.c
@@ -511,13
the middle instead. Patch 1 makes
the change, patch 2 is a test.
Best regards,
Ilya
Ilya Leoshkevich (2):
linux-user: Map low priority rt signals
tests/tcg: Add SIGRTMIN/SIGRTMAX test
linux-user/signal.c | 18 +---
tests/tcg/multiarch/linux/linux-sigrtminmax.c
On Mon, Feb 05, 2024 at 11:11:06AM +, Richard Purdie wrote:
> On Mon, 2024-02-05 at 13:05 +1000, Richard Henderson wrote:
> > On 1/26/24 23:52, Richard Purdie wrote:
> > > On Fri, 2024-01-26 at 16:33 +0300, Michael Tokarev wrote:
> > > > 26.01.2024 16:03, Richard Purdie wrote:
> > > > > I've
On Wed, 2024-02-07 at 15:02 +, Alex Bennée wrote:
> Ilya Leoshkevich writes:
>
> > v2:
> > https://lists.gnu.org/archive/html/qemu-devel/2024-02/msg00890.html
> > v2 -> v3: Structure the meson check similar to have_asan_fiber;
> > Reduce th
IRC. I had several
problems with it, which this series resolves.
Best regards,
Ilya
Ilya Leoshkevich (4):
tests/vm: Set UseDNS=no in the sshd configuration
tests/vm/freebsd: Reload the sshd configuration
test-util-filemonitor: Adapt to the FreeBSD inotify rename semantics
meson
After console_sshd_config(), the SSH server needs to be nudged to pick
up the new configs. The scripts for the other BSD flavors already do
this with a reboot, but a simple reload is sufficient.
Reviewed-by: Thomas Huth
Signed-off-by: Ilya Leoshkevich
---
tests/vm/freebsd | 1 +
1 file changed
reeBSD the inotify functions are defined in libinotify.so. Add it
to the dependencies.
Signed-off-by: Ilya Leoshkevich
---
meson.build | 23 +++
util/meson.build | 6 +-
2 files changed, 24 insertions(+), 5 deletions(-)
diff --git a/meson.build b/meson.build
in the server
config.
Reviewed-by: Thomas Huth
Signed-off-by: Ilya Leoshkevich
---
tests/vm/basevm.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py
index 61725b83254..c0d62c08031 100644
--- a/tests/vm/basevm.py
+++ b/tests/vm/ba
txt
Event id=1 event=0 file=two.txt
Expected event 0 but got 2
This difference in behavior is not expected to break the real users, so
teach the test to accept it.
Suggested-by: Daniel P. Berrange
Signed-off-by: Ilya Leoshkevich
---
tests/unit/test-util-filemonitor.c | 8
2865.html
v1 -> v2: Fix !CONFIG_INT128 builds (Richard).
Hi,
Ido reported that we are missing the CVDG emulation (which is very
similar to the existing CVD emulation). This series adds it along with
a test.
Best regards,
Ilya
Ilya Leoshkevich (4):
target/s390x: Emulate CVDG
target/s390x:
Check the CVB's, CVBY's, and CVBG's corner cases.
Co-developed-by: Pavel Zbitskiy
Reviewed-by: Thomas Huth
Tested-by: Thomas Huth
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/cvb.c | 102
2 files
Check the CVD's, CVDY's, and CVDG's corner cases.
Reviewed-by: Thomas Huth
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/cvd.c | 63 +
2 files changed, 64 insertions(+)
create mode 100644 tests/tcg/s390x
CVDG is the same as CVD, except that it converts 64 bits into 128,
rather than 32 into 64. Create a new helper, which uses Int128
wrappers.
Reported-by: Ido Plat
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
target/s390x/helper.h| 1 +
target/s390x/tcg/insn
Convert to Binary - counterparts of the already implemented Convert
to Decimal (CVD*) instructions.
Example from the Principles of Operation: 25594C becomes 63FA.
Co-developed-by: Pavel Zbitskiy
Signed-off-by: Ilya Leoshkevich
---
target/s390x/helper.h| 2 +
target/s390x/tcg/insn
On Mon, Feb 05, 2024 at 07:36:32PM +0100, Philippe Mathieu-Daudé wrote:
> Hi Ilya,
>
> On 5/2/24 19:11, Ilya Leoshkevich wrote:
> > make vm-build-freebsd fails with:
> >
> > ld: error: undefined symbol: inotify_init1
> > >>> referenced by f
On Mon, Feb 05, 2024 at 06:04:27PM +0100, Thomas Huth wrote:
> On 02/02/2024 15.11, Ilya Leoshkevich wrote:
> > Convert to Binary - counterparts of the already implemented Convert
> > to Decimal (CVD*) instructions.
> > Example from the Principles of Operation: 25594C beco
txt
Event id=1 event=0 file=two.txt
Expected event 0 but got 2
This difference in behavior is not expected to break the real users, so
teach the test to accept it.
Suggested-by: Daniel P. Berrange
Signed-off-by: Ilya Leoshkevich
---
tests/unit/test-util-filemonitor.c | 8
in the server
config.
Reviewed-by: Thomas Huth
Signed-off-by: Ilya Leoshkevich
---
tests/vm/basevm.py | 2 ++
1 file changed, 2 insertions(+)
diff --git a/tests/vm/basevm.py b/tests/vm/basevm.py
index 61725b83254..c0d62c08031 100644
--- a/tests/vm/basevm.py
+++ b/tests
After console_sshd_config(), the SSH server needs to be nudged to pick
up the new configs. The scripts for the other BSD flavors already do
this with a reboot, but a simple reload is sufficient.
Signed-off-by: Ilya Leoshkevich
---
tests/vm/freebsd | 1 +
1 file changed, 1 insertion(+)
diff
On FreeBSD inotify functions are defined in libinotify.so. Add it to
the dependencies.
Signed-off-by: Ilya Leoshkevich
---
meson.build | 12 +++-
util/meson.build | 6 +-
2 files changed, 16 insertions(+), 2 deletions(-)
diff --git a/meson.build b/meson.build
index b5d6dc94a83..
ded to verify that my qemu-user changes didn't break BSD, and
Daniel Berrange suggested vm-build-freebsd on IRC. I had several
problems with it, which this series resolves.
Best regards,
Ilya
Ilya Leoshkevich (4):
tests/vm: Set UseDNS=no in the sshd configuration
tests/vm/freebsd: Reload the s
,
> > > but not true on *BSD, hence the undefined symbol.
> > >
> > > We need to augment the header file check with a linker
> > > symbol check for the C library.
> > >
> > > If we wanted to also check for -linotify that'd make
> > > it port
The upcoming follow-fork-mode child support needs to perform certain
actions when GDB detaches from the stopped parent or the stopped child.
Introduce a user-specific hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 6 ++
gdbstub/internals.h | 1 +
gdbstub/user.c
The upcoming follow-fork-mode child support needs to perform certain
actions when GDB switches between the stopped parent and the stopped
child. Introduce a user-specific hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 11 +--
gdbstub/internals.h | 1 +
gdbstub
The upcoming follow-fork-mode child support requires knowing the child
pid. Pass it down.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/freebsd/os-proc.h | 6 +++---
bsd-user/main.c | 4 +++-
bsd-user/qemu.h | 2 +-
linux-user/main.c | 4 +++-
linux-user
The upcoming follow-fork-mode child support requires knowing when
fork() is about to happen in order to initialize its state. Add a hook
for that.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 1 +
gdbstub/user.c | 4
include/gdbstub/user.h | 5 +
linux-user
Currently ts_tid contains the parent tid after fork(), which is not
correct. So far it has not affected anything, but the upcoming
follow-fork-mode child support relies on the correct value, so fix it.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c | 1 +
linux-user/main.c | 1 +
2 files
The upcoming follow-fork-mode child support requires knowing the child
pid. Pass it down.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 2 +-
gdbstub/user.c | 2 +-
include/gdbstub/user.h | 2 +-
linux-user/main.c | 2 +-
4 files changed, 4 insertions(+), 4 deletions
that is initialized on fork(),
decides the current owner of the gdbserver socket, and is terminated
when one of the two processes is detached. The logic for the parent and
the child is the same, only the initial state is different.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 212
Add follow-fork-mode child and and follow-fork-mode parent tests.
Check for the obvious pitfalls, such as lingering breakpoints,
catchpoints, and single-step mode.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/Makefile.target | 17 +-
tests/tcg/multiarch/follow-fork
1-9
are preliminary refactorings, patch 10 is the implementation, and patch
11 is the test.
[1] https://lists.gnu.org/archive/html/qemu-devel/2024-01/msg06424.html
Best regards,
Ilya
Ilya Leoshkevich (11):
gdbstub: Support disablement in a multi-threaded process
{linux,bsd}-user: Update ts_tid aft
The upcoming follow-fork-mode child support requires post-fork message
exchange between the parent and the child. Prepare gdbserver_fork() for
this purpose. Rename it to gdbserver_fork_end() to better reflect its
purpose.
Signed-off-by: Ilya Leoshkevich
---
bsd-user/main.c| 3
The upcoming follow-fork-mode child support requires advertising the
fork-events feature, which is user-specific. Introduce a user-specific
hook for this.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 12 +---
gdbstub/internals.h | 1 +
gdbstub/user.c | 4
3
-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 19 +++
1 file changed, 15 insertions(+), 4 deletions(-)
diff --git a/gdbstub/user.c b/gdbstub/user.c
index 8f3affbad47..e6809da2243 100644
--- a/gdbstub/user.c
+++ b/gdbstub/user.c
@@ -356,16 +356,27 @@ int gdbserver_start(const char
On Sat, Feb 03, 2024 at 11:48:44PM +0300, Michael Tokarev wrote:
> 01.02.2024 01:02, Ilya Leoshkevich wrote:
> > The `if not probe_proc_self_mem` check never passes, because
> > probe_proc_self_mem is a function object, which is a truthy value.
> > Add parentheses in order
ml
Signed-off-by: Ilya Leoshkevich
---
gdbstub/gdbstub.c | 9 +
gdbstub/internals.h | 1 +
gdbstub/user.c | 95 +
3 files changed, 105 insertions(+)
diff --git a/gdbstub/gdbstub.c b/gdbstub/gdbstub.c
index 46d752bbc2c..7e73e916
Check that adding/removing syscall catchpoints works.
Reviewed-by: Alex Bennée
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/multiarch/Makefile.target | 10 +++-
tests/tcg/multiarch/catch-syscalls.c | 51 ++
tests/tcg/multiarch/gdbstub/catch-syscalls.py | 53
The upcoming syscall catchpoint support needs to get control on syscall
entry and return. Provide the necessary hooks for that, which are
no-ops for now.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c | 8
include/gdbstub/user.h | 13 +
include/user
1/2] and a test in [2/2].
I'm basing this on my other series, since it contains useful gdbstub
test refactorings.
Best regards,
Ilya
Ilya Leoshkevich (5):
gdbstub: Expose TARGET_SIGTRAP in a target-agnostic way
gdbstub: Allow specifying a reason in stop packets
gdbstub: Add syscall ent
The upcoming syscall catchpoint support needs to send SIGTRAP stop
packets to GDB. Being able to compile this support only once for all
targets is a good thing, and it requires hiding TARGET_SIGTRAP behind
a function call.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/internals.h | 1 +
gdbstub
The upcoming syscall catchpoint support needs to send stop packets with
an associated reason to GDB. Add an extra parameter to gdb_handlesig()
for that, and rename it to gdb_handlesig_reason(). Provide a
compatibility wrapper with an old name.
Signed-off-by: Ilya Leoshkevich
---
gdbstub/user.c
On Thu, 2024-02-01 at 17:15 +, Alex Bennée wrote:
> Ilya Leoshkevich writes:
>
> > GDB supports stopping on syscall entry and exit using the "catch
> > syscall" command. It relies on 3 packets, which are currently not
> > supported by QEMU:
> &
https://lists.gnu.org/archive/html/qemu-devel/2024-01/msg02865.html
v1 -> v2: Fix !CONFIG_INT128 builds (Richard).
Hi,
Ido reported that we are missing the CVDG emulation (which is very
similar to the existing CVD emulation). This series adds it along with
a test.
Best regards,
Ilya
Ilya Leosh
CVDG is the same as CVD, except that it converts 64 bits into 128,
rather than 32 into 64. Create a new helper, which uses Int128
wrappers.
Reported-by: Ido Plat
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
target/s390x/helper.h| 1 +
target/s390x/tcg/insn
Check the CVD's, CVDY's, and CVDG's corner cases.
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/cvd.c | 63 +
2 files changed, 64 insertions(+)
create mode 100644 tests/tcg/s390x/cvd.c
diff --git a/tests
Check the CVB's, CVBY's, and CVBG's corner cases.
Co-developed-by: Pavel Zbitskiy
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/cvb.c | 102
2 files changed, 103 insertions(+)
create mode 100644 tests
Convert to Binary - counterparts of the already implemented Convert
to Decimal (CVD*) instructions.
Example from the Principles of Operation: 25594C becomes 63FA.
Co-developed-by: Pavel Zbitskiy
Signed-off-by: Ilya Leoshkevich
---
target/s390x/helper.h| 2 +
target/s390x/tcg/insn
On Thu, 2024-02-01 at 12:11 +, Alex Bennée wrote:
> Ilya Leoshkevich writes:
>
> > Currently it's not possible to use gdbstub for debugging linux-user
> > code that runs in a forked child, which is normally done using the
> > `set
> > follow-fork-m
From: Pavel Zbitskiy
Convert to Binary - counterparts of the already implemented Convert
to Decimal (CVD*) instructions.
Example from the Principles of Operation: 25594C becomes 63FA.
[iii: Use separate functions for CVB and CVBG for simplicity].
Signed-off-by: Pavel Zbitskiy
---
CVDG is the same as CVD, except that it converts 64 bits into 128,
rather than 32 into 64. Create a new helper, which uses Int128
wrappers.
Reported-by: Ido Plat
Reviewed-by: Richard Henderson
Signed-off-by: Ilya Leoshkevich
---
target/s390x/helper.h| 1 +
target/s390x/tcg/insn
Check the CVB's and CVBG's corner cases.
Co-developed-by: Pavel Zbitskiy
Signed-off-by: Ilya Leoshkevich
---
tests/tcg/s390x/Makefile.target | 1 +
tests/tcg/s390x/cvb.c | 47 +
2 files changed, 48 insertions(+)
create mode 100644 tests/tcg/s390x
hat we are missing the CVDG emulation (which is very
similar to the existing CVD emulation). This series adds it along with
a test.
Best regards,
Ilya
Ilya Leoshkevich (3):
target/s390x: Emulate CVDG
tests/tcg/s390x: Test CONVERT TO DECIMAL
tests/tcg/s390x: Test CONVERT TO BINARY
Pavel Zbits
1 - 100 of 957 matches
Mail list logo