From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 110599 invoked by alias); 15 Mar 2017 00:04:22 -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 110578 invoked by uid 89); 15 Mar 2017 00:04:22 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.1 required=5.0 tests=AWL,BAYES_05,KAM_LAZY_DOMAIN_SECURITY,RCVD_IN_DNSWL_LOW autolearn=no version=3.3.2 spammy=Hx-spam-relays-external:sk:smtp-ou, H*RU:sk:smtp-ou, HX-HELO:sk:smtp-ou, H*r:172.16.0 X-HELO: smtp-out6.electric.net Received: from smtp-out6.electric.net (HELO smtp-out6.electric.net) (192.162.217.186) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 15 Mar 2017 00:04:20 +0000 Received: from 1cnwQN-0003iH-TX by out6b.electric.net with emc1-ok (Exim 4.87) (envelope-from ) id 1cnwQN-0003jX-UO for gdb@sourceware.org; Tue, 14 Mar 2017 17:04:19 -0700 Received: by emcmailer; Tue, 14 Mar 2017 17:04:19 -0700 Received: from [188.39.184.230] (helo=glaexch1.ftdichip.com) by out6b.electric.net with esmtps (TLSv1:AES128-SHA:128) (Exim 4.87) (envelope-from ) id 1cnwQN-0003iH-TX for gdb@sourceware.org; Tue, 14 Mar 2017 17:04:19 -0700 Received: from GLAEXCH3.ftdi.local ([172.16.0.161]) by glaexch1 ([172.16.0.121]) with mapi id 14.01.0438.000; Wed, 15 Mar 2017 00:04:18 +0000 From: James Bowman To: "gdb@sourceware.org" Subject: Relaxations vs debug info Date: Wed, 15 Mar 2017 00:04:00 -0000 Message-ID: <2BB0A51F073B384698CACFD1D5A30FCC24F429@glaexch3> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Outbound-IP: 188.39.184.230 X-Env-From: james.bowman@ftdichip.com X-Proto: esmtps X-Revdns: glaexch1.ftdichip.com X-TLS: TLSv1:AES128-SHA:128 X-Authenticated_ID: X-PolicySMART: 10711027 X-SW-Source: 2017-03/txt/msg00019.txt.bz2 I am working on some linker relaxations for my target, using existing=20 relaxation implementations as my pattern. Everything seems to be working: relaxations are being applied, for example relaxation reduces the size of function foo from 0x48 to 0x38 bytes.=20 Checking symbols, it looks good: $ ft32-elf-objdump -t a.out | grep foo 0000033c g F .text 00000038 foo However when I look at the debug info (objdump -g) I see that the size is s= till 0x48: DW_AT_name : foo DW_AT_decl_file : 1 DW_AT_decl_line : 51 DW_AT_prototyped : 1 DW_AT_type : <0x5d> DW_AT_low_pc : 0x33c DW_AT_high_pc : 0x48 =20=20=20=20 Unsurprisingly this confuses gdb. My question is: in relaxation, how does the gdb info get adjusted?=20