[Top][All Lists]

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

Re: core file writing

From: Marcus Brinkmann
Subject: Re: core file writing
Date: Wed, 6 Mar 2002 20:04:45 +0100
User-agent: Mutt/1.3.27i

On Mon, Mar 04, 2002 at 04:38:42PM -0700, Jon Arney wrote:
> Roland:
> Since you said it's not really very hard to do, I thought I'd make
> an attempt at it with your permission.

I'm sure he will give it to you :)
> I am guided by other elf core writers (such as Linux's) and it seems
> to be going ok for now, but I have a couple of questions if you have
> any clues.

That most can be shared was my impression, too, last time I looked at it. 
The main difference that comes to mind is that we have native (kernel-level)
threads, and the threads state needs to be stored in the core file as well.
> I thought I'd make it an elf-core file (since Hurd uses elf files
> for executables) and perhaps leave some hooks in for other exec
> formats. (a.out,etc)  Creating the header info seems not too difficult
> using proc_getprocinfo and company, but I'm a little confused on how
> to get access to the user register state and the VM for the process.

Some of these are provided by Mach, see the mach.info manual in the
gnumach package (or mach.texi in the source).  Like thread_get_state.  Note
that the flavour is processor specific, so you will probably have to look
into the Mach sources or header files for more details.
> I thought perhaps proc_getexecdata might be correct, but then I thought
> perhaps I should ask someone first.

That is something different (the initial ports for a task).

Thanks for taking the initiative!  Make sure to glue your work into the
crash server (hurd/trans/crash.c) and gdb!


`Rhubarb is no Egyptian god.' Debian http://www.debian.org brinkmd@debian.org
Marcus Brinkmann              GNU    http://www.gnu.org    marcus@gnu.org

reply via email to

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