From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 27522 invoked by alias); 7 Mar 2014 10:44:37 -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 27504 invoked by uid 89); 7 Mar 2014 10:44:36 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00,SPF_HELO_PASS,T_RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-Spam-User: qpsmtpd, 2 recipients X-HELO: mailout2.w1.samsung.com Received: from mailout2.w1.samsung.com (HELO mailout2.w1.samsung.com) (210.118.77.12) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (DES-CBC3-SHA encrypted) ESMTPS; Fri, 07 Mar 2014 10:44:35 +0000 Received: from eucpsbgm1.samsung.com (unknown [203.254.199.244]) by mailout2.w1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N220080JB61PR80@mailout2.w1.samsung.com>; Fri, 07 Mar 2014 10:44:25 +0000 (GMT) Received: from eusync4.samsung.com ( [203.254.199.214]) by eucpsbgm1.samsung.com (EUCPMTA) with SMTP id E6.22.23059.E03A9135; Fri, 07 Mar 2014 10:44:31 +0000 (GMT) Received: from [106.109.130.115] by eusync4.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0N220091PB666410@eusync4.samsung.com>; Fri, 07 Mar 2014 10:44:30 +0000 (GMT) Message-id: <5319A309.40004@samsung.com> Date: Fri, 07 Mar 2014 10:44:00 -0000 From: Ilmir Usmanov User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.0 MIME-version: 1.0 To: Tobias Burnus Cc: Thomas Schwinge , Evgeny Gavrin , GarbuzovViacheslav , Dmitri Botcharnikov , gcc-patches@gcc.gnu.org, jakub@redhat.com, fortran@gcc.gnu.org Subject: Re: [PATCH 1/4] [GOMP4] [Fortran] OpenACC 1.0+ support in fortran front-end References: <52E158EF.9050009@samsung.com> <877g9pqmt2.fsf@schwinge.name> <52E65B24.9070403@samsung.com> <87iot5pgqb.fsf@schwinge.name> <52EB8437.3060602@samsung.com> <52EB84C3.4010407@samsung.com> <52F7FFAA.9020702@net-b.de> <5304CEFC.4000602@samsung.com> <53054370.2030802@net-b.de> <5305BA82.5060804@samsung.com> <53158715.1090908@samsung.com> <5315873E.4010203@samsung.com> <53160B41.3060501@net-b.de> In-reply-to: <53160B41.3060501@net-b.de> Content-type: text/plain; charset=ISO-8859-1; format=flowed Content-transfer-encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2014-03/txt/msg00316.txt.bz2 Hi Tobias! Thanks a lot for your review! > !$acc loop > outer_loop: do i = 1, n > inner_loop: do j = 1,m > ! ... > cycle outer_loop > exit outer_loop > end do inner_loop > end do outer_loop > > That's a new Fortran 2008 feature that CYCLE and EXIT can leave the > inner DO loop. > I added the following to test suite: > !$acc loop > outer_loop: do i = 1, 5 > inner_loop: do j = 1,5 > if (i .eq. j) cycle outer_loop > if (i .ne. j) exit outer_loop ! { dg-error "EXIT statement" } > end do inner_loop > end do outer_loop > > outer_loop1: do i = 1, 5 > !$acc loop > inner_loop1: do j = 1,5 > if (i .eq. j) cycle outer_loop1 ! { dg-error "CYCLE statement" } > end do inner_loop1 > end do outer_loop1 > > !$acc loop collapse(2) > outer_loop2: do i = 1, 5 > inner_loop2: do j = 1,5 > if (i .eq. j) cycle outer_loop2 ! { dg-error "CYCLE statement" } > if (i .ne. j) exit outer_loop2 ! { dg-error "EXIT statement" } > end do inner_loop2 > end do outer_loop2 All cases pass. The second one passes due to check of structured blocks: > if (o != NULL) > { > gfc_error ("%s statement at %C leaving OpenMP structured block", > gfc_ascii_statement (st)); > return MATCH_ERROR; > } So, I needed to change error message. Also I fixed checks of polymofphic type and indentation. OK for gomp4 branch? -- Ilmir.