From patchwork Fri Oct 15 00:48:14 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 67878 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 85FA9B70D0 for ; Fri, 15 Oct 2010 11:48:26 +1100 (EST) Received: (qmail 23312 invoked by alias); 15 Oct 2010 00:48:24 -0000 Received: (qmail 23303 invoked by uid 22791); 15 Oct 2010 00:48:23 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL, BAYES_00, T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 15 Oct 2010 00:48:17 +0000 Received: (qmail 7867 invoked from network); 15 Oct 2010 00:48:15 -0000 Received: from unknown (HELO digraph.polyomino.org.uk) (joseph@127.0.0.2) by mail.codesourcery.com with ESMTPA; 15 Oct 2010 00:48:15 -0000 Received: from jsm28 (helo=localhost) by digraph.polyomino.org.uk with local-esmtp (Exim 4.69) (envelope-from ) id 1P6YT0-0006om-I3; Fri, 15 Oct 2010 00:48:14 +0000 Date: Fri, 15 Oct 2010 00:48:14 +0000 (UTC) From: "Joseph S. Myers" To: gcc-patches@gcc.gnu.org, edelsohn@gnu.org Subject: rs6000_option_optimization section anchors cleanup Message-ID: MIME-Version: 1.0 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 Continuing cleanups to TARGET_OPTION_OPTIMIZATION hooks, this patch removes a hack in rs6000_option_optimization. There *used* to be problems with section anchors for Objective-C: bug 41848, resulting in a hack in this back end to disable them in that case. At that bug shows, those problems were fixed, meaning that such a hack did not need to be introduced for ARM, and the hack should be removed for rs6000 as well, which this patch does. Tested by building cc1 for a cross to powerpc-eabi. OK to commit? 2010-10-14 Joseph Myers * config/rs6000/rs6000.c (rs6000_option_optimization): Don't disable section anchors for lang_hooks.name[4] != 'O'. Index: gcc/config/rs6000/rs6000.c =================================================================== --- gcc/config/rs6000/rs6000.c (revision 165460) +++ gcc/config/rs6000/rs6000.c (working copy) @@ -3690,10 +3690,8 @@ rs6000_option_optimization (int level AT avoid calling them when that's the only reason we would. */ flag_errno_math = 0; - /* Enable section anchors by default. - Skip section anchors for Objective C and Objective C++ - until front-ends fixed. */ - if (!TARGET_MACHO && lang_hooks.name[4] != 'O') + /* Enable section anchors by default. */ + if (!TARGET_MACHO) flag_section_anchors = 2; }