From patchwork Wed May 15 12:39:26 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Christophe Lyon X-Patchwork-Id: 164276 Delivered-To: patch@linaro.org Received: by 2002:ac9:2a84:0:0:0:0:0 with SMTP id p4csp602202oca; Wed, 15 May 2019 05:40:55 -0700 (PDT) X-Google-Smtp-Source: APXvYqzMssO1MCbjH7nXVp9hOaSMmqjf4tx6zj/vmOmjSq8R+0mgVunTN/Bg207UbvQDtez7oCOj X-Received: by 2002:a63:1d05:: with SMTP id d5mr43420417pgd.157.1557924055022; Wed, 15 May 2019 05:40:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1557924055; cv=none; d=google.com; s=arc-20160816; b=mUjcmV0uKnLb1IdBM1NhK10LXUAGJ8ExDi+CC/r5i8B9Bgn8qn3W+sZGK/oxLeM+sl LWxb1oad36wEGixIeg1UFNTsiFmumVZpDoRxcfmVAd2J60c43QbBCv5OT7c7aeXip6uc gpD+Xqvt0G2nwrizFrVlheGX2Fjw0+ucLCeg4cm/68sd2oKrLuubuGaA6MxCFOIWCo8M Ap3J7bMlu2IV361ApJSvGpbEPf6PzToUIt7rsoHEi6mqyiQ6a8j3ZUF0mKW1kehaQtle NrbDQuQ3tkFYQGsI46b1e6488V5SUlyDZsct/4g5rLwClOQb8xZ+F7HiQH8nu1h1N050 g4jg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:dkim-signature:delivered-to:sender :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mailing-list:dkim-signature:domainkey-signature; bh=aWwxTkIWEvWAbPorTqMtQcgPqhxKxdJzMlCX72tYqCY=; b=HzjCuBCZi6hlUyT02CRtzd8Xzf3Cp1X/b7KUaoRNkXuFHMwdSwdsm+hrITFqokIwpB qSazDsuLawaj99obycny00BYZ+almiBtGZ2F/JTjtt7AbT6DEzo7qAEmv4lmMEP6pyZf fTU238P8HanojMGCNzgfX+tRmhdDWe8VpyYT4ECuBRorDZxf274/nhYi51oUAndYX0to DgUILHe1dytzdbrpgm3YhD05tLSOfLJytWOS8iMe2FW93+BLd0OZQ31wG1/lg5J2pon2 jD5rKFA9C/e/iJ39hxAS2xTHz3M6MATfezcP8hSrW9BZD3CHpzJN5I9VlwyilVq4GMKc T3tA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=TNpvr2Nc; dkim=pass header.i=@st.com header.s=STMicroelectronics header.b=UK9kmKmY; spf=pass (google.com: domain of gcc-patches-return-500765-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom="gcc-patches-return-500765-patch=linaro.org@gcc.gnu.org" Return-Path: Received: from sourceware.org (server1.sourceware.org. [209.132.180.131]) by mx.google.com with ESMTPS id f62si1722971plb.339.2019.05.15.05.40.54 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 15 May 2019 05:40:55 -0700 (PDT) Received-SPF: pass (google.com: domain of gcc-patches-return-500765-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) client-ip=209.132.180.131; Authentication-Results: mx.google.com; dkim=pass header.i=@gcc.gnu.org header.s=default header.b=TNpvr2Nc; dkim=pass header.i=@st.com header.s=STMicroelectronics header.b=UK9kmKmY; spf=pass (google.com: domain of gcc-patches-return-500765-patch=linaro.org@gcc.gnu.org designates 209.132.180.131 as permitted sender) smtp.mailfrom="gcc-patches-return-500765-patch=linaro.org@gcc.gnu.org" 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:in-reply-to:references:mime-version :content-type:content-transfer-encoding; q=dns; s=default; b=CLV Qom8ZlGUHkh66QpiZ3qhLY/pgFIG9vYAgDNvEy/xeu+r1smaRVtYUY3kq6+3MAap HrBt7jqmCYQEkeOmq22tfeB9N5/YMewGZDGTedOIrqZDJupu3DgaKvfmG5fvSM1Q bI2KUxZDq3ggpzUOyUTxPRcKXzg3A0H4uMr53sZI= 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:in-reply-to:references:mime-version :content-type:content-transfer-encoding; s=default; bh=p0m/wmin/ E/RWuDg94FKxVva9aA=; b=TNpvr2NcHuL1VtN/ZL1+TEAum2Xv72RMU8CQF51Oi qLNqeKf+0TZRDkPeafP3fMzAXSrLw5a2rPrJChtyNZN2JxCqbEzA93R0sESBEvaN jykCpd90YrlD9K99s3N2aOz4fQ09CcAkN6Q8fqHioSNqgpkptfbzYcz1L6Xmz9r6 +g= Received: (qmail 128571 invoked by alias); 15 May 2019 12:40:41 -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 128463 invoked by uid 89); 15 May 2019 12:40:41 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-14.6 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.1 spammy=Requirements, gun, Specification X-HELO: mx07-00178001.pphosted.com Received: from mx07-00178001.pphosted.com (HELO mx07-00178001.pphosted.com) (62.209.51.94) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 15 May 2019 12:40:40 +0000 Received: from pps.filterd (m0046668.ppops.net [127.0.0.1]) by mx07-00178001.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x4FCcNsu003671 for ; Wed, 15 May 2019 14:40:36 +0200 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=st.com; h=from : to : subject : date : message-id : in-reply-to : references : mime-version : content-type : content-transfer-encoding; s=STMicroelectronics; bh=aWwxTkIWEvWAbPorTqMtQcgPqhxKxdJzMlCX72tYqCY=; b=UK9kmKmYfDuwRqjXGtdImIgdDK6/Ze/S9L59pEZvAMJGRGGgHuy/018AHIvJFMOJLmIP NLyKkke//bkDq+p1HbA770Wg6dsJclksYoWvRTg7zC1umuExTwNwXSL7vmdnCT4zfVNm BD7ENvWuwAHn4+ZgMRRJcjoR4arhgODsRUcrdCaoTOrUrdKizeV4o6VGr5RLiOklayf2 NpD0KOEVXRDv38s06XRT4Jw3DqHA0BZ1qwnKUt75hzCKa4gdLg05npUMgq0jXkZjuYk1 xc3VDHjsBAW1B0ZrbLbVjFPSVye4niBRv5vQLX1BpmVNNLRDEuQR98TimNpQKHA2pNKT NA== Received: from beta.dmz-eu.st.com (beta.dmz-eu.st.com [164.129.1.35]) by mx07-00178001.pphosted.com with ESMTP id 2sdkv00gdr-1 (version=TLSv1 cipher=ECDHE-RSA-AES256-SHA bits=256 verify=NOT) for ; Wed, 15 May 2019 14:40:36 +0200 Received: from zeta.dmz-eu.st.com (zeta.dmz-eu.st.com [164.129.230.9]) by beta.dmz-eu.st.com (STMicroelectronics) with ESMTP id 4B69A38 for ; Wed, 15 May 2019 12:40:35 +0000 (GMT) Received: from Webmail-eu.st.com (sfhdag5node1.st.com [10.75.127.13]) by zeta.dmz-eu.st.com (STMicroelectronics) with ESMTP id AC48E2736 for ; Wed, 15 May 2019 12:40:34 +0000 (GMT) Received: from gnb.st.com (10.75.127.45) by SFHDAG5NODE1.st.com (10.75.127.13) with Microsoft SMTP Server (TLS) id 15.0.1347.2; Wed, 15 May 2019 14:40:33 +0200 From: Christophe Lyon To: Subject: [ARM/FDPIC v5 01/21] [ARM] FDPIC: Add -mfdpic option support Date: Wed, 15 May 2019 14:39:26 +0200 Message-ID: <20190515124006.25840-2-christophe.lyon@st.com> In-Reply-To: <20190515124006.25840-1-christophe.lyon@st.com> References: <20190515124006.25840-1-christophe.lyon@st.com> MIME-Version: 1.0 X-IsSubscribed: yes 2019-XX-XX Christophe Lyon Mickaël Guêné gcc/ * config/arm/arm.opt: Add -mfdpic option. * doc/invoke.texi: Add documentation for -mfdpic. Change-Id: I0eabd1d11c9406fd4a43c4333689ebebbfcc4fe8 -- 2.6.3 diff --git a/gcc/config/arm/arm.opt b/gcc/config/arm/arm.opt index 9067d49..2ed3bd5 100644 --- a/gcc/config/arm/arm.opt +++ b/gcc/config/arm/arm.opt @@ -306,3 +306,7 @@ Cost to assume for a branch insn. mgeneral-regs-only Target Report RejectNegative Mask(GENERAL_REGS_ONLY) Save Generate code which uses the core registers only (r0-r14). + +mfdpic +Target Report Mask(FDPIC) +Enable Function Descriptor PIC mode. diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 29585cf..805d7cc 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -703,7 +703,8 @@ Objective-C and Objective-C++ Dialects}. -mrestrict-it @gol -mverbose-cost-dump @gol -mpure-code @gol --mcmse} +-mcmse @gol +-mfdpic} @emph{AVR Options} @gccoptlist{-mmcu=@var{mcu} -mabsdata -maccumulate-args @gol @@ -17912,6 +17913,23 @@ MOVT instruction. Generate secure code as per the "ARMv8-M Security Extensions: Requirements on Development Tools Engineering Specification", which can be found on @url{http://infocenter.arm.com/help/topic/com.arm.doc.ecm0359818/ECM0359818_armv8m_security_extensions_reqs_on_dev_tools_1_0.pdf}. + +@item -mfdpic +@itemx -mno-fdpic +@opindex mfdpic +@opindex mno-fdpic +Select the FDPIC ABI, which uses function descriptors to represent +pointers to functions. When the compiler is configured for +@code{arm-*-uclinuxfdpiceabi} targets, this option is on by default +and implies @option{-fPIE} if none of the PIC/PIE-related options is +provided. On other targets, it only enables the FDPIC-specific code +generation features, and the user should explicitly provide the +PIC/PIE-related options as needed. + +The opposite @option{-mno-fdpic} option is useful (and required) to +build the Linux kernel using the same (@code{arm-*-uclinuxfdpiceabi}) +toolchain as the one used to build the userland programs. + @end table @node AVR Options