From patchwork Sun Sep 23 20:22:37 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Thomas_K=C3=B6nig?= X-Patchwork-Id: 973754 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-486210-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=tkoenig.net Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="B9uBHKq0"; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=tkoenig.net header.i=@tkoenig.net header.b="S+6Gz4+F"; 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 42JJg36grZz9sB4 for ; Mon, 24 Sep 2018 06:22:53 +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:to :from:subject:message-id:date:mime-version:content-type; q=dns; s=default; b=kfQQ14XkfhEhI45Dyk8diAScz8RBKsJvXxLBzZzDzKMEDEhe0R vcdONcbXgGZy0vc+VCITM8R0lzfHR6NLFw2FuzyyjIkWbSHBF6EgMuWbS8lpwUKs ASyp4U90LccFfHqK7/YCzjzcLgEG/OBXrFQIlfKJsOKJq0DPfxVimYLNw= 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:to :from:subject:message-id:date:mime-version:content-type; s= default; bh=bezrsJSNoJ1EQDYpkSUfU0cIfBs=; b=B9uBHKq0eky+es1wrcUF TlZTMJUwJI/ZirwqQTEP9R366lYiQw3jC2OJPubQwXwHp8dheqke3/SIgpR8rbqV FcobUNJaVLyT5So1pk6VennJIAphOSiAqPfykcgFHvUkAcf7dZDbMhEMKZ4g0aQ+ oZgdilu0x9sCfPSPuhxHTCg= Received: (qmail 81360 invoked by alias); 23 Sep 2018 20:22:44 -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 81336 invoked by uid 89); 23 Sep 2018 20:22:43 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-8.9 required=5.0 tests=AWL, BAYES_40, GIT_PATCH_2, GIT_PATCH_3, KAM_ASCII_DIVIDERS, RCVD_IN_DNSWL_NONE, SPF_HELO_PASS autolearn=ham version=3.3.2 spammy=profits, LIMITED, BUSINESS, SPECIAL X-HELO: mo4-p00-ob.smtp.rzone.de Received: from mo4-p00-ob.smtp.rzone.de (HELO mo4-p00-ob.smtp.rzone.de) (85.215.255.25) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Sun, 23 Sep 2018 20:22:40 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1537734157; s=strato-dkim-0002; d=tkoenig.net; h=Date:Message-ID:Subject:From:To:X-RZG-CLASS-ID:X-RZG-AUTH:From: Subject:Sender; bh=Ji39FpxqOw7NmBbzWTg4BSfEXNgTcqBy5PZFlXEoV30=; b=S+6Gz4+FmJpM8fivu/HX4mmyRIRhe+qNz/DdC+rtVvGFnza0B5njge92+Kw7Mn0iL0 lN5NjUbuuPFXKpVsrShTxMTtk9om4QMhmF/g8w7aNeVRXJX1xJG5v2wggzHXL0Idoks8 /fvJrUNn2cIVHAiYG4JIxGqCFQe9m4LryxuWwTH5UeuRfVv2Opts4wBndHvitOssdLPP hMmTuJ0y07tbTlC3LK8djv+tHnwJws9kjMeAQfT+5ryx2EgycfbU0FlvMbL/yrVJc9rI SGGHg2Sjc4ZXJGxnKt8OFw0w5wKQ59mH5EAs0itfN0yfF8N4rtRnYMRrJFDE90NwFR5x GWFA== Received: from [192.168.178.68] by smtp.strato.de (RZmta 44.1 DYNA|AUTH) with ESMTPSA id i05aecu8NKMbco1 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve secp521r1 with 521 ECDH bits, eq. 15360 bits RSA)) (Client did not present a certificate); Sun, 23 Sep 2018 22:22:37 +0200 (CEST) To: "fortran@gcc.gnu.org" , gcc-patches From: =?utf-8?q?Thomas_K=C3=B6nig?= Subject: [patch, fortran, committed] Another fallout from clobbering INTENT(OUT) variables Message-ID: <8ea01645-0314-1caf-3143-209c76bdd103@tkoenig.net> Date: Sun, 23 Sep 2018 22:22:37 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 Hello world, committed as obvious after regression-testing. Instead of spending a lot of work trying to reducing the test case, I used all of it (retainging the copyright notice). Regards Thomas 2018-09-23 Thomas Koenig PR fortran/87397 * gfc_conv_procedure_call: Do not add clobber on INTENT(OUT) for variables having the dimension attribute. 2018-09-23 Thomas Koenig PR fortran/87397 * gfortran.dg/intent_out_11.f90: New test. Index: trans-expr.c =================================================================== --- trans-expr.c (Revision 264512) +++ trans-expr.c (Arbeitskopie) @@ -5280,6 +5280,7 @@ gfc_conv_procedure_call (gfc_se * se, gfc_symbol * bool add_clobber; add_clobber = fsym && fsym->attr.intent == INTENT_OUT && !fsym->attr.allocatable && !fsym->attr.pointer + && !e->symtree->n.sym->attr.dimension && !e->symtree->n.sym->attr.pointer /* See PR 41453. */ && !e->symtree->n.sym->attr.dummy