Open hiker opened 3 weeks ago
That all sounds OK to me. I was thinking about suggesting we bite the bullet and bring in the infrastructure wholesale (with permission from the Met Office) but that might just complicate things further?
Yes, the license issue might be the biggest problem. @TeranIvy , any idea if we can add the infrastructure folder (I believe this is all we need, likely even only a subset, since it also contains build tools)? We try to be on current LFRic, so I kind of need to fix the psydata stuff (for kernel extraction). Easy enough to do it with a search&replace, but then I have these changes in my tree, which is annoying :)
The license is not a problem, and the Met Office doesn't have a problem. I have approval for LFRic to go public, so taking a mirror now should be fine. Hoping to do a port to a public GitHub repo in 2025 - possibly with a mirror copy earlier than that.
Great, then I can have a look! Thanks a lot!
One thing we need to be careful of is not to shoot ourselves in the foot when it comes to our ability to test with other compilers, especially nvidia.
Besides the name change (and I can't see this being a problem with any compiler ;) ), the templaterator is a pre-processing step, i.e. nothing is different from what PSyclone of fparser will see.
Are you thinking of any specific issues?
I thought you were talking about bringing in the whole infrastructure. If you're not then it's all fine :-)
I don't think we should include the whole lfric_core directory (though I kind of said it this way). There is a lot of unnecessary stuff in there (applications, mesh tools, rose_stem components, unit-tests) - Seems to be around 100 MB, only 2.2 MB with actual source files that we would need for compiling lfric (well, plus whatever we need to actually compile this, but I will likely just use a standard Makefile and some jinja?? Well, I'll check).
At around r50490 lfric replaced the existing
field_{r32,r64}_mod
andinteger_field
with a template, and the build system includes a templaterator. As a result, the name of these files has changed. This does not really affect much of PSyclone, it relies onfield_mod.F90
:But a lot of psydata libraries use the original name (to be able to work with 32- and 64-bit fields), they need to be changed. And all PSycl, seeone tests, examples, and tutorials(?) need to be changed.
If/when we agree to go ahead with this, we should move the infrastructure files to externals (so that in the future when lfric_core is on git, we can use a submodule), and also take care of pre-processing (in case of case-insensitive file systems), see #2239.
The templaterator itself seems to be a small-ish python script using jinja2, so we might be able to use our own script to create the source files from the template, without having to add the templaterator(?)