IRON 1.0
Loading...
Searching...
No Matches
Public Member Functions | Protected Attributes | List of all members
iron.kernel.BaseKernel Class Reference
Inheritance diagram for iron.kernel.BaseKernel:
Inheritance graph
[legend]
Collaboration diagram for iron.kernel.BaseKernel:
Collaboration graph
[legend]

Public Member Functions

 __init__ (self, str name, list[type[np.ndarray]|np.dtype] arg_types=[])
 
None resolve (self, ir.Location|None loc=None, ir.InsertionPoint|None ip=None)
 
 __call__ (self, *args, **kwargs)
 

Protected Attributes

 _name
 
 _arg_types
 
 _op
 

Detailed Description

Base class for kernel-like objects that resolve to FuncOp.

Constructor & Destructor Documentation

◆ __init__()

iron.kernel.BaseKernel.__init__ (   self,
str  name,
list[type[np.ndarray] | np.dtype]   arg_types = [] 
)
Initialize base kernel.

Args:
    name (str): The name of the function
    arg_types (list[type[np.ndarray] | np.dtype], optional): The type signature of the function. Defaults to [].

Reimplemented in iron.kernel.Kernel, and iron.kernel.ExternalFunction.

Member Function Documentation

◆ __call__()

iron.kernel.BaseKernel.__call__ (   self,
args,
**  kwargs 
)
Call the kernel with the given arguments.

Reimplemented in iron.kernel.ExternalFunction.

◆ resolve()

None iron.kernel.BaseKernel.resolve (   self,
ir.Location | None   loc = None,
ir.InsertionPoint | None   ip = None 
)
Resolve the kernel to a FuncOp. Must be implemented by subclasses.

Reimplemented from iron.resolvable.Resolvable.

Reimplemented in iron.kernel.Kernel, and iron.kernel.ExternalFunction.

Member Data Documentation

◆ _arg_types

iron.kernel.BaseKernel._arg_types
protected

◆ _name

iron.kernel.BaseKernel._name
protected

◆ _op

iron.kernel.BaseKernel._op
protected

The documentation for this class was generated from the following file: