From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 39314 invoked by alias); 28 Sep 2016 19:22:41 -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 39028 invoked by uid 89); 28 Sep 2016 19:22:39 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-4.8 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 spammy= X-HELO: mx5.ptsecurity.com Received: from mx5.ptsecurity.com (HELO mx5.ptsecurity.com) (45.58.112.35) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 28 Sep 2016 19:22:29 +0000 Received: from dc1-mail-01.ptsecurity.ru (10.0.52.111) by ny-mx-01.ptsecurity.ru (10.6.20.6) with Microsoft SMTP Server (TLS) id 15.1.466.34; Wed, 28 Sep 2016 22:22:27 +0300 Received: from [10.0.72.136] (10.0.72.136) by dc1-mail-01.ptsecurity.ru (10.0.52.111) with Microsoft SMTP Server (TLS) id 15.1.466.34; Wed, 28 Sep 2016 22:22:26 +0300 Subject: Re: Custom core file To: , References: <20160928083121.5c1bb9f86d671edec44bb378f25c04cc.5416b9a60c.wbe@email03.godaddy.com> From: Nikolay Martyanov Message-ID: Date: Wed, 28 Sep 2016 19:22:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <20160928083121.5c1bb9f86d671edec44bb378f25c04cc.5416b9a60c.wbe@email03.godaddy.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: dc1-mail-01.ptsecurity.ru (10.0.52.111) To dc1-mail-01.ptsecurity.ru (10.0.52.111) X-SW-Source: 2016-09/txt/msg00074.txt.bz2 On 09/28/2016 06:31 PM, duane@duaneellis.com wrote: >>> So, I guess, dump/restore approach works only in two cases: >>> a) debugging live process you have attached to (it's not my case, as I >>> perform postmortem debug) >>> b) already has loaded core file, which provides a context via saved CPU >>> state - and it is the way I chose to follow. > For step (B) - first load a dummy (tiny) standard core file - that gives > you a debug context, think of it as a shim. > > Then proceed with adding your symbols and using dump/restore to load > your image. > > At first I tried to restore memory in a case of fake core file (according to your advice). Looks like it's impossible, cause it still asks for a process. `Restore` doesn't work with core file debugging, I guess. But now I have one other idea =)