From patchwork Wed Sep 5 11:51:20 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andrew Stubbs X-Patchwork-Id: 966344 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-485180-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="AXdIkCAp"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4252Cv2yM6z9s5c for ; Wed, 5 Sep 2018 21:53:47 +1000 (AEST) 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; q=dns; s=default; b=x2EzaZVOprDYSwSdkkoaNJTwlPMV8 iAz27+FVFM607ujUQ5nLt5yCnGyA5x1Svcl+j3WFZy+AkE0legfrG6VhhPTJXnN2 lntcwber68hbh+kCIji8R1o7lR+kiUQ6m3Dvg+q5DeC+Hh+QPc9kbE3A3liURmb8 GVG8+uttGJ1Wz0= 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; s=default; bh=JBz9LOh2BZjT7csMF+pIuAvV2YQ=; b=AXd IkCApbiyerJX/eHH3wUaJsfc1yOKyErKPgc4Cfcvgv76vNczmBRNt6rPGGgR75aB HZVsyljN7XurOZDUyEHBPc08TlL9zsTB/Rml7WeWiEhBqQlXY8bzrcWZRaqdsUkL hTE16J03yCWA4M2hkiQZ2vDwUFUBrWYvuPxgvcxI= Received: (qmail 99212 invoked by alias); 5 Sep 2018 11:52:08 -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 99100 invoked by uid 89); 5 Sep 2018 11:52:07 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-24.8 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_0, GIT_PATCH_1, GIT_PATCH_2, GIT_PATCH_3 autolearn=ham version=3.3.2 spammy= X-HELO: eggs.gnu.org Received: from eggs.gnu.org (HELO eggs.gnu.org) (208.118.235.92) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Wed, 05 Sep 2018 11:52:00 +0000 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fxWLk-0006mh-8T for gcc-patches@gcc.gnu.org; Wed, 05 Sep 2018 07:51:59 -0400 Received: from relay1.mentorg.com ([192.94.38.131]:45578) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1fxWLk-0006F0-0A for gcc-patches@gcc.gnu.org; Wed, 05 Sep 2018 07:51:56 -0400 Received: from nat-ies.mentorg.com ([192.94.31.2] helo=svr-ies-mbx-01.mgc.mentorg.com) by relay1.mentorg.com with esmtps (TLSv1.2:ECDHE-RSA-AES256-SHA384:256) id 1fxWLY-0005se-1a from Andrew_Stubbs@mentor.com for gcc-patches@gcc.gnu.org; Wed, 05 Sep 2018 04:51:44 -0700 Received: from build6-trusty-cs.sje.mentorg.com (137.202.0.90) by svr-ies-mbx-01.mgc.mentorg.com (139.181.222.1) with Microsoft SMTP Server (TLS) id 15.0.1320.4; Wed, 5 Sep 2018 12:51:40 +0100 From: To: Subject: [PATCH 19/25] GCN libgfortran. Date: Wed, 5 Sep 2018 12:51:20 +0100 Message-ID: In-Reply-To: References: MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Windows NT kernel [generic] [fuzzy] X-Received-From: 192.94.38.131 This patch contains the GCN port of libgfortran. We use the minimal configuration created for NVPTX. That's all that's required, besides the target-independent bug fixes posted already. 2018-09-05 Andrew Stubbs Kwok Cheung Yeung Julian Brown Tom de Vries libgfortran/ * configure.ac: Use minimal mode for amdgcn. * configure: Regenerate. --- libgfortran/configure | 7 ++++--- libgfortran/configure.ac | 3 ++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/libgfortran/configure b/libgfortran/configure index a583b67..fd8b697 100755 --- a/libgfortran/configure +++ b/libgfortran/configure @@ -5994,7 +5994,8 @@ fi # * C library support for other features such as signal, environment # variables, time functions - if test "x${target_cpu}" = xnvptx; then + if test "x${target_cpu}" = xnvptx \ + || test "x${target_cpu}" = xamdgcn; then LIBGFOR_MINIMAL_TRUE= LIBGFOR_MINIMAL_FALSE='#' else @@ -12514,7 +12515,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 12517 "configure" +#line 12518 "configure" #include "confdefs.h" #if HAVE_DLFCN_H @@ -12620,7 +12621,7 @@ else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext <<_LT_EOF -#line 12623 "configure" +#line 12624 "configure" #include "confdefs.h" #if HAVE_DLFCN_H diff --git a/libgfortran/configure.ac b/libgfortran/configure.ac index 05952aa..11b629d 100644 --- a/libgfortran/configure.ac +++ b/libgfortran/configure.ac @@ -206,7 +206,8 @@ AM_CONDITIONAL(LIBGFOR_USE_SYMVER_SUN, [test "x$gfortran_use_symver" = xsun]) # * C library support for other features such as signal, environment # variables, time functions -AM_CONDITIONAL(LIBGFOR_MINIMAL, [test "x${target_cpu}" = xnvptx]) +AM_CONDITIONAL(LIBGFOR_MINIMAL, [test "x${target_cpu}" = xnvptx \ + || test "x${target_cpu}" = xamdgcn]) # Figure out whether the compiler supports "-ffunction-sections -fdata-sections", # similarly to how libstdc++ does it