From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18397 invoked by alias); 25 Feb 2011 15:55:03 -0000 Received: (qmail 18383 invoked by uid 22791); 25 Feb 2011 15:55:02 -0000 X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW X-Spam-Check-By: sourceware.org Received: from mail-qy0-f176.google.com (HELO mail-qy0-f176.google.com) (209.85.216.176) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 25 Feb 2011 15:54:57 +0000 Received: by qyk30 with SMTP id 30so1678307qyk.0 for ; Fri, 25 Feb 2011 07:54:56 -0800 (PST) MIME-Version: 1.0 Received: by 10.224.47.66 with SMTP id m2mr2123725qaf.391.1298649295698; Fri, 25 Feb 2011 07:54:55 -0800 (PST) Received: by 10.224.61.18 with HTTP; Fri, 25 Feb 2011 07:54:55 -0800 (PST) In-Reply-To: <20110225074917.GB5959@bubble.grove.modra.org> References: <20100715141753.GI31087@bubble.grove.modra.org> <20100716093630.GN31087@bubble.grove.modra.org> <20100720054451.GF19525@bubble.grove.modra.org> <20100720141031.GI19525@bubble.grove.modra.org> <20110225074917.GB5959@bubble.grove.modra.org> Date: Fri, 25 Feb 2011 15:55:00 -0000 Message-ID: Subject: Re: VMA section overlap warnings for overlays From: "H.J. Lu" To: Andreas Schwab , David Stubbs , binutils@sourceware.org Cc: Alan Modra Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact binutils-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: binutils-owner@sourceware.org X-SW-Source: 2011-02/txt/msg00312.txt.bz2 On Thu, Feb 24, 2011 at 11:49 PM, Alan Modra wrote: > On Thu, Feb 24, 2011 at 03:49:25PM -0800, H.J. Lu wrote: >> On Tue, Jul 20, 2010 at 7:10 AM, Alan Modra wrote: >> > This removes all the special treatment for zero size sections when >> > using ELF_SECTION_IN_SEGMENT in elf.c, and makes readelf display > [snip] >> This may have caused: >> >> http://sourceware.org/bugzilla/show_bug.cgi?id=3D12516 > > Yes, looks like it. > > =A0 =A0 =A0 =A0PR 12519 > =A0 =A0 =A0 =A0* internal.h (ELF_SECTION_IN_SEGMENT_1): Don't match zero = size > =A0 =A0 =A0 =A0sections at start or end of PT_DYNAMIC. I checked in this. H.J. --- diff --git a/ld/testsuite/ChangeLog b/ld/testsuite/ChangeLog index b7de27d..4ff663f 100644 --- a/ld/testsuite/ChangeLog +++ b/ld/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2011-02-25 H.J. Lu + + PR ld/12516 + * ld-elf/dynamic1.d: New. + * ld-elf/dynamic1.ld: Likewise. + * ld-elf/dynamic1.s: Likewise. + 2011-02-25 Alan Modra * ld-mn10300/i135409-3.s: Correct .size label reference. diff --git a/ld/testsuite/ld-elf/dynamic1.d b/ld/testsuite/ld-elf/dynamic1.d new file mode 100644 index 0000000..6a8ba55 --- /dev/null +++ b/ld/testsuite/ld-elf/dynamic1.d @@ -0,0 +1,10 @@ +#ld: -shared -T dynamic1.ld +#readelf: -l --wide +#target: *-*-linux* *-*-gnu* + +#... + Section to Segment mapping: + Segment Sections... +#... + 0[1-9] .dynamic[ ]* +#pass diff --git a/ld/testsuite/ld-elf/dynamic1.ld b/ld/testsuite/ld-elf/dynamic1= .ld new file mode 100644 index 0000000..d110bf7 --- /dev/null +++ b/ld/testsuite/ld-elf/dynamic1.ld @@ -0,0 +1,8 @@ +SECTIONS +{ + . =3D SIZEOF_HEADERS; + .text : { *(.text) } + .data : { *(.data) } + .data1 : { KEEP (*(.data1)) } + .dynamic : { *(.dynamic) } +} diff --git a/ld/testsuite/ld-elf/dynamic1.s b/ld/testsuite/ld-elf/dynamic1.s new file mode 100644 index 0000000..f1caf0e --- /dev/null +++ b/ld/testsuite/ld-elf/dynamic1.s @@ -0,0 +1,2 @@ +.section .data1,"aw" +.balign 16