From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 102999 invoked by alias); 25 Jul 2018 00:17:36 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Received: (qmail 102959 invoked by uid 89); 25 Jul 2018 00:17:31 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,SPF_PASS autolearn=ham version=3.3.2 spammy=Hx-languages-length:1251, H*r:0700, HContent-Transfer-Encoding:8bit X-HELO: relay1.mentorg.com Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 25 Jul 2018 00:17:30 +0000 Received: from svr-orw-mbx-03.mgc.mentorg.com ([147.34.90.203]) by relay1.mentorg.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-SHA384:256) id 1fi7Ud-0007fA-7C from Sandra_Loosemore@mentor.com ; Tue, 24 Jul 2018 17:17:27 -0700 Received: from [127.0.0.1] (147.34.91.1) by svr-orw-mbx-03.mgc.mentorg.com (147.34.90.203) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Tue, 24 Jul 2018 17:17:24 -0700 Subject: Re: [2/5] C-SKY port: Backend implementation To: Jeff Law , "gcc-patches@gcc.gnu.org" CC: Xianmiao Qu , Yunhai Shang References: <49d0a2c8-51a0-4a74-d015-0bf1c1098e38@codesourcery.com> <28cb3a6e-4594-3545-5236-c68784af6a57@codesourcery.com> <8a1b9bac-82dc-bb4f-e0a2-9a9b9cbea98a@redhat.com> From: Sandra Loosemore Message-ID: <5ca2a106-d1d7-6eee-b0b8-2c5f2eb5e0a4@codesourcery.com> Date: Wed, 25 Jul 2018 00:17:00 -0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <8a1b9bac-82dc-bb4f-e0a2-9a9b9cbea98a@redhat.com> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit X-SW-Source: 2018-07/txt/msg01454.txt.bz2 On 07/24/2018 03:24 PM, Jeff Law wrote: >> >>> Any thoughts on using the newer function descriptor bits rather than old >>> style stack trampolines? >> >> Has that been committed?  I vaguely remembered discussion of a new way >> to handle nested functions without using the trampoline interface, but I >> couldn't find any documentation in the internals manual. > It did. See TARGET_CUSTOM_FUNCTION_DESCRIPTORS and the (relatively few) > ports that define it. Hmmm, I completely failed to make that connection from the docs -- the whole description of that hook is pretty gibberishy and I thought it was something for targets where the ABI already specifies some "standard calling sequence" using descriptors (C-SKY doesn't), rather than a generic alternative to executable trampolines. Putting on my doc maintainer hat briefly, I can see this needs a lot of work. :-( Anyway, is this required for new ports nowadays? If so, I at least know what to search for now. At this point I couldn't say whether this would do anything to fix the situation on ck801 targets where there simply aren't enough spare registers available to the trampoline to both hold the static link and do an indirect jump. -Sandra