[PATCH v4 6/7] OpenMP: Fortran front-end support for dispatch + adjust_args

Paul-Antoine Arras parras@baylibre.com
Fri Dec 27 18:52:58 GMT 2024


Hi Tobias,

On 23/12/2024 21:04, Tobias Burnus wrote:
> Paul-Antoine Arras wrote:
>> Replying to your last two messages here and attaching revised patches.
> 
> Regarding the C++ and ME patches:
> 
>> ==> 0003-C-fix.patch <==
>> Subject: [PATCH 3/4] C++ fix
>>
>> ==> 0004-ME-fixes.patch <==
>> Subject: [PATCH 4/4] ME fixes
> 
> I think it is best to fold them into the Fortran patch; otherwise, they 
> would clearly need a better subject line.

Folded everything in one patch.

> And for both changes and in either case, both need a ChangeLog entry.

Updated ChangeLog.

> Additionally, the middle-end patch does not apply as it doesn't honor my 
> Dec 18 change to gimplify.cc.

Rebased and amended accordingly. I believe I did the right thing but 
please have a quick look to be sure.

> * * *
> 
>> ==> 0001-OpenMP-Fortran-front-end-support-for-dispatch-adjust.patch <==
>> Subject: [PATCH 1/4] OpenMP: Fortran front-end support for dispatch +
>> adjust_args
> 
> The following two patches do not work (at least with some testsuite 
> testing) as in gcc/testsuite/ neither omp_lib nor libgomp.{so,a} is 
> available.
> 
> For gcc/testsuite/gfortran.dg/gomp/adjust-args-10.f90, you can just 
> remove the 'omp_lib'.
> 
> And as gcc/testsuite/gfortran.dg/gomp/declare-variant-21.f90 contains ! 
> { dg-do run }
> 
> ... I'd suggest to move it to libgomp (including its aux-21.f90 file).

Fixed as suggested.

> For adjust-args-10.f90, I wonder whether it is sufficient as compile- 
> time only or whether it makes more sense to have a "dg-do run" to check 
> that type(C_ptr) value vs. not-value works. I think either is fine, but 
> if it stays in gcc/, can you manually run it once to re-check that it 
> works? (I think I did check it and it worked.)

Running adjust-args-10.f90 manually exhibited a bug that no other 
testcase triggered. So I fixed the bug; then moved adjust-args-10.f90 to 
the libgomp testsuite, renamed it to dispatch-3.f90 and made it dg-run.

> * * *
> 
> Note that gcc/testsuite/gfortran.dg/gomp/adjust-args-9.f90 
> and ...-10.f90 are missing a ChangeLog entry.
> 
> Likewise for dispatch-9a.f90.

Updated ChangeLog.

> BTW: If you have applied (committed) the patch locally, run ./contrib/ 
> gcc-changelog/git_check_commit.py -v -p — the '-v' will output new files 
> that have not been listed as warning and -p shows the patch log for 
> checking it. Additionally, it has the usual "git push" checks of GCC.

Thanks for the tip!

> * * *
> 
> Otherwise, LGTM. Thanks!
> 
> [As gimplify.cc couldn't be applied, I have not played with the patch 
> but I believe that it should be okay, based on past playing and looking 
> at the patch.]
> 
> Tobias
> 
> PS: Besides fixing the minor issues above, I think you have a follow-up/ 
> cleanup patch available addressing some issues related to the C/C++ FE, 
> including where the '#pragma' is handled etc. I am looking forward to 
> that follow-up patch as well :-)
> 

Yes, I'll post the follow-up patches soon.

Thanks,
-- 
PA
-------------- next part --------------
A non-text attachment was scrubbed...
Name: v4.6-0004-OpenMP-Fortran-front-end-support-for-dispatch-a.patch
Type: text/x-patch
Size: 90745 bytes
Desc: not available
URL: <https://gcc.gnu.org/pipermail/fortran/attachments/20241227/5da3d1e9/attachment-0001.bin>


More information about the Fortran mailing list