24 #ifndef TVM_RELAY_FEATURE_H_ 25 #define TVM_RELAY_FEATURE_H_ 100 template <
typename T>
106 template <
typename T>
112 template <
typename T>
133 std::bitset<feature_count> bs_;
135 explicit FeatureSet(
const std::bitset<feature_count>& bs) : bs_(bs) {}
199 #endif // TVM_RELAY_FEATURE_H_
FeatureSet operator+(const T &rhs) const
Set union.
Definition: feature.h:101
A finite set of Feature.
Definition: feature.h:64
IRModule that holds the functions and type definitions.
Relay expression language.
runtime implementation for LibTorch/TorchScript.
Definition: analyzer.h:36
Whether there is local fixpoint in the program.
Definition: feature.h:56
constexpr size_t feature_count
Definition: feature.h:59
static FeatureSet No()
The empty set. Contain no Feature.
Definition: feature.h:90
FeatureSet & operator-=(const T &rhs)
Definition: feature.h:107
bool is_subset_of(const FeatureSet &rhs) const
Is this a subset of rhs?
Definition: feature.h:125
void push_back(const T &item)
push a new item to the back of the list
Definition: array.h:457
FeatureSet(const tvm::Array< tvm::Integer > &ft)
Definition: feature.h:69
FeatureSet operator-(const T &rhs) const
Set difference.
Definition: feature.h:113
void CheckFeature(const RelayExpr &expr, const FeatureSet &fs)
Check the feature of the program.
Array, container representing a contiguous sequence of ObjectRefs.
Definition: array.h:289
FeatureSet DetectFeature(const RelayExpr &expr)
Calculate the feature of the program.
Managed reference to RelayExprNode.
Definition: expr.h:433
static FeatureSet All()
A set that contain all the Feature.
Definition: feature.h:84
Managed reference class to IRModuleNode.
Definition: module.h:348
Whether any non-atom fragment of the program is shared, making the program a graph.
Definition: feature.h:54
std::string ToString() const
return a string representation.
FeatureSet & operator+=(const T &rhs)
Definition: feature.h:95
PrimExpr ret(PrimExpr value, Span span=Span())
Return the value.
Feature
Different kinds of relay feature a program might use.
Definition: feature.h:37
tvm::PrimExpr mod(const tvm::PrimExpr &a, const tvm::PrimExpr &b)
Definition: broadcast.h:290
FeatureSet(Feature ft)
A singleton set containing a single Feature.
Definition: feature.h:68
Container of constant int that adds more constructors.
Definition: expr.h:622