From patchwork Tue Jun 18 19:04:56 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rempel, Cynthia" X-Patchwork-Id: 252413 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]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "localhost", Issuer "www.qmailtoaster.com" (not verified)) by ozlabs.org (Postfix) with ESMTPS id A84BA2C0099 for ; Wed, 19 Jun 2013 05:05:35 +1000 (EST) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:references:in-reply-to:content-type :content-transfer-encoding:mime-version; q=dns; s=default; b=Xts 25/aD7EKuFqtz9wxA7h7qIqcEB/Vow7hJdmTDso4n4mbdHhyWRia31RBWQ4K3Rck 1KAk4jtEhtd2361ORjaBIGO+ocG9OhCCPTM+6YiiPxsJNCiw9uxSaYruh3/Y6+6Z fOvkxRp3XoyxzgVFFJ7XYwKucMWz16vBH0ZcvDc4= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:from :to:subject:date:message-id:references:in-reply-to:content-type :content-transfer-encoding:mime-version; s=default; bh=4n7cVNLzu swxeDTYCzsvgeOvaxI=; b=BMznm9cle5fVc1GWq/QH7BEDvCyDoUUgltolI/9Ma U0FCOu+4kI21utEoeaAvNODpQizv3mNyTlJv820GG+pyFb95h1r2VzaUZRh+u1Ig livD+wdLzxh/wCqNhxf3tfmjzdIT+/A0qX+IIf9UmjvGGcHQu+wnie7lYuoPl188 jg= Received: (qmail 6062 invoked by alias); 18 Jun 2013 19:05:28 -0000 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 Received: (qmail 6047 invoked by uid 89); 18 Jun 2013 19:05:28 -0000 X-Spam-SWARE-Status: No, score=-5.4 required=5.0 tests=BAYES_00, KHOP_THREADED, RCVD_IN_DNSWL_NONE, RCVD_IN_HOSTKARMA_W, RCVD_IN_HOSTKARMA_WL, SPF_PASS, TW_LG autolearn=ham version=3.3.1 Received: from mail-db9lp0252.outbound.messaging.microsoft.com (HELO db9outboundpool.messaging.microsoft.com) (213.199.154.252) by sourceware.org (qpsmtpd/0.84/v0.84-167-ge50287c) with ESMTP; Tue, 18 Jun 2013 19:05:07 +0000 Received: from mail159-db9-R.bigfish.com (10.174.16.254) by DB9EHSOBE014.bigfish.com (10.174.14.77) with Microsoft SMTP Server id 14.1.225.23; Tue, 18 Jun 2013 19:05:04 +0000 Received: from mail159-db9 (localhost [127.0.0.1]) by mail159-db9-R.bigfish.com (Postfix) with ESMTP id 3BCAE10011C; Tue, 18 Jun 2013 19:05:04 +0000 (UTC) X-Forefront-Antispam-Report: CIP:157.56.240.85; KIP:(null); UIP:(null); IPV:NLI; H:BL2PRD0410HT004.namprd04.prod.outlook.com; RD:none; EFVD:NLI X-SpamScore: 24 X-BigFish: PS24(zz9371I936eI154dIc8kzz1f42h1d77h1ee6h1de0h1fdah1202h1e76h1d1ah1d2ah1fc6h1648lzz17326ah8275dhz2fh2a8h668h839h944hd24hf0ah1220h1288h12a5h12a9h12bdh137ah13b6h1441h1504h1537h153bh162dh1631h1758h18e1h1946h19b5h19ceh1ad9h1b0ah1d07h1d0ch1d2eh1d3fh1de9h1dfeh1dffh1e1dh9a9j1deas1b1cn1b1bi1155h) Received-SPF: pass (mail159-db9: domain of vandals.uidaho.edu designates 157.56.240.85 as permitted sender) client-ip=157.56.240.85; envelope-from=cynt6007@vandals.uidaho.edu; helo=BL2PRD0410HT004.namprd04.prod.outlook.com ; .outlook.com ; X-Forefront-Antispam-Report-Untrusted: SFV:SKI; SFS:; DIR:OUT; SFP:; SCL:-1; SRVR:BY2PR04MB192; H:BY2PR04MB189.namprd04.prod.outlook.com; LANG:en; Received: from mail159-db9 (localhost.localdomain [127.0.0.1]) by mail159-db9 (MessageSwitch) id 137158230372862_10393; Tue, 18 Jun 2013 19:05:03 +0000 (UTC) Received: from DB9EHSMHS022.bigfish.com (unknown [10.174.16.239]) by mail159-db9.bigfish.com (Postfix) with ESMTP id 030CA420262; Tue, 18 Jun 2013 19:05:03 +0000 (UTC) Received: from BL2PRD0410HT004.namprd04.prod.outlook.com (157.56.240.85) by DB9EHSMHS022.bigfish.com (10.174.14.32) with Microsoft SMTP Server (TLS) id 14.16.227.3; Tue, 18 Jun 2013 19:05:02 +0000 Received: from BY2PR04MB192.namprd04.prod.outlook.com (10.242.40.149) by BL2PRD0410HT004.namprd04.prod.outlook.com (10.255.99.39) with Microsoft SMTP Server (TLS) id 14.16.324.0; Tue, 18 Jun 2013 19:04:59 +0000 Received: from BY2PR04MB189.namprd04.prod.outlook.com (10.242.40.145) by BY2PR04MB192.namprd04.prod.outlook.com (10.242.40.149) with Microsoft SMTP Server (TLS) id 15.0.702.21; Tue, 18 Jun 2013 19:04:57 +0000 Received: from BY2PR04MB189.namprd04.prod.outlook.com ([169.254.16.89]) by BY2PR04MB189.namprd04.prod.outlook.com ([169.254.16.89]) with mapi id 15.00.0702.005; Tue, 18 Jun 2013 19:04:56 +0000 From: "Rempel, Cynthia" To: "Joel.Sherrill@OARCorp.com" , "gcc-patches@gcc.gnu.org" , "Sebastian.Huber@embedded-brains.de" Subject: FW: [PATCH] RTEMS: Use strict DWARF-2 on ARM, PowerPC, SPARC Date: Tue, 18 Jun 2013 19:04:56 +0000 Message-ID: <33926d33c8fd409dba7b6b0890fc86c6@BY2PR04MB189.namprd04.prod.outlook.com> References: <1371556682-799-1-git-send-email-sebastian.huber@embedded-brains.de> In-Reply-To: <1371556682-799-1-git-send-email-sebastian.huber@embedded-brains.de> MIME-Version: 1.0 X-OriginatorOrg: vandals.uidaho.edu X-FOPE-CONNECTOR: Id%0$Dn%*$RO%0$TLS%0$FQDN%$TlsDn% Hi, Forwarding this patch to gcc-patches... Cheers! Cindy diff --git a/gcc/config.gcc b/gcc/config.gcc index 1a0be50..6394551 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -734,6 +734,7 @@ case ${target} in yes) thread_file='rtems' ;; esac extra_options="${extra_options} rtems.opt" + extra_objs="rtems.o" use_gcc_stdint=wrap ;; *-*-uclinux*) diff --git a/gcc/config/arm/rtems-eabi.h b/gcc/config/arm/rtems-eabi.h index 77fcf1a..a7ccdae 100644 --- a/gcc/config/arm/rtems-eabi.h +++ b/gcc/config/arm/rtems-eabi.h @@ -27,3 +27,6 @@ builtin_assert ("system=rtems"); \ TARGET_BPABI_CPP_BUILTINS(); \ } while (0) + +#undef SUBTARGET_OVERRIDE_OPTIONS +#define SUBTARGET_OVERRIDE_OPTIONS RTEMS_OVERRIDE_OPTIONS diff --git a/gcc/config/rs6000/rtems.h b/gcc/config/rs6000/rtems.h index b910b5e..cf53592 100644 --- a/gcc/config/rs6000/rtems.h +++ b/gcc/config/rs6000/rtems.h @@ -34,6 +34,9 @@ } \ while (0) +#undef SUBSUBTARGET_OVERRIDE_OPTIONS +#define SUBSUBTARGET_OVERRIDE_OPTIONS RTEMS_OVERRIDE_OPTIONS + #undef CPP_OS_DEFAULT_SPEC #define CPP_OS_DEFAULT_SPEC "%(cpp_os_rtems)" diff --git a/gcc/config/rtems.c b/gcc/config/rtems.c new file mode 100644 index 0000000..4250ba3 --- /dev/null +++ b/gcc/config/rtems.c @@ -0,0 +1,37 @@ +/* Common RTEMS target definitions for GNU compiler. + Copyright (C) 2013 Free Software Foundation, Inc. + +This file is part of GCC. + +GCC is free software; you can redistribute it and/or modify it under +the terms of the GNU General Public License as published by the Free +Software Foundation; either version 3, or (at your option) any later +version. + +GCC is distributed in the hope that it will be useful, but WITHOUT ANY +WARRANTY; without even the implied warranty of MERCHANTABILITY or +FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License +for more details. + +You should have received a copy of the GNU General Public License +along with GCC; see the file COPYING3. If not see +. */ + +#include "config.h" +#include "system.h" +#include "coretypes.h" +#include "target.h" +#include "tm.h" + +void +rtems_override_options (void) +{ + /* Use strict DWARF-2 unless specifically selected. This is a + workaround for a lack of tool support. */ + + if (!global_options_set.x_dwarf_strict) + dwarf_strict = 1; + + if (!global_options_set.x_dwarf_version) + dwarf_version = 2; +} diff --git a/gcc/config/rtems.h b/gcc/config/rtems.h index 4d94f82..8ea97fe 100644 --- a/gcc/config/rtems.h +++ b/gcc/config/rtems.h @@ -43,3 +43,7 @@ along with GCC; see the file COPYING3. If not see -lc -lgcc --end-group %{!qnolinkcmds: -T linkcmds%s}}}" #define TARGET_POSIX_IO + +/* Do RTEMS specific parts of TARGET_OPTION_OVERRIDE. */ +extern void rtems_override_options (void); +#define RTEMS_OVERRIDE_OPTIONS rtems_override_options () diff --git a/gcc/config/sparc/rtemself.h b/gcc/config/sparc/rtemself.h index 7a69dfa..2ee939c 100644 --- a/gcc/config/sparc/rtemself.h +++ b/gcc/config/sparc/rtemself.h @@ -29,5 +29,8 @@ along with GCC; see the file COPYING3. If not see } \ while (0) +#undef SUBTARGET_OVERRIDE_OPTIONS +#define SUBTARGET_OVERRIDE_OPTIONS RTEMS_OVERRIDE_OPTIONS + /* Use the default */ #undef LINK_GCC_C_SEQUENCE_SPEC diff --git a/gcc/config/t-rtems b/gcc/config/t-rtems index baa00d8..5a8e88a 100644 --- a/gcc/config/t-rtems +++ b/gcc/config/t-rtems @@ -1,2 +1,6 @@ # RTEMS always has limits.h. LIMITS_H_TEST = true + +rtems.o: $(srcdir)/config/rtems.c $(CONFIG_H) $(SYSTEM_H) coretypes.h \ + $(TARGET_H) $(TM_H) + $(COMPILER) -c $(ALL_COMPILERFLAGS) $(ALL_CPPFLAGS) $(INCLUDES) $<