From patchwork Wed Jul 7 19:18:21 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Anatoly Sokolov X-Patchwork-Id: 58153 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id 20E92B6ED0 for ; Thu, 8 Jul 2010 05:18:25 +1000 (EST) Received: (qmail 1511 invoked by alias); 7 Jul 2010 19:18:24 -0000 Received: (qmail 1498 invoked by uid 22791); 7 Jul 2010 19:18:22 -0000 X-SWARE-Spam-Status: No, hits=2.8 required=5.0 tests=AWL, BAYES_20, KAM_THEBAT, RCVD_IN_DNSWL_NONE, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from contrabass.post.ru (HELO contrabass.post.ru) (85.21.78.5) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 07 Jul 2010 19:18:17 +0000 Received: from corbina.ru (mail.post.ru [195.14.50.16]) by contrabass.post.ru (Postfix) with ESMTP id BFBBA7DEC; Wed, 7 Jul 2010 23:18:14 +0400 (MSD) Received: from [95.27.237.173] (account aesok@post.ru HELO Vista.corbina.ru) by corbina.ru (CommuniGate Pro SMTP 5.1.14) with ESMTPA id 230234217; Wed, 07 Jul 2010 23:18:14 +0400 Date: Wed, 7 Jul 2010 23:18:21 +0400 From: Anatoly Sokolov Message-ID: <104346215.20100707231821@post.ru> To: gcc-patches CC: Steve Ellcey Subject: [IA64] Hookize OVERRIDE_OPTIONS MIME-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Hello. This patch removes obsolete OVERRIDE_OPTIONS macro from IA64 back end in the GCC and introduces equivalent TARGET_OPTION_OVERRIDE target hooks.  Bootstrapped and regression tested on ia64-unknown-linux-gnu. OK to install? * config/ia64/ia64.h (OVERRIDE_OPTIONS): Remove macros. * config/ia64/ia64-protos.h (ia64_override_options): Remove. * config/ia64/ia64.c (TARGET_OPTION_OVERRIDE): Define. (ia64_override_options): Rename to... (ia64_option_override): ... this one. Make static. Anatoly. Index: gcc/config/ia64/ia64.c =================================================================== --- gcc/config/ia64/ia64.c (revision 161930) +++ gcc/config/ia64/ia64.c (working copy) @@ -200,6 +200,7 @@ static rtx gen_fr_spill_x (rtx, rtx, rtx); static rtx gen_fr_restore_x (rtx, rtx, rtx); +static void ia64_option_override (void); static bool ia64_can_eliminate (const int, const int); static enum machine_mode hfa_element_mode (const_tree, bool); static void ia64_setup_incoming_varargs (CUMULATIVE_ARGS *, enum machine_mode, @@ -353,6 +354,9 @@ #undef TARGET_ASM_INTEGER #define TARGET_ASM_INTEGER ia64_assemble_integer +#undef TARGET_OPTION_OVERRIDE +#define TARGET_OPTION_OVERRIDE ia64_option_override + #undef TARGET_ASM_FUNCTION_PROLOGUE #define TARGET_ASM_FUNCTION_PROLOGUE ia64_output_function_prologue #undef TARGET_ASM_FUNCTION_END_PROLOGUE @@ -5563,10 +5567,10 @@ } } -/* Implement OVERRIDE_OPTIONS. */ +/* Implement TARGET_OPTION_OVERRIDE. */ -void -ia64_override_options (void) +static void +ia64_option_override (void) { if (TARGET_AUTO_PIC) target_flags |= MASK_CONST_GP; Index: gcc/config/ia64/ia64.h =================================================================== --- gcc/config/ia64/ia64.h (revision 161930) +++ gcc/config/ia64/ia64.h (working copy) @@ -116,13 +116,6 @@ extern enum processor_type ia64_tune; -/* Sometimes certain combinations of command options do not make sense on a - particular target machine. You can define a macro `OVERRIDE_OPTIONS' to - take account of this. This macro, if defined, is executed once just after - all the command options have been parsed. */ - -#define OVERRIDE_OPTIONS ia64_override_options () - /* Some machines may desire to change what optimizations are performed for various optimization levels. This macro, if defined, is executed once just after the optimization level is determined and before the remainder of the Index: gcc/config/ia64/ia64-protos.h =================================================================== --- gcc/config/ia64/ia64-protos.h (revision 161930) +++ gcc/config/ia64/ia64-protos.h (working copy) @@ -86,7 +86,6 @@ extern int ia64_eh_uses (int); extern void emit_safe_across_calls (void); extern void ia64_init_builtins (void); -extern void ia64_override_options (void); extern int ia64_dbx_register_number (int); extern rtx ia64_return_addr_rtx (HOST_WIDE_INT, rtx);