From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31151 invoked by alias); 31 Mar 2014 14:16:30 -0000 Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org Received: (qmail 31141 invoked by uid 89); 31 Mar 2014 14:16:29 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.8 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_PASS autolearn=ham version=3.3.2 X-HELO: ausc60ps301.us.dell.com Received: from ausc60ps301.us.dell.com (HELO ausc60ps301.us.dell.com) (143.166.148.206) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (CAMELLIA256-SHA encrypted) ESMTPS; Mon, 31 Mar 2014 14:16:28 +0000 X-LoopCount0: from 10.170.28.39 From: To: CC: Subject: Re: break on C++ global objects ctors Date: Mon, 31 Mar 2014 14:16:00 -0000 Message-ID: References: In-Reply-To: Content-Type: text/plain; charset="Windows-1252" Content-ID: <6C90F162CF14D7428784516574116C10@dell.com> Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-IsSubscribed: yes X-SW-Source: 2014-03/txt/msg00694.txt.bz2 On Mar 31, 2014, at 10:10 AM, Daniel Gutson wrote: > On Mon, Mar 31, 2014 at 10:56 AM, wrote: >> This certainly should be easily doable, just in gdb. FWIW, if you start= a program with gdbserver and then connect to it from gdb ("target remote" = to gdbserver), the program is stopped at the first instruction, way before = "main". >=20 > That doesn't solve how gdb detects the beginning of each ctor function. I don=92t know what problem you=92re referring to. A constructor is just a= function, which has a name, and you can set a breakpoint on it.=20=20 If for some reason that=92s not working, that would be a bug, but I=92ve us= ed breakpoints on constructors for a long time and it seems to work when I = try it. paul