LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Programming (https://www.linuxquestions.org/questions/programming-9/)
-   -   Creating a core dump from raw ram dump? (https://www.linuxquestions.org/questions/programming-9/creating-a-core-dump-from-raw-ram-dump-825475/)

cyent 08-11-2010 12:02 AM

Creating a core dump from raw ram dump?
 
So I have an embedded device that runs eCos on a sparc. I have on my linux box the ELF executable file and the cross compiler tools, and a debug connection that I can use to pull the entire contents of ram from the device.

Now I want to do that and create a core dump file so I can debug the core dump at leisure.

Any ideas how to do that?

ArthurSittler 08-11-2010 11:55 PM

coredump to ram may be noninvertible transform
 
cyent,
Core dump to RAM image is not a trivially invertible transform. The problem is that the core dump includes the register images and memory image inside the process. The mapping from the process memory space to the RAM addresses depends on the registers in the memory management unit (MMU). That is, there may be no fixed mapping from RAM address back to process memory address space because you do not have the MMU and register contents.
I am weak on my familiarity with sparc architecture, so my comments are a best somewhat-educated guess on my part.

cyent 08-15-2010 05:57 PM

Hmm. Fortunately in this case, (or unfortunately in most other cases), we do _not_ have the MMU active. ie. I can pull the ram and registers as seen by the process no trouble. The problem then is merely to format as a coredump edible to gdb.


All times are GMT -5. The time now is 02:36 AM.