From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 94363 invoked by alias); 26 Aug 2019 16:50:47 -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 94355 invoked by uid 89); 26 Aug 2019 16:50:46 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-1.2 required=5.0 tests=AWL,BAYES_05,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.1 spammy=HX-Languages-Length:528, H*f:CAPTJ0XH, H*f:sk:ULSbw@m, H*f:sk:r2socS0 X-HELO: mail-io1-f54.google.com Received: from mail-io1-f54.google.com (HELO mail-io1-f54.google.com) (209.85.166.54) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 26 Aug 2019 16:50:45 +0000 Received: by mail-io1-f54.google.com with SMTP id p12so38972793iog.5 for ; Mon, 26 Aug 2019 09:50:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=vugJ4V0iWogmI5HaEEEePgT3oKOuc8EomlcdN05WxRQ=; b=GuLnIpf8u10g4O1ucHXtNEHSpkUyJUV8StXhseC7D7POfEj7YY8pOK7EsCB2Ip3mCy eHakk8C0ZmFzkWRsBQRENj3QUOjKmTi8WUBt79GQaRb/zptqKmyQp+JIBNTs3ezAwF0A kB5PDuI15nePuLmIUHijH8VrfAesHkEODe7E92pgh/uCa9S4CrkXj6dNXELgtwnmklM0 eyvogd9F1NErOJDZ9dCGgxNJ1dYXGizl+QcMa9QeTr5tt0LFjmQUmxrtRqb3dTHwyFgi sH2mBRrPShsk9ascFInPB5OPi8STs9ARuF6F55aviqqDR+YziPv/eCZeAxKwMflF5u2U FeHQ== MIME-Version: 1.0 References: In-Reply-To: From: Andrea Cardaci Date: Mon, 26 Aug 2019 16:50:00 -0000 Message-ID: Subject: Re: Function address incoherence To: Christian Biesinger Cc: gdb@sourceware.org Content-Type: text/plain; charset="UTF-8" X-SW-Source: 2019-08/txt/msg00044.txt.bz2 On Mon, 26 Aug 2019 at 18:34, Christian Biesinger wrote: > Why don't you use frame.function() and get the address from there? This actually seems a good idea and I can't remember why I didn't end up using that, let me try... > (and why parse_and_eval instead of lookup_symbol?) Because: >>> gdb.lookup_symbol('_start') (None, False) >>> gdb.parse_and_eval('_start') Maybe I need to specify a block different than the current.