From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18753 invoked by alias); 7 Jun 2005 18:11:29 -0000 Mailing-List: contact binutils-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sources.redhat.com Received: (qmail 18257 invoked by uid 22791); 7 Jun 2005 18:11:18 -0000 Received: from norbert.ecoscentric.com (HELO smtp.ecoscentric.com) (194.153.168.165) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Tue, 07 Jun 2005 18:11:18 +0000 Received: by smtp.ecoscentric.com (Postfix, from userid 99) id 4799D65C083; Tue, 7 Jun 2005 19:11:16 +0100 (BST) Received: from [127.0.0.1] (localhost [127.0.0.1]) by smtp.ecoscentric.com (Postfix) with ESMTP id 0A0D365C064; Tue, 7 Jun 2005 19:11:15 +0100 (BST) Message-ID: <42A5E378.4040600@eCosCentric.com> Date: Tue, 07 Jun 2005 18:11:00 -0000 From: Jonathan Larmour User-Agent: Mozilla Thunderbird 1.0.2-1.3.3 (X11/20050513) MIME-Version: 1.0 To: Eric Botcazou Cc: binutils@sources.redhat.com Subject: Re: gc sections and .eh_frame References: <42A5DE0C.9050108@eCosCentric.com> <200506071959.33267.ebotcazou@adacore.com> In-Reply-To: <200506071959.33267.ebotcazou@adacore.com> Content-Type: text/plain; charset=iso-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2005-06/txt/msg00131.txt.bz2 Eric Botcazou wrote: >Jifl wrote: >>This change doesn't make sense to me. _bfd_elf_discard_section_eh_frame >>does not set gc_mark on any section. So as a result, I would assume none >>of the reloc dependencies of .eh_frame would ever get marked and that's >>how those sections get GC'd. Am I missing something? > > > Presumably: > > 2004-04-21 Eric Botcazou > > * scripttempl/elf.sc (.text): Add KEEP for .text.*personality*. > (.data): Add KEEP for .gnu.linkonce.d.*personality*. > (.gcc_except_table): Add KEEP for self and accept .gcc_except_table.*. > Yes, as I mentioned briefly that doesn't help for powerpc, where the referenced data doesn't go in .gcc_except_table, but instead goes in .rodata. Don't ask me why it does, but it does. Probably some weird ABI thing. It's also worth mentioning that even on other architectures, this new requirement (the KEEP) would cause a regression with previously working builds. And a pretty difficult to diagnose one at that. On embedded systems, custom linker scripts are exceptionally common. The default GNU ld template stuff isn't very relevant. For example, have a look at newlib/libgloss (although I'm using a different runtime). Of course this would only affect people using --gc-sections with recent binutils, which is why you probably haven't had people jumping up and down yet :-). Jifl -- eCosCentric http://www.eCosCentric.com/ The eCos and RedBoot experts --["No sense being pessimistic, it wouldn't work anyway"]-- Opinions==mine