From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26462 invoked by alias); 1 Mar 2013 17:36:08 -0000 Received: (qmail 26323 invoked by uid 22791); 1 Mar 2013 17:36:01 -0000 X-SWARE-Spam-Status: No, hits=-5.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from mail-pb0-f43.google.com (HELO mail-pb0-f43.google.com) (209.85.160.43) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 01 Mar 2013 17:35:40 +0000 Received: by mail-pb0-f43.google.com with SMTP id md12so1887918pbc.16 for ; Fri, 01 Mar 2013 09:35:39 -0800 (PST) X-Received: by 10.66.240.136 with SMTP id wa8mr19512073pac.143.1362159339873; Fri, 01 Mar 2013 09:35:39 -0800 (PST) Received: from fremont.twiddle.net (50-194-63-110-static.hfc.comcastbusiness.net. [50.194.63.110]) by mx.google.com with ESMTPS id kl4sm12679430pbc.31.2013.03.01.09.35.37 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 01 Mar 2013 09:35:38 -0800 (PST) From: Richard Henderson To: libc-ports@sourceware.org Cc: joseph@codesourcery.com Subject: [PATCH v2 04/14] arm: Enable thumb2 mode in assembly files Date: Fri, 01 Mar 2013 17:36:00 -0000 Message-Id: <1362159320-5934-5-git-send-email-rth@twiddle.net> In-Reply-To: <1362159320-5934-1-git-send-email-rth@twiddle.net> References: <1362159320-5934-1-git-send-email-rth@twiddle.net> X-IsSubscribed: yes Mailing-List: contact libc-ports-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: libc-ports-owner@sourceware.org X-SW-Source: 2013-03/txt/msg00011.txt.bz2 The preceeding patches have allowed for the few incompatibilities between arm and thumb2 mode, or have marked the file as not wanting to use thumb2 mode. --- * sysdeps/arm/sysdep.h [__ASSEMBLER__]: Enable thumb2 if __thumb2__. (PC_OFS): Respect __thumb__ if __ASSEMBLER__. --- ports/sysdeps/arm/sysdep.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/ports/sysdeps/arm/sysdep.h b/ports/sysdeps/arm/sysdep.h index c525d5b..d855ceb 100644 --- a/ports/sysdeps/arm/sysdep.h +++ b/ports/sysdeps/arm/sysdep.h @@ -117,6 +117,16 @@ the caller. */ .eabi_attribute 24, 1 +/* The thumb2 encoding is reasonably complete. Unless suppressed, use it. */ + .syntax unified +# if defined(__thumb2__) && !defined(NO_THUMB) + .thumb +#else +# undef __thumb__ +# undef __thumb2__ + .arm +# endif + /* Load or store to/from a pc-relative EXPR into/from R, using T. */ # ifdef __thumb2__ # define LDST_PCREL(OP, R, T, EXPR) \ @@ -172,8 +182,7 @@ #endif /* __ASSEMBLER__ */ /* This number is the offset from the pc at the current location. */ -/* ??? At the moment we're not turning on thumb mode in assembly. */ -#if defined(__thumb__) && !defined(__ASSEMBLER__) +#ifdef __thumb__ # define PC_OFS 4 #else # define PC_OFS 8 -- 1.8.1.2