Uni20
Asynchronous tensor and runtime library.
Loading...
Searching...
No Matches
task_registry_snapshot.hpp
Go to the documentation of this file.
1#pragma once
2
8#include <cstddef>
9#include <cstdint>
10#include <string>
11#include <vector>
12
13namespace uni20
14{
15
18{
19 Reader,
20 Writer,
21};
22
25{
26 std::string location{};
27 std::string function{};
28 std::string stacktrace{};
29};
30
33{
34 std::size_t max_frames{32};
36};
37
40{
41 std::uint64_t id{0};
42 std::string label{};
43 std::string type{};
44 std::string storage_address{};
45 std::string address{};
46 std::string state{};
47 std::string value{};
49};
50
58
61{
62 std::size_t id{0};
63 std::string address{};
64 std::string label{};
65 std::string state{};
66 std::size_t transition_count{0};
67 std::string creation_timestamp{};
69 std::string waiting_on{};
74 std::vector<std::uint64_t> read_dependencies{};
75 std::vector<std::uint64_t> write_dependencies{};
76 std::vector<TaskRegistryGraphAwaitDependency> await_dependencies{};
77 std::string failure{};
78};
79
82{
83 std::size_t id{0};
84 std::string address{};
86 std::string creation_timestamp{};
87 int generation{0};
88 std::string phase{};
89 bool has_next_epoch{false};
90 std::size_t next_epoch_id{0};
91 bool has_node{false};
92 std::uint64_t node_id{0};
96 bool writer_active{false};
98 std::vector<std::size_t> reader_task_ids{};
99 std::vector<std::size_t> writer_task_ids{};
100};
101
104{
106 std::string unavailable_reason{};
107 std::vector<TaskRegistryGraphDataNode> data_nodes{};
108 std::vector<TaskRegistryGraphEpoch> epochs{};
109 std::vector<TaskRegistryGraphTask> tasks{};
110};
111
114{
115 std::vector<std::string> notes{};
116 std::vector<std::size_t> blocked_read_task_ids{};
117 std::vector<std::size_t> blocked_write_task_ids{};
118 std::vector<std::size_t> cycle_task_ids{};
119 std::vector<std::uint64_t> cycle_node_ids{};
120 std::vector<std::uint64_t> missing_writer_node_ids{};
121 std::vector<std::size_t> missing_writer_epoch_ids{};
122 std::vector<std::size_t> failed_task_ids{};
123};
124
125} // namespace uni20
Definition async/async.hpp:26
TaskRegistryGraphRole
Reader/writer role for a task-registry graph dependency.
Definition task_registry_snapshot.hpp:18
Concrete awaited dependency captured for a task.
Definition task_registry_snapshot.hpp:53
std::uint64_t node_id
Definition task_registry_snapshot.hpp:54
TaskRegistryGraphRole role
Definition task_registry_snapshot.hpp:55
TaskRegistryGraphProvenance await_site
Definition task_registry_snapshot.hpp:56
Async value node captured in a task-registry graph snapshot.
Definition task_registry_snapshot.hpp:40
std::string state
Definition task_registry_snapshot.hpp:46
std::string label
Definition task_registry_snapshot.hpp:42
std::string value
Definition task_registry_snapshot.hpp:47
bool value_constructed
Definition task_registry_snapshot.hpp:48
std::string type
Definition task_registry_snapshot.hpp:43
std::string address
Definition task_registry_snapshot.hpp:45
std::string storage_address
Definition task_registry_snapshot.hpp:44
Diagnostics derived from a structured task-registry graph snapshot.
Definition task_registry_snapshot.hpp:114
std::vector< std::size_t > cycle_task_ids
Definition task_registry_snapshot.hpp:118
std::vector< std::uint64_t > cycle_node_ids
Definition task_registry_snapshot.hpp:119
std::vector< std::size_t > blocked_write_task_ids
Definition task_registry_snapshot.hpp:117
std::vector< std::size_t > missing_writer_epoch_ids
Definition task_registry_snapshot.hpp:121
std::vector< std::size_t > blocked_read_task_ids
Definition task_registry_snapshot.hpp:116
std::vector< std::string > notes
Definition task_registry_snapshot.hpp:115
std::vector< std::uint64_t > missing_writer_node_ids
Definition task_registry_snapshot.hpp:120
std::vector< std::size_t > failed_task_ids
Definition task_registry_snapshot.hpp:122
Epoch context captured in a task-registry graph snapshot.
Definition task_registry_snapshot.hpp:82
int generation
Definition task_registry_snapshot.hpp:87
std::vector< std::size_t > writer_task_ids
Definition task_registry_snapshot.hpp:99
int total_writers
Definition task_registry_snapshot.hpp:93
std::size_t next_epoch_id
Definition task_registry_snapshot.hpp:90
std::string phase
Definition task_registry_snapshot.hpp:88
bool has_node
Definition task_registry_snapshot.hpp:91
bool snapshot_available
Definition task_registry_snapshot.hpp:85
int num_writers
Definition task_registry_snapshot.hpp:94
bool writer_active
Definition task_registry_snapshot.hpp:96
TaskRegistryGraphProvenance creation_site
Definition task_registry_snapshot.hpp:97
bool has_next_epoch
Definition task_registry_snapshot.hpp:89
std::vector< std::size_t > reader_task_ids
Definition task_registry_snapshot.hpp:98
std::string address
Definition task_registry_snapshot.hpp:84
std::string creation_timestamp
Definition task_registry_snapshot.hpp:86
int num_readers
Definition task_registry_snapshot.hpp:95
std::uint64_t node_id
Definition task_registry_snapshot.hpp:92
Optional source provenance attached to a task, epoch, or dependency edge.
Definition task_registry_snapshot.hpp:25
std::string location
Definition task_registry_snapshot.hpp:26
std::string stacktrace
Definition task_registry_snapshot.hpp:28
std::string function
Definition task_registry_snapshot.hpp:27
Structured task-registry graph snapshot.
Definition task_registry_snapshot.hpp:104
std::vector< TaskRegistryGraphEpoch > epochs
Definition task_registry_snapshot.hpp:108
std::string unavailable_reason
Definition task_registry_snapshot.hpp:106
std::vector< TaskRegistryGraphDataNode > data_nodes
Definition task_registry_snapshot.hpp:107
bool snapshot_available
Definition task_registry_snapshot.hpp:105
std::vector< TaskRegistryGraphTask > tasks
Definition task_registry_snapshot.hpp:109
Coroutine task captured in a task-registry graph snapshot.
Definition task_registry_snapshot.hpp:61
TaskRegistryGraphProvenance last_transition_site
Definition task_registry_snapshot.hpp:72
std::string address
Definition task_registry_snapshot.hpp:63
std::vector< std::uint64_t > write_dependencies
Definition task_registry_snapshot.hpp:75
std::string creation_timestamp
Definition task_registry_snapshot.hpp:67
std::vector< TaskRegistryGraphAwaitDependency > await_dependencies
Definition task_registry_snapshot.hpp:76
std::string failure
Definition task_registry_snapshot.hpp:77
TaskRegistryGraphProvenance schedule_site
Definition task_registry_snapshot.hpp:71
std::vector< std::uint64_t > read_dependencies
Definition task_registry_snapshot.hpp:74
std::string state
Definition task_registry_snapshot.hpp:65
std::string waiting_on
Definition task_registry_snapshot.hpp:69
std::size_t transition_count
Definition task_registry_snapshot.hpp:66
std::string last_transition_timestamp
Definition task_registry_snapshot.hpp:68
std::string label
Definition task_registry_snapshot.hpp:64
TaskRegistryGraphProvenance creation_site
Definition task_registry_snapshot.hpp:70
TaskRegistryGraphProvenance last_await_site
Definition task_registry_snapshot.hpp:73
Runtime controls for formatting captured task-registry stacktraces.
Definition task_registry_snapshot.hpp:33
bool include_internal_frames
Definition task_registry_snapshot.hpp:35
std::size_t max_frames
Definition task_registry_snapshot.hpp:34