CompileOptions

class CompileOptions(verbose: typing.Optional[bool] = False, logfile: typing.Optional[_io.TextIOWrapper] = <_io.TextIOWrapper name='<stderr>' mode='w' encoding='utf-8'>, target: typing.Optional[str] = 'binary', keep_intermediate: typing.Optional[bool] = False, pipelines: typing.Optional[typing.List[typing.Any]] = None, autograph: typing.Optional[bool] = False, async_qnodes: typing.Optional[bool] = False, lower_to_llvm: typing.Optional[bool] = True, static_argnums: typing.Optional[typing.Union[int, typing.Iterable[int]]] = None, abstracted_axes: typing.Optional[typing.Union[typing.Iterable[typing.Iterable[str]], typing.Dict[int, str]]] = None)[source]

Bases: object

Generic compilation options, for which reasonable default values exist.

Parameters
  • verbose (Optional[bool]) – flag indicating whether to enable verbose output. Default is False

  • logfile (Optional[TextIOWrapper]) – the logfile to write output to. Default is sys.stderr

  • keep_intermediate (Optional[bool]) – flag indicating whether to keep intermediate results. Default is False

  • pipelines (Optional[List[Tuple[str,List[str]]]]) – A list of tuples. The first entry of the tuple corresponds to the name of a pipeline. The second entry of the tuple corresponds to a list of MLIR passes.

  • autograph (Optional[bool]) – flag indicating whether experimental autograph support is to be enabled.

  • async_qnodes (Optional[bool]) – flag indicating whether experimental asynchronous execution of QNodes support is to be enabled.

  • lower_to_llvm (Optional[bool]) – flag indicating whether to attempt the LLVM lowering after the main compilation pipeline is complete. Default is True.

  • static_argnums (Optional[Union[int, Iterable[int]]]) – indices of static arguments. Default is None.

  • abstracted_axes (Optional[Any]) – store the abstracted_axes value. Defaults to None.

abstracted_axes

async_qnodes

autograph

keep_intermediate

logfile

lower_to_llvm

pipelines

static_argnums

target

verbose

abstracted_axes: Optional[Union[Iterable[Iterable[str]], Dict[int, str]]] = None
async_qnodes: Optional[bool] = False
autograph: Optional[bool] = False
keep_intermediate: Optional[bool] = False
logfile: Optional[_io.TextIOWrapper] = <_io.TextIOWrapper name='<stderr>' mode='w' encoding='utf-8'>
lower_to_llvm: Optional[bool] = True
pipelines: Optional[List[Any]] = None
static_argnums: Optional[Union[int, Iterable[int]]] = None
target: Optional[str] = 'binary'
verbose: Optional[bool] = False

get_pipelines()

Get effective pipelines

get_pipelines() List[Tuple[str, List[str]]][source]

Get effective pipelines