|
Uni20
Asynchronous tensor and runtime library.
|
Records node information for DAG/debugging visualization. More...
#include <async_node.hpp>
Public Member Functions | |
| void const * | address () const |
| Returns the raw address of the current constructed value when observable. | |
| uint64_t | global_index () const |
| Returns the unique global index of this node. | |
| NodeInfo ()=delete | |
| Deleted default constructor. NodeInfo can only be constructed via create. | |
| void const * | storage_address () const |
| Returns the raw address of the shared storage control block. | |
| std::string_view | type () const |
| Returns a human-readable, demangled type name. | |
| bool | value_constructed () const noexcept |
| Reports whether the value is currently constructed when observable. | |
| NodeValueState | value_state () const noexcept |
| Reports the current construction state when observable. | |
| std::string_view | value_state_label () const noexcept |
| Returns a stable label for the current construction state. | |
| std::string | value_text () const |
| Returns type-specific display text for the current value. | |
Static Public Member Functions | |
| template<typename T > | |
| static NodeInfo const * | create (shared_storage< T > const &storage) |
| Factory method to create a NodeInfo for shared async storage. | |
| template<typename T > | |
| static NodeInfo const * | create (T const *value) |
| Returns the stacktrace of where the node was created. | |
Records node information for DAG/debugging visualization.
Each NodeInfo represents a single instance of an object participating in the dependency DAG (e.g., an Async<T>). It is assigned a unique global index at construction, and retains diagnostic addresses for the async storage and the constructed value when available.
NodeInfo objects are always heap-allocated and intentionally leaked for process-lifetime diagnostics. Each node is globally unique for the process lifetime.
|
delete |
|
inline |
Returns the raw address of the current constructed value when observable.
nullptr if the value is currently unconstructed.
|
inlinestatic |
Factory method to create a NodeInfo for shared async storage.
| T | The async storage value type. |
| storage | Storage handle represented by this node. |
|
inlinestatic |
Returns the stacktrace of where the node was created.
Factory method to create a NodeInfo for an object pointer.
| T | The type of the object. |
| value | Pointer to the value for which a NodeInfo should be created. |
|
inline |
Returns the unique global index of this node.
|
inline |
Returns the raw address of the shared storage control block.
nullptr when the node was not storage-backed.
|
inline |
Returns a human-readable, demangled type name.
The string is obtained from an interned map keyed by the mangled type name. The returned string_view is valid for the process lifetime.
|
inlinenoexcept |
Reports whether the value is currently constructed when observable.
true when address is non-null.
|
inlinenoexcept |
Reports the current construction state when observable.
|
inlinenoexcept |
Returns a stable label for the current construction state.
|
inline |
Returns type-specific display text for the current value.
shape=(...), when available.