From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13821 invoked by alias); 25 May 2005 08:39:07 -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 13779 invoked by uid 22791); 25 May 2005 08:38:59 -0000 Received: from cam-admin0.cambridge.arm.com (HELO cam-admin0.cambridge.arm.com) (193.131.176.58) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Wed, 25 May 2005 08:38:59 +0000 Received: from pc960.cambridge.arm.com (pc960.cambridge.arm.com [10.1.205.4]) by cam-admin0.cambridge.arm.com (8.12.10/8.12.10) with ESMTP id j4P8cSeS000752; Wed, 25 May 2005 09:38:28 +0100 (BST) Received: from pc960.cambridge.arm.com (localhost.localdomain [127.0.0.1]) by pc960.cambridge.arm.com (8.12.8/8.12.8) with ESMTP id j4P8cabC021972; Wed, 25 May 2005 09:38:37 +0100 Received: (from rearnsha@localhost) by pc960.cambridge.arm.com (8.12.8/8.12.8/Submit) id j4P8ca5l021970; Wed, 25 May 2005 09:38:36 +0100 X-Authentication-Warning: pc960.cambridge.arm.com: rearnsha set sender to rearnsha@gcc.gnu.org using -f Subject: Re: Fix some of the ARM GAS failures From: Richard Earnshaw To: Zack Weinberg Cc: Nick Clifton , binutils@sourceware.org In-Reply-To: <1116965825.7031.16.camel@localhost.localdomain> References: <1116965825.7031.16.camel@localhost.localdomain> Content-Type: text/plain Content-Transfer-Encoding: 7bit Message-Id: <1117010314.7618.15.camel@pc960.cambridge.arm.com> Mime-Version: 1.0 Date: Wed, 25 May 2005 13:42:00 -0000 X-SW-Source: 2005-05/txt/msg00697.txt.bz2 On Tue, 2005-05-24 at 21:17, Zack Weinberg wrote: > This patch should improve the ARM-GAS situation somewhat. md_apply_fix3 > needs to truncate the relocation to 32 signed bits manually; if the host > is 64-bit, fx_addnumber and fx_offset are 64-bit, and may generate > spurious overflows. Also, we need a double cast on both sides of the > hack to pass an integer around in tc_fix_data. > AFAICT tc_fix_data is a private type to the ARM-specific parts of the assembler. Since storing the thumbness is the only use, and the type of tc_fix_data is defined in tc-arm.h (TC_FIX_TYPE), it would make much more sense to just change TC_FIX_TYPE to 'int' and get rid of all those nasty casts. Otherwise OK. R. > zw > * config/tc-arm.c (fix_new_arm): Cast thumb_mode to size_t > before casting it to PTR. > (md_apply_fix3): Truncate value, *valP, fixP->fx_addnumber, > and fixP->fx_offset to 32 signed bits.