CIRCT
20.0.0git
|
Base class for evaluator runtime values. More...
#include <Evaluator.h>
Public Types | |
enum class | Kind { Attr , Object , List , Tuple , Map , Reference , BasePath , Path } |
Public Member Functions | |
EvaluatorValue (MLIRContext *ctx, Kind kind, Location loc) | |
Kind | getKind () const |
MLIRContext * | getContext () const |
bool | isFullyEvaluated () const |
void | markFullyEvaluated () |
MLIRContext * | getContext () |
Return the associated MLIR context. More... | |
Type | getType () const |
LogicalResult | finalize () |
Location | getLoc () const |
void | setLoc (Location l) |
void | setLocIfUnknown (Location l) |
Private Attributes | |
const Kind | kind |
MLIRContext * | ctx |
Location | loc |
bool | fullyEvaluated = false |
bool | finalized = false |
Base class for evaluator runtime values.
Enables the shared_from_this functionality so Evaluator Value pointers can be passed through the CAPI and unwrapped back into C++ smart pointers with the appropriate reference count.
Definition at line 48 of file Evaluator.h.
|
strong |
Enumerator | |
---|---|
Attr | |
Object | |
List | |
Tuple | |
Map | |
Reference | |
BasePath | |
Path |
Definition at line 50 of file Evaluator.h.
|
inline |
Definition at line 51 of file Evaluator.h.
LogicalResult circt::om::evaluator::EvaluatorValue::finalize | ( | ) |
Definition at line 43 of file Evaluator.cpp.
References assert().
|
inline |
|
inline |
Definition at line 54 of file Evaluator.h.
References ctx.
Referenced by circt::om::evaluator::ObjectValue::getField().
|
inline |
Definition at line 53 of file Evaluator.h.
References kind.
Referenced by circt::om::evaluator::ReferenceValue::classof(), circt::om::evaluator::AttributeValue::classof(), circt::om::evaluator::ListValue::classof(), circt::om::evaluator::MapValue::classof(), circt::om::evaluator::ObjectValue::classof(), circt::om::evaluator::TupleValue::classof(), circt::om::evaluator::BasePathValue::classof(), and circt::om::evaluator::PathValue::classof().
|
inline |
Definition at line 73 of file Evaluator.h.
References loc.
Type circt::om::evaluator::EvaluatorValue::getType | ( | ) | const |
Definition at line 57 of file Evaluator.cpp.
References circt::calyx::direction::get().
|
inline |
Definition at line 57 of file Evaluator.h.
References fullyEvaluated.
|
inline |
Definition at line 58 of file Evaluator.h.
References assert(), and fullyEvaluated.
Referenced by circt::om::evaluator::AttributeValue::AttributeValue(), circt::om::evaluator::PathValue::getEmptyPath(), circt::om::evaluator::ListValue::ListValue(), circt::om::evaluator::MapValue::MapValue(), circt::om::evaluator::ObjectValue::ObjectValue(), circt::om::evaluator::MapValue::setElements(), circt::om::evaluator::ListValue::setElements(), circt::om::evaluator::TupleValue::setElements(), circt::om::evaluator::ObjectValue::setFields(), circt::om::evaluator::ReferenceValue::setValue(), and circt::om::evaluator::TupleValue::TupleValue().
|
inline |
Definition at line 75 of file Evaluator.h.
References loc.
|
inline |
Definition at line 77 of file Evaluator.h.
References loc.
|
private |
Definition at line 84 of file Evaluator.h.
Referenced by getContext().
|
private |
Definition at line 87 of file Evaluator.h.
|
private |
Definition at line 86 of file Evaluator.h.
Referenced by isFullyEvaluated(), and markFullyEvaluated().
|
private |
Definition at line 83 of file Evaluator.h.
Referenced by getKind().
|
private |
Definition at line 85 of file Evaluator.h.
Referenced by getLoc(), setLoc(), and setLocIfUnknown().