From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from esa2.mentor.iphmx.com (esa2.mentor.iphmx.com [68.232.141.98]) by sourceware.org (Postfix) with ESMTPS id 5C93C3858D20; Thu, 26 Oct 2023 16:28:13 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 5C93C3858D20 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=mentor.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 5C93C3858D20 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=68.232.141.98 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1698337695; cv=none; b=M3kmGnH3/r+KIvo80cNp+1cgBUoMSkRJcod+Fx7Hi7XHlXePuAq/UdgTYZekfougIefV1d9tzbAQFTbtwNu5oEZgw3J9g8vI0wH8ddcKGvvlzRIhyGtzfWvYB44Ro7gYI7Ku0+SBBrRvVql/ZjszS884fwCyUQuVoqhFQRfQCJ4= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1698337695; c=relaxed/simple; bh=rA8A+ep3IGQ7qA5dzhJ5piYcXguEIT/skWYnPjyE9iE=; h=Message-ID:Date:MIME-Version:Subject:To:From; b=vFd4F+kPiRmkT0A+rs76kLN28SkgO8gkOIfbkQzj0/aYNvDFh6vgOOlV3dnN85xddUBKnTv5n3z3QqUY9Bg1nNIy9xzwKHbtduaEbnLzw9vMCR2LGKO5usHPih9IMEmYMSOu5P6/bLdSb2mMhJeDz4cLyt8QLISF5/5fhyYnagM= ARC-Authentication-Results: i=1; server2.sourceware.org X-CSE-ConnectionGUID: /0bLKRvOT3aqw/y+pjpKrg== X-CSE-MsgGUID: Wo1Y/HJeSyiVQYTgTqIitg== X-IronPort-AV: E=Sophos;i="6.03,253,1694764800"; d="scan'208";a="23415310" Received: from orw-gwy-02-in.mentorg.com ([192.94.38.167]) by esa2.mentor.iphmx.com with ESMTP; 26 Oct 2023 08:28:12 -0800 IronPort-SDR: poqj7S+ReSf3PcR9vO1DcCyMsSHzQK1t64ytbvRDY5JsSNtvpoIUtvRCa7wrCAGaG+tut5vBgh iGQPjF8V1VU/Poa4t8FKVbG22gcozQsJMFY0V1O62HFqiqQWUYK5tUz5iDR7YvisUw5hoUSxRI XI6XCYSqdL2oD+T+8yS3d959G1v8Y745ws77S8+fRjzXBrwinLTWDNzzvOMjHiPD7BWZRh/4gv 50JITZM2Vlc7H9nHWb/6M+HJMczXXZu590smy1G8GYkcyfQudskxvyAzg16xCfPh3imPHwXJt3 y7s= Message-ID: <2b01b415-e8db-4ea5-a2ca-cba66ed7d851@codesourcery.com> Date: Thu, 26 Oct 2023 18:28:07 +0200 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH] Fortran: Fix incompatible types between INTEGER(8) and TYPE(c_ptr) Content-Language: en-GB, fr To: Thomas Schwinge , Tobias Burnus CC: , gcc-patches References: <6fc6a877-2dc7-4551-b141-fd117c66ecfa@codesourcery.com> <78236b34-a5bd-4ccf-a197-94bee00b8a2b@codesourcery.com> <4cec8ab5-9300-4628-a945-24db1249edf4@codesourcery.com> <87il6t1hr3.fsf@euler.schwinge.homeip.net> From: Paul-Antoine Arras In-Reply-To: <87il6t1hr3.fsf@euler.schwinge.homeip.net> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [137.202.0.90] X-ClientProxiedBy: svr-ies-mbx-10.mgc.mentorg.com (139.181.222.10) To svr-ies-mbx-13.mgc.mentorg.com (139.181.222.13) X-Spam-Status: No, score=-12.1 required=5.0 tests=BAYES_00,GIT_PATCH_0,HEADER_FROM_DIFFERENT_DOMAINS,KAM_DMARC_STATUS,SPF_HELO_PASS,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: Hi Thomas, On 26/10/2023 18:16, you wrote: > Hi! > > On 2023-10-26T13:24:04+0200, Paul-Antoine Arras wrote: >> --- /dev/null >> +++ b/gcc/testsuite/gfortran.dg/c_ptr_tests_20.f90 >> @@ -0,0 +1,57 @@ >> +! { dg-do compile } >> +! { dg-additional-options "-fopenmp" } >> +[...] > >> --- /dev/null >> +++ b/gcc/testsuite/gfortran.dg/c_ptr_tests_21.f90 >> @@ -0,0 +1,57 @@ >> +! { dg-do compile } >> +! { dg-additional-options "-fopenmp" } >> +[...] > > OpenMP is not universally supported across different GCC configurations, > so this will FAIL for some. Therefore, please either guard with > effective target: > > @item fopenmp > Target supports OpenMP via @option{-fopenmp}. > Would the following be enough? > diff --git gcc/testsuite/gfortran.dg/c_ptr_tests_20.f90 gcc/testsuite/gfortran.dg/c_ptr_tests_20.f90 > index 7dd510400f3..131603d3819 100644 > --- gcc/testsuite/gfortran.dg/c_ptr_tests_20.f90 > +++ gcc/testsuite/gfortran.dg/c_ptr_tests_20.f90 > @@ -1,4 +1,5 @@ > ! { dg-do compile } > +! { dg-require-effective-target fopenmp } > ! { dg-additional-options "-fopenmp" } > ! > ! This failed to compile the declare variant directive due to the C_PTR > diff --git gcc/testsuite/gfortran.dg/c_ptr_tests_21.f90 gcc/testsuite/gfortran.dg/c_ptr_tests_21.f90 > index 05ccb771eee..060d29d0275 100644 > --- gcc/testsuite/gfortran.dg/c_ptr_tests_21.f90 > +++ gcc/testsuite/gfortran.dg/c_ptr_tests_21.f90 > @@ -1,4 +1,5 @@ > ! { dg-do compile } > +! { dg-require-effective-target fopenmp } > ! { dg-additional-options "-fopenmp" } > ! > ! Ensure that C_PTR and C_FUNPTR are reported as incompatible types in variant Thanks, -- PA