From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 52637 invoked by alias); 5 Oct 2017 09:55:42 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 52626 invoked by uid 89); 5 Oct 2017 09:55:42 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=3.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,RCVD_IN_SORBS_SPAM,SPF_PASS autolearn=no version=3.3.2 spammy=ram, H*r:sk:gdb@sou, H*c:alternative, RAM X-HELO: mail-it0-f52.google.com Received: from mail-it0-f52.google.com (HELO mail-it0-f52.google.com) (209.85.214.52) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 05 Oct 2017 09:55:40 +0000 Received: by mail-it0-f52.google.com with SMTP id p138so557293itp.2 for ; Thu, 05 Oct 2017 02:55:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=uYYfHCS0dHVO3ozgk06SYqnqjIg4cWfdpzasmB36/jQ=; b=N8QM/Qn7tW92sbjwbBooLve2/+1PrPS6h8+DraG6k1qQL2xjbaAc4PbAfsCqpJIWDi EIU4HtpIuDsCE67sSfFyT+l6ViWL8Wi+xx0RKuC8ccDwUbPJe78VEKTzi5MewcJ3nTxU hEOd3OBhwCPbR4z+HTa2oSErZIYlhz5GCgB2cgReOrxhyrDiG1zRDKYaaJpfVETyX/cZ 3e64IFhF4m/cIqw13p4guPROR4dCCSdvf26/IkJ7YXzkxvHlc3TMN0rs6b44Mgzm07pW /z7zasuAgP9a5AdtOHU10FIoW9S3TuipS75eP3uWrRywcQKXf7HThTHEsd5HzP5ZqILG 5jBg== X-Gm-Message-State: AMCzsaUcxOw6fQ2L/w2ikfStoPPNpDl1uZFzXaHA0O7Avs41c82i8uXk v1guLo47y/+H9sB8ywPPgvmmxwJfr8tNJb+lvCHUow== X-Google-Smtp-Source: AOwi7QB33CSB4zxKfyXpTgPnHw1xYO83tW/gCCOx4dLlwTxcgXE3bfvq9/UjbKIh4D8KMw7RnayqZVhKyk9+SjmhHJI= X-Received: by 10.36.200.132 with SMTP id w126mr7691000itf.101.1507197338770; Thu, 05 Oct 2017 02:55:38 -0700 (PDT) MIME-Version: 1.0 Received: by 10.79.33.146 with HTTP; Thu, 5 Oct 2017 02:55:38 -0700 (PDT) From: Hesham M Date: Thu, 05 Oct 2017 09:55:00 -0000 Message-ID: Subject: Postmortem debugging with arm-none-eabi-gdb from memory dump (not core) To: gdb@sourceware.org Content-Type: text/plain; charset="UTF-8" X-SW-Source: 2017-10/txt/msg00012.txt.bz2 Hi all, As this is my first email to the list, and as an old user for gdb, I'd like first to thank the gdb community for their effort. In a bare-metal ARM system, is there a way to use arm-none-eabi-gdb for postmortem debugging, the same way we do when we debug with core file on Linux, for example? The issue is that I don't have a "core" file but I can generate memory dump of the whole memory (ROM is already known and through the hardware debugger used I can write the RAM contents to a file (outside the target of course). I can also collect the registers at the time of the crash. I can do the debugging/analysis if I connect gdb to the target at the time of the crash but I need to do this in later time away from the target. I hope to find a way to debug with memory dumps the same way gdb debugs with core files. Of course if I can convert the memory dump to a valid core file, it might be another path to the solution. I don't know how to do that or if there is a tool that can help with this conversion. Any idea if this is possible? A variant of this is idea is done for Keil tools: https://os.mbed.com/blog/entry/Post-mortem-debugging-with-ARM-mbed/ I have posted a similar question on stackoverflow but they closed it! So, please let me know if my question isn't clear. Thanks, -Hesham