tvm
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes | List of all members
tvm::meta_schedule::RunnerFutureNode Class Reference

A class to asynchronously fetch runner's output. More...

#include <runner.h>

Inheritance diagram for tvm::meta_schedule::RunnerFutureNode:
Collaboration diagram for tvm::meta_schedule::RunnerFutureNode:

Public Types

using FDone = ffi::TypedFunction< bool()>
 The function type to check whether the runner has finished. More...
 
using FResult = ffi::TypedFunction< RunnerResult()>
 The function type to fetch runner output if it is ready. More...
 

Public Member Functions

bool Done () const
 Check whether the runner has finished. More...
 
RunnerResult Result () const
 Fetch the runner's output if it is ready. More...
 
 TVM_DECLARE_FINAL_OBJECT_INFO (RunnerFutureNode, runtime::Object)
 

Static Public Member Functions

static void RegisterReflection ()
 

Public Attributes

FDone f_done
 The packed function to check whether the runner has finished. More...
 
FResult f_result
 The packed function to fetch runner output if it is ready. More...
 

Static Public Attributes

static constexpr const char * _type_key = "meta_schedule.RunnerFuture"
 

Detailed Description

A class to asynchronously fetch runner's output.

Note
The API design is consistent with python's concurrent.futures.Future: https://docs.python.org/3/library/concurrent.futures.html#concurrent.futures.Future

Member Typedef Documentation

◆ FDone

using tvm::meta_schedule::RunnerFutureNode::FDone = ffi::TypedFunction<bool()>

The function type to check whether the runner has finished.

Returns
Whether the runner's output is ready.

◆ FResult

The function type to fetch runner output if it is ready.

Returns
The runner's output.

Member Function Documentation

◆ Done()

bool tvm::meta_schedule::RunnerFutureNode::Done ( ) const
inline

Check whether the runner has finished.

Returns
A boolean indicating whether the runner has finished.

◆ RegisterReflection()

static void tvm::meta_schedule::RunnerFutureNode::RegisterReflection ( )
inlinestatic

◆ Result()

RunnerResult tvm::meta_schedule::RunnerFutureNode::Result ( ) const
inline

Fetch the runner's output if it is ready.

Returns
The runner's output.

◆ TVM_DECLARE_FINAL_OBJECT_INFO()

tvm::meta_schedule::RunnerFutureNode::TVM_DECLARE_FINAL_OBJECT_INFO ( RunnerFutureNode  ,
runtime::Object   
)

Member Data Documentation

◆ _type_key

constexpr const char* tvm::meta_schedule::RunnerFutureNode::_type_key = "meta_schedule.RunnerFuture"
staticconstexpr

◆ f_done

FDone tvm::meta_schedule::RunnerFutureNode::f_done

The packed function to check whether the runner has finished.

◆ f_result

FResult tvm::meta_schedule::RunnerFutureNode::f_result

The packed function to fetch runner output if it is ready.


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