5#include <unordered_map>
25 constexpr type Any = -1;
26 constexpr type Generic = 1;
27 [[ deprecated(
"Use ComponentType::Generic instead. This constant will be removed in the future (used up until version 1.0.0).") ]]
28 constexpr type None = Generic;
29 constexpr type Thread = 2;
30 constexpr type Core = 3;
31 constexpr type Cache = 4;
32 constexpr type Subdivision = 5;
33 constexpr type Numa = 6;
34 constexpr type Chip = 7;
35 constexpr type Memory = 8;
36 constexpr type Storage = 9;
37 constexpr type Node = 10;
38 constexpr type QuantumBackend = 11;
39 constexpr type AtomSite = 12;
40 constexpr type Qubit = 13;
41 constexpr type Topology = 14;
44 static const std::unordered_map<type, const char*> names = {
45 {Generic,
"GenericComponent"},
46 {Thread,
"HW_Thread"},
49 {Subdivision,
"Subdivision"},
55 {QuantumBackend,
"QuantumBackend"},
56 {AtomSite,
"AtomSite"},
58 {Topology,
"Topology"}
69 inline const char* ToString(type rt) {
70 auto it = names.find(rt);
71 if (it != names.end())
return it->second;
83 constexpr type None = 1;
84 constexpr type GpuSM = 2;
94 constexpr type None = 1;
95 constexpr type Cpu = 2;
96 constexpr type CpuSocket = 3;
97 constexpr type Gpu = 4;
111 using type = int32_t;
113 constexpr type Any = -1;
114 constexpr type Relation = 0;
115 constexpr type DataPath = 1;
116 constexpr type QuantumGate = 2;
117 constexpr type CouplingMap = 3;
118 constexpr type _num_relation_types = 4;
120 constexpr type RelationTypeList [_num_relation_types] = {
128 static const std::unordered_map<type, const char*> names = {
130 {Relation,
"Relation"},
131 {DataPath,
"DataPath"},
132 {QuantumGate,
"QuantumGate"},
133 {CouplingMap,
"CouplingMap"}
143 inline const char* ToString(type rt) {
144 auto it = names.find(rt);
145 if (it != names.end())
return it->second;
153 namespace RelationCategory {
159 constexpr type PAPI_Metrics = 1;
170 using type = int32_t;
172 constexpr type Any = -1;
173 constexpr type None = 0;
174 constexpr type Logical = 1;
175 constexpr type Physical = 2;
176 constexpr type Datatransfer = 3;
177 constexpr type L3CAT = 4;
178 constexpr type MIG = 5;
179 constexpr type C2C = 6;
186 using type = int32_t;
188 constexpr type Any = 1;
189 constexpr type Outgoing = 2;
190 constexpr type Incoming = 3;
199 using type = int32_t;
201 constexpr type Oriented = 1;
202 constexpr type Bidirectional = 2;
209 using type = int32_t;
211 constexpr type Unknown = 0;
212 constexpr type Id = 1;
213 constexpr type X = 2;
214 constexpr type Rz = 3;
215 constexpr type Cnot = 4;
216 constexpr type Sx = 5;
217 constexpr type Toffoli = 6;
220 static const std::unordered_map<type, const char*> names = {
221 {Unknown,
"Unknown"},
236 inline const char* ToString(type rt) {
237 auto it = names.find(rt);
238 if (it != names.end())
return it->second;
Enumerates chip types (CPU, GPU, etc.).
Enumerates all supported component types in sys-sage.
Enumerates directionality for DataPaths.
Enumerates orientation (directed/bidirectional) for DataPaths.
Enumerates types of DataPaths (logical, physical, etc.).
Enumerates quantum gate types.
Enumerates all supported relation types in sys-sage.
Enumerates subdivision types for components (e.g., GPU SMs).
constexpr type Any
Definition enums.hpp:156
int32_t type
Definition enums.hpp:154
constexpr type Default
Definition enums.hpp:157