From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5655 invoked by alias); 6 Sep 2004 12:00:38 -0000 Mailing-List: contact gdb-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sources.redhat.com Received: (qmail 5633 invoked from network); 6 Sep 2004 12:00:35 -0000 Received: from unknown (HELO miranda.se.axis.com) (193.13.178.2) by sourceware.org with SMTP; 6 Sep 2004 12:00:35 -0000 Received: from [10.84.130.1] (ironmaiden.se.axis.com [10.84.130.1]) by miranda.se.axis.com (8.12.9/8.12.9/Debian-5local0.1) with ESMTP id i86BxgFI002103; Mon, 6 Sep 2004 13:59:42 +0200 Message-ID: <413C512E.2000300@axis.com> Date: Mon, 06 Sep 2004 12:00:00 -0000 From: Orjan Friberg Organization: Axis Communications User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040616 MIME-Version: 1.0 To: Daniel Jacobowitz CC: gdb@sources.redhat.com Subject: Re: Register fudging (CRISv32) References: <4138656F.9020001@axis.com> <20040903134721.GA1028@nevyn.them.org> <4138800F.9050503@axis.com> <20040903160329.GA18755@nevyn.them.org> In-Reply-To: <20040903160329.GA18755@nevyn.them.org> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2004-09/txt/msg00044.txt.bz2 Daniel Jacobowitz wrote: > > Precisely. It sounds like the kernel can do a more accuarate job than > gdbserver can easily. For instance, if we single-step a task, and > detach leaving it stopped, and attach another debugger - that debugger > won't have the state to know whether the task was last stepped or > trapped. I sort of see what you're saying (though I'm not sure I understand your example: the register contents would be the same when attaching again, which is what the pseudo-PC is calculated from). Anyways, I'm going to try and implement the creation of the pseudo-PC in the kernel - I'm not entirely happy with having it in the Gdbserver, and it also has it flaws (for example, sigaltstack.exp generating several FAILs if we receive the signal in a delay slot). >>For example, in case of a PTRACE_CONT I set the single-step PC to 0 to >>disable single-stepping (similar to what the m68k does). > > > Ah, I think I see. I don't remember what your original question was > though :-) It was just one example of register fudging that seemed appropriate to do in the kernel. -- Orjan Friberg Axis Communications