From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29378 invoked by alias); 26 Mar 2003 00:31:34 -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 29371 invoked from network); 26 Mar 2003 00:31:34 -0000 Received: from unknown (HELO localhost.redhat.com) (207.219.125.105) by sources.redhat.com with SMTP; 26 Mar 2003 00:31:34 -0000 Received: from redhat.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 5E7972B23 for ; Tue, 25 Mar 2003 19:31:27 -0500 (EST) Message-ID: <3E80F4DF.4090809@redhat.com> Date: Wed, 26 Mar 2003 00:31:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.2) Gecko/20030223 X-Accept-Language: en-us, en MIME-Version: 1.0 To: gdb@sources.redhat.com Subject: GDB's breakpoint internals Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2003-03/txt/msg00349.txt.bz2 (Put simply, the things you learn when reading a book explaining how a debugger should work :-) The `How Debuggers Work' [rosenberg] book describes a breakpoint implementation broken into two parts: - high level user breakpoint list This is what the user sees. One entry corresponds to each `break XXX' command. That high level breakpoint then maps onto 1 or more ... - low level physical breakpoints (or watchpoints or ...) One entry per physical breakpoint. When a breakpoint is hit, a reverse map back to each high-level breakpoint for the event is done, and then that breakpoint's handler is called. I might be mistaken, but I don't think GDB implemented things this way. Instead, it has a single tangled table. Andrew