* [Qemu-devel] Regarding PTRACE implementation in QEMU user mode
@ 2008-09-23 14:01 sathish kumar
2008-09-23 14:12 ` Paul Brook
0 siblings, 1 reply; 5+ messages in thread
From: sathish kumar @ 2008-09-23 14:01 UTC (permalink / raw)
To: qemu-devel; +Cc: rajesh-siso
[-- Attachment #1: Type: text/plain, Size: 299 bytes --]
hi,
Can someone explain why explain why ptrace system call is not implemented in QEMU?
if someone is working on it, please share some ideas.
Thanks & Regards,
Sathish
Get an email ID as yourname@ymail.com or yourname@rocketmail.com. Click here http://in.promos.yahoo.com/address
[-- Attachment #2: Type: text/html, Size: 691 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] Regarding PTRACE implementation in QEMU user mode
2008-09-23 14:01 [Qemu-devel] Regarding PTRACE implementation in QEMU user mode sathish kumar
@ 2008-09-23 14:12 ` Paul Brook
2008-09-23 14:20 ` Paul Brook
0 siblings, 1 reply; 5+ messages in thread
From: Paul Brook @ 2008-09-23 14:12 UTC (permalink / raw)
To: qemu-devel; +Cc: sathish kumar, rajesh-siso
> Can someone explain why explain why ptrace system call is not implemented
> in QEMU? if someone is working on it, please share some ideas.
Because it's extremely hard (read: nearly impossible) to implement properly.
ptrace allows direct access to the state of a different process. Passing
through ptrace would give you the state of qemu itself, not the program
you're interested in, so you have to emulate everything via some othe IPC
mechanism (which must also be hidden from the emulated application). This
includes signals like SIGSTOP which cannot be trapped.
If you're not extremely careful you end up with a monstrosity like Cygwin, and
all the problems that implies.
Paul
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] Regarding PTRACE implementation in QEMU user mode
2008-09-23 14:12 ` Paul Brook
@ 2008-09-23 14:20 ` Paul Brook
2008-09-23 15:02 ` Jamie Lokier
0 siblings, 1 reply; 5+ messages in thread
From: Paul Brook @ 2008-09-23 14:20 UTC (permalink / raw)
To: qemu-devel; +Cc: sathish kumar, rajesh-siso
On Tuesday 23 September 2008, Paul Brook wrote:
> > Can someone explain why explain why ptrace system call is not implemented
> > in QEMU? if someone is working on it, please share some ideas.
>
> Because it's extremely hard (read: nearly impossible) to implement
> properly.
I'll also note that the usual use of ptrace if for gdb/gdbserver. You should
use the builtin qemu gdb stub instead.
Paul
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] Regarding PTRACE implementation in QEMU user mode
2008-09-23 14:20 ` Paul Brook
@ 2008-09-23 15:02 ` Jamie Lokier
2008-09-23 18:29 ` Kirill A. Shutemov
0 siblings, 1 reply; 5+ messages in thread
From: Jamie Lokier @ 2008-09-23 15:02 UTC (permalink / raw)
To: qemu-devel; +Cc: sathish kumar, rajesh-siso
Paul Brook wrote:
> On Tuesday 23 September 2008, Paul Brook wrote:
> > > Can someone explain why explain why ptrace system call is not implemented
> > > in QEMU? if someone is working on it, please share some ideas.
> >
> > Because it's extremely hard (read: nearly impossible) to implement
> > properly.
>
> I'll also note that the usual use of ptrace if for gdb/gdbserver. You should
> use the builtin qemu gdb stub instead.
The other usual use is strace, which seems like it would be useful for
user mode emulation.
-- Jamie
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Qemu-devel] Regarding PTRACE implementation in QEMU user mode
2008-09-23 15:02 ` Jamie Lokier
@ 2008-09-23 18:29 ` Kirill A. Shutemov
0 siblings, 0 replies; 5+ messages in thread
From: Kirill A. Shutemov @ 2008-09-23 18:29 UTC (permalink / raw)
To: qemu-devel; +Cc: sathish kumar, rajesh-siso
[-- Attachment #1: Type: text/plain, Size: 768 bytes --]
On Tue, Sep 23, 2008 at 04:02:37PM +0100, Jamie Lokier wrote:
> Paul Brook wrote:
> > On Tuesday 23 September 2008, Paul Brook wrote:
> > > > Can someone explain why explain why ptrace system call is not implemented
> > > > in QEMU? if someone is working on it, please share some ideas.
> > >
> > > Because it's extremely hard (read: nearly impossible) to implement
> > > properly.
> >
> > I'll also note that the usual use of ptrace if for gdb/gdbserver. You should
> > use the builtin qemu gdb stub instead.
>
> The other usual use is strace, which seems like it would be useful for
> user mode emulation.
Set QEMU_STRACE environment variable.
--
Regards, Kirill A. Shutemov
+ Belarus, Minsk
+ ALT Linux Team, http://www.altlinux.com/
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 197 bytes --]
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2008-09-23 18:28 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-23 14:01 [Qemu-devel] Regarding PTRACE implementation in QEMU user mode sathish kumar
2008-09-23 14:12 ` Paul Brook
2008-09-23 14:20 ` Paul Brook
2008-09-23 15:02 ` Jamie Lokier
2008-09-23 18:29 ` Kirill A. Shutemov
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).