From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7378 invoked by alias); 13 Nov 2012 20:35:01 -0000 Received: (qmail 7281 invoked by uid 22791); 13 Nov 2012 20:35:00 -0000 X-SWARE-Spam-Status: No, hits=-5.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE,RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail-oa0-f41.google.com (HELO mail-oa0-f41.google.com) (209.85.219.41) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 13 Nov 2012 20:34:54 +0000 Received: by mail-oa0-f41.google.com with SMTP id k14so8802107oag.0 for ; Tue, 13 Nov 2012 12:34:53 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:x-gm-message-state; bh=tDTB0h2rn6V6BZq8girCYqqX8GTGeYKyagkZmcMkTDU=; b=I7k5Vf2EVIqSRQ2cIuCTANB5J1kgk2OBBbtia5jbfuhzbxLquGh5EVipEtE/WNFZ+d 4rHzgx0feOiG1SRoT73/S6GrsxUc1fFqdgJTDxKv4OfQ2E5njrTg3ysIQzLkc1g0E0fN Tf5iBOgZgoLkIcb4r36fPNKStfRaEmhgOS8S5H9ieEHutF58q2AMdZrm/JQ8pquN41H3 hI6HCuXriIPT+9OuI3C8jELs3azFbIu5jL71KbHQnzD8tZtTFS5Bc4Ilc1dgyLp3Qosm CcVJZURWG9/XYq/wu3SWTZUZdE2CaeWJ0zabsDI0g+ZdJJqgbbZcgqvvUh4/6qpbM7lX I2wg== MIME-Version: 1.0 Received: by 10.60.170.9 with SMTP id ai9mr17755174oec.36.1352838893891; Tue, 13 Nov 2012 12:34:53 -0800 (PST) Received: by 10.76.71.201 with HTTP; Tue, 13 Nov 2012 12:34:53 -0800 (PST) In-Reply-To: <1352454420562-212534.post@n7.nabble.com> References: <1352454420562-212534.post@n7.nabble.com> Date: Tue, 13 Nov 2012 20:35:00 -0000 Message-ID: Subject: Re: Strange address in the stack trace From: Doug Evans To: santoshp Cc: gdb@sourceware.org Content-Type: text/plain; charset=ISO-8859-1 X-Gm-Message-State: ALoCoQm9W25k6SBgTRl/UBTnnuRZ8qe+n4+zUHwETWlbkmkkb4B3YrA4w74I0jbeAoWmft2oajmHDiJ2POUWwP3Pyb5ePgj932S1+zuWrigOr9o7EotTtDSnexiAsrqRYQEDwJKv4orebrSohFCu4tRPSSMve1misB7w6y22ls1qhlOW57+st828lS5rYOIf5kbCoCrEVaZA X-IsSubscribed: yes 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 X-SW-Source: 2012-11/txt/msg00022.txt.bz2 On Fri, Nov 9, 2012 at 1:47 AM, santoshp wrote: > Hi All,While debugging a crash dump using GDB (7.2) on RHEL-5, one address > looks strange to me. i.e. valueChanges variable. The same variable getting > passed to frames but shows different addresses in different frames. #1 > 0x00002aaaab8a163a in MR_AnyVal (this=0x2aaab9000020, *o=@0x52*) at > repos/mr/anyvali.c:36#2 0x00002aaaabb0fa13 in > MR_MonitoringSystem::valueChanges2monValueChanges > (*valueChanges=@0x465a5700*) at repos/mr/MR_MonitoredValue.h:61#3 > 0x00002aaaabb1065b in MR_MonitoringSystem::processChangesStandard > (*valueChanges=@0x465a5700*) at repos/mr/MR_MonitoringSystem.c:280#4 > 0x00002aaaabbb026c in MR_Accessor::notify (this=, *valueChanges=@0x52*) at > repos/accessors/MR_Accessor.c:1573Can somebody please comment on this > whether this is from OS (because it's optimized build) or the behavior from > GDB?Thanks,Santosh Hi. Sounds like this is just the effect of debugging optimized code. GDB can only print a value as the debug info specifies, and when debugging optimized code often the debug info is inaccurate. GIGO.