From patchwork Mon Apr 9 20:10:13 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Koenig X-Patchwork-Id: 896401 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-476082-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=netcologne.de Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="PrQuuqNu"; 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 40KhHv1XhXz9s02 for ; Tue, 10 Apr 2018 06:10:33 +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=surt/N8IyV3Rj0iXrviK+l2XGLsed74DmQUhI/95NjC9ppg6qH kDmyG6uTRHkDsqHgiywLiVaw31pJLvzEmYZthn/UWNF2EOwu3KfnUtGjk1MBgfWz mvomYhi7DZNLf1ipYyssLF3yBv3c2dGQRYIDFITLN7xrqLT40eNZXeXiM= 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=i2WzCVDfQaUCVMUy9UcAAWCqK7U=; b=PrQuuqNuAd6FD9HDYWLN +E1YON2nQAqBniF+rKzKAoOiMa0OCkKNk+3HjECLh6TOQCC+40y15Zrtyya/mBNw qFpqwiePLkuE1zUKw/G8U4EJfUtlZ6oJY7wCorA8TxZiQeF82MiHwNQAlyUTQJpU CJkrTKI4AJccbx9XQ/j1yBc= Received: (qmail 68432 invoked by alias); 9 Apr 2018 20:10:21 -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 68392 invoked by uid 89); 9 Apr 2018 20:10:20 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-11.0 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_ASCII_DIVIDERS, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 spammy=ceiling, mod, UD:netcologne.de X-Spam-User: qpsmtpd, 2 recipients X-HELO: cc-smtpout2.netcologne.de Received: from cc-smtpout2.netcologne.de (HELO cc-smtpout2.netcologne.de) (89.1.8.212) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 09 Apr 2018 20:10:17 +0000 Received: from cc-smtpin3.netcologne.de (cc-smtpin3.netcologne.de [89.1.8.203]) by cc-smtpout2.netcologne.de (Postfix) with ESMTP id 917EB127E2; Mon, 9 Apr 2018 22:10:15 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by cc-smtpin3.netcologne.de (Postfix) with ESMTP id 83F6311D94; Mon, 9 Apr 2018 22:10:15 +0200 (CEST) Received: from [78.35.153.70] (helo=cc-smtpin3.netcologne.de) by localhost with ESMTP (eXpurgate 4.1.9) (envelope-from ) id 5acbc8a7-02b7-7f0000012729-7f000001a17d-1 for ; Mon, 09 Apr 2018 22:10:15 +0200 Received: from [192.168.178.68] (xdsl-78-35-153-70.netcologne.de [78.35.153.70]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by cc-smtpin3.netcologne.de (Postfix) with ESMTPSA; Mon, 9 Apr 2018 22:10:14 +0200 (CEST) To: "fortran@gcc.gnu.org" , gcc-patches From: Thomas Koenig Subject: [patch, fortran] Remove parallell annotation from DO CONCURRENT Message-ID: Date: Mon, 9 Apr 2018 22:10:13 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 Hello world, the attached patch removes the parallel annotation from DO CONCURRENT. As discussed in the PR, the autoparallellizer currently generates wrong code. The only feasible way is to disable the annotation for gcc-8 and work on the wrong-code issues for gcc-9. This is an 8 regression. Regression-tested. OK for trunk? Regards Thomas 2018-04-09 Thomas Koenig PR fortran/83064 * trans-stmt.c (gfc_trans_forall_loop): Remove annotation for parallell processing of DO CONCURRENT. 2018-04-09 Thomas Koenig PR fortran/83064 * gfortran.dg/do_concurrent_5.f90: New test. * gfortran.dg/vect/vect-do-concurrent-1.f90: Xfail. Adjust dg-bogus message. Index: fortran/trans-stmt.c =================================================================== --- fortran/trans-stmt.c (Revision 259222) +++ fortran/trans-stmt.c (Arbeitskopie) @@ -3642,12 +3642,6 @@ gfc_trans_forall_loop (forall_info *forall_tmp, tr /* The exit condition. */ cond = fold_build2_loc (input_location, LE_EXPR, logical_type_node, count, build_int_cst (TREE_TYPE (count), 0)); - if (forall_tmp->do_concurrent) - cond = build3 (ANNOTATE_EXPR, TREE_TYPE (cond), cond, - build_int_cst (integer_type_node, - annot_expr_parallel_kind), - integer_zero_node); - tmp = build1_v (GOTO_EXPR, exit_label); tmp = fold_build3_loc (input_location, COND_EXPR, void_type_node, cond, tmp, build_empty_stmt (input_location)); Index: testsuite/gfortran.dg/vect/vect-do-concurrent-1.f90 =================================================================== --- testsuite/gfortran.dg/vect/vect-do-concurrent-1.f90 (Revision 259222) +++ testsuite/gfortran.dg/vect/vect-do-concurrent-1.f90 (Arbeitskopie) @@ -1,6 +1,8 @@ ! { dg-do compile } ! { dg-require-effective-target vect_float } ! { dg-additional-options "-O3 -fopt-info-vec-optimized" } +! { xfail *-*-* } +! PR 83064 - DO CONCURRENT is no longer vectorized for this case. subroutine test(n, a, b, c) integer, value :: n @@ -12,4 +14,4 @@ subroutine test(n, a, b, c) end subroutine test ! { dg-message "loop vectorized" "" { target *-*-* } 0 } -! { dg-bogus " version\[^\n\r]* alias" "" { target *-*-* } 0 } +! Restoration of the test case will need dg-bogus " version\[^\n\r]* alias" "" { target *-*-* } 0