Reference Guide
2.5.0
|
Public Member Functions | |
def | __init__ (self, invoke_info) |
def | container (self) |
def | __str__ (self) |
def | invokes (self) |
def | name (self) |
def | gen (self) |
Base class to help manage and generate PSy code for a single algorithm file. Takes the invocation information output from the function :func:`parse.algorithm.parse` as its input and stores this in a way suitable for optimisation and code generation. :param FileInfo invoke_info: An object containing the required \ invocation information for code \ optimisation and generation. Produced \ by the function :func:`parse.algorithm.parse`. :type invoke_info: :py:class:`psyclone.parse.algorithm.FileInfo` For example: >>> from psyclone.parse.algorithm import parse >>> ast, info = parse("argspec.F90") >>> from psyclone.psyGen import PSyFactory >>> api = "..." >>> psy = PSyFactory(api).create(info) >>> print(psy.gen)
def psyclone.psyGen.PSy.container | ( | self | ) |
:returns: the container associated with this PSy object :rtype: :py:class:`psyclone.psyir.nodes.Container`
Definition at line 248 of file psyGen.py.
References psyclone.nemo.NemoPSy._container, and psyclone.psyGen.PSy._container.
def psyclone.psyGen.PSy.gen | ( | self | ) |
Abstract base class for code generation function. :returns: root node of generated Fortran AST. :rtype: :py:class:`psyclone.psyir.nodes.Node`
Reimplemented in psyclone.nemo.NemoPSy, psyclone.gocean1p0.GOPSy, and psyclone.dynamo0p3.DynamoPSy.
def psyclone.psyGen.PSy.invokes | ( | self | ) |
:returns: the list of invokes. :rtype: :py:class:`psyclone.psyGen.Invokes` or derived class
Definition at line 259 of file psyGen.py.
References psyclone.dynamo0p3.DynamoPSy._invokes, psyclone.gocean1p0.GOPSy._invokes, psyclone.nemo.NemoInvoke._invokes, psyclone.nemo.NemoPSy._invokes, psyclone.psyGen.PSy._invokes, and psyclone.psyGen.Invoke._invokes.
def psyclone.psyGen.PSy.name | ( | self | ) |
:returns: the name of the PSy object. :rtype: str
Reimplemented in psyclone.dynamo0p3.DynamoPSy.
Definition at line 266 of file psyGen.py.
References psyclone.domain.common.algorithm.psyir.AlgorithmInvokeCall._name, psyclone.domain.gocean.kernel.psyir.GOceanKernelMetadata._name, psyclone.domain.gocean.kernel.psyir.GOceanKernelMetadata.GridArg._name, psyclone.domain.lfric.kernel.lfric_kernel_metadata.LFRicKernelMetadata._name, psyclone.dynamo0p3.DynFuncDescriptor03._name, psyclone.expression.NamedArg._name, psyclone.gocean1p0.GOKernelGridArgument._name, psyclone.gocean1p0.GOStencil._name, psyclone.nemo.NemoInvoke._name, psyclone.nemo.NemoPSy._name, psyclone.parse.algorithm.FileInfo._name, psyclone.parse.algorithm.InvokeCall._name, psyclone.parse.kernel.KernelProcedure._name, psyclone.parse.kernel.KernelType._name, psyclone.parse.module_info.ModuleInfo._name, psyclone.psyGen.PSy._name, psyclone.psyGen.Invoke._name, psyclone.psyGen.Kern._name, psyclone.psyGen.Argument._name, psyclone.psyir.nodes.container.Container._name, psyclone.psyir.nodes.routine.Routine._name, and psyclone.psyir.symbols.symbol.Symbol._name.