MLIR
20.0.0git
|
Statically known information for a particular Value. More...
#include "mlir/Dialect/Tosa/Utils/ShapeUtils.h"
Public Member Functions | |
ValueKnowledge ()=delete | |
ValueKnowledge (bool hasRank, llvm::ArrayRef< int64_t > newSizes, Type dtype) | |
operator bool () const | |
ShapedTypeComponents | getShapedTypeComponents () const |
Type | getType () const |
bool | operator== (const ValueKnowledge &rhs) const |
Static Public Member Functions | |
static ValueKnowledge | getKnowledgeFromType (Type type) |
static ValueKnowledge | getPessimisticValueState () |
static ValueKnowledge | join (const ValueKnowledge &lhs, const ValueKnowledge &rhs) |
static ValueKnowledge | meet (const ValueKnowledge &lhs, const ValueKnowledge &rhs) |
Public Attributes | |
bool | hasError |
bool | hasRank |
llvm::SmallVector< int64_t > | sizes |
Type | dtype |
Statically known information for a particular Value.
This struct currently tracks only information relevant for tensor/array-like shaped types. It is fine to associate a ValueKnowledge
with a non-shaped type as long as it is in the default "no knowledge" state returned by getPessimisticValueState
. The important invariant is that we cannot claim to know something about a value which is false.
This class could also be called "dataflow facts", "lattice value", etc.
Definition at line 33 of file ShapeUtils.h.
|
delete |
Referenced by getPessimisticValueState().
|
inline |
Definition at line 35 of file ShapeUtils.h.
References sizes.
|
inlinestatic |
Definition at line 45 of file ShapeUtils.h.
References dtype, getPessimisticValueState(), hasRank, and sizes.
|
inlinestatic |
Definition at line 61 of file ShapeUtils.h.
References ValueKnowledge().
Referenced by getKnowledgeFromType(), join(), and meet().
|
inline |
Definition at line 65 of file ShapeUtils.h.
|
inline |
Definition at line 69 of file ShapeUtils.h.
References dtype, mlir::get(), hasRank, and sizes.
|
inlinestatic |
Definition at line 81 of file ShapeUtils.h.
References dtype, getPessimisticValueState(), hasError, hasRank, and sizes.
|
inlinestatic |
Definition at line 136 of file ShapeUtils.h.
References dtype, getPessimisticValueState(), hasError, hasRank, and sizes.
|
inline |
Definition at line 42 of file ShapeUtils.h.
References hasError.
|
inline |
Definition at line 75 of file ShapeUtils.h.
Type mlir::tosa::ValueKnowledge::dtype |
Definition at line 178 of file ShapeUtils.h.
Referenced by getKnowledgeFromType(), getType(), join(), meet(), and operator==().
bool mlir::tosa::ValueKnowledge::hasError |
Definition at line 169 of file ShapeUtils.h.
Referenced by join(), meet(), and operator bool().
bool mlir::tosa::ValueKnowledge::hasRank |
Definition at line 171 of file ShapeUtils.h.
Referenced by getKnowledgeFromType(), getShapedTypeComponents(), getType(), join(), meet(), and operator==().
llvm::SmallVector<int64_t> mlir::tosa::ValueKnowledge::sizes |
Definition at line 174 of file ShapeUtils.h.
Referenced by getKnowledgeFromType(), getShapedTypeComponents(), getType(), join(), meet(), operator==(), and ValueKnowledge().