stfc / PSyclone

Domain-specific compiler and code transformation system for Finite Difference/Volume/Element Earth-system models in Fortran
BSD 3-Clause "New" or "Revised" License
107 stars 29 forks source link

[LFRic] [PSyAD] PSyAD processing fails when module and metadata names are different #2669

Closed DrTVockerodtMO closed 3 months ago

DrTVockerodtMO commented 3 months ago

If we have code in the file prefix_foo_kernel_mod.F90 with a module name prefix_foo_kernel_mod, but with metadata names foo_kernel_type, psyad raises an error

psyclone.psyir.transformations.transformation_error.TransformationError: Transformation Error: Error in RaisePSyIR2LFRicKernTrans transformation. The metadata name 'prefix_foo_kernel_type' provided to the transformation does not correspond to a symbol in the supplied PSyIR.

Some of the new LFRic code has kernel files which have a different module name to the kernel metadata. This can be alleviated with patches to the forward code, but nonetheless is not desired behaviour.

arporter commented 3 months ago

Thanks @DrTVockerodtMO, is this a duplicate of #2652?

DrTVockerodtMO commented 3 months ago

Yes it is, I will close this issue!