psyclone.domain.lfric.lfric_invoke#

This module implements the LFRic-specific implementation of the Invoke base class from psyGen.py.

Classes#

  • LFRicInvoke: The LFRic-specific Invoke class. This passes the LFRic-specific

class psyclone.domain.lfric.lfric_invoke.LFRicInvoke(alg_invocation, idx, invokes)[source]#

The LFRic-specific Invoke class. This passes the LFRic-specific InvokeSchedule class to the base class so it creates the one we require.

Parameters:
Raises:

GenerationError – if integer reductions are required in the PSy-layer.

Inheritance

Inheritance diagram of LFRicInvoke
arg_for_funcspace(fspace)[source]#

Returns an argument object which is on the requested function space. Searches through all Kernel calls in this Invoke. Currently the first argument object that is found is used. Throws an exception if no argument exists.

Parameters:

fspace (psyclone.domain.lfric.FunctionSpace) – function space of the argument.

Returns:

an argument object which is on the requested function space.

Return type:

psyclone.lfric.LFRicKernelArgument

Raises:

GenerationError – if the argument object does not exist.

field_on_space(func_space)[source]#

If a field exists on this space for any kernel in this Invoke then return that field. Otherwise return ‘None’.

Parameters:

func_space (psyclone.domain.lfric.FunctionSpace) – the function space for which to find an argument.

property operates_on_dofs_only#
Returns:

whether or not this Invoke consists only of kernels that operate on DoFs.

Return type:

bool

setup_psy_layer_symbols()[source]#

Declare, initialise and deallocate all symbols required by the PSy-layer Invoke subroutine.

unique_fss()[source]#
Returns:

the unique function space objects over all kernel calls in this Invoke.

Return type:

list of psyclone.domain.lfric.FunctionSpace