From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2702 invoked by alias); 1 Mar 2005 02:36:17 -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 2570 invoked from network); 1 Mar 2005 02:36:09 -0000 Received: from unknown (205.217.158.180) by sourceware.org with QMTP; 1 Mar 2005 02:36:09 -0000 Received: (qmail 16909 invoked by uid 10); 1 Mar 2005 02:36:09 -0000 Received: (qmail 7864 invoked by uid 500); 1 Mar 2005 02:36:00 -0000 Mail-Followup-To: binutils@sources.redhat.com, amodra@bigpond.net.au To: Alan Modra Cc: binutils@sources.redhat.com Subject: Re: compiling binutils with -DDEBUG References: <20050301020120.GJ5299@bubble.modra.org> From: Ian Lance Taylor Date: Tue, 01 Mar 2005 02:36:00 -0000 In-Reply-To: <20050301020120.GJ5299@bubble.modra.org> Message-ID: User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2005-03/txt/msg00004.txt.bz2 Alan Modra writes: > (fixup_segment): Remove assertion. > Didn't seem worth including struct-symbol.h just for this. I suspect > the assertion isn't true too, since a similar assertion in obj-coff.c > fails with X_op an O_constant. Maybe this is a real bug. Ian, you're > probably the only one who can answer mri mode queries off the top of > your head. Care to comment? > @@ -2583,7 +2585,6 @@ fixup_segment (fixS *fixP, segT this_seg > if (fixP->fx_addsy != NULL > && symbol_mri_common_p (fixP->fx_addsy)) > { > - know (fixP->fx_addsy->sy_value.X_op == O_symbol); > add_number += S_GET_VALUE (fixP->fx_addsy); > fixP->fx_offset = add_number; > fixP->fx_addsy The assertion should be true. This is a symbol defined in an MRI common section. Since we don't generate IEEE object files, we treat an MRI common section as a single large common symbol. Then we handle a reloc against a symbol defined within an MRI common section as an offset to that symbol. The assertion is just checking that we really do point to the magic symbol we are using for the MRI common section. So, I don't think it's a bug, but since MRI mode is not very important I don't think we need to keep the assertion if it's convenient to remove it. Ian