TT-MLIR
system_desc_generated.h
Go to the documentation of this file.
1 // automatically generated by the FlatBuffers compiler, do not modify
2 
3 
4 #ifndef FLATBUFFERS_GENERATED_SYSTEMDESC_TT_TARGET_H_
5 #define FLATBUFFERS_GENERATED_SYSTEMDESC_TT_TARGET_H_
6 
7 #include "flatbuffers/flatbuffers.h"
8 
9 // Ensure the included flatbuffers.h is the same version as when this file was
10 // generated, otherwise it may not be compatible.
11 static_assert(FLATBUFFERS_VERSION_MAJOR == 24 &&
12  FLATBUFFERS_VERSION_MINOR == 3 &&
13  FLATBUFFERS_VERSION_REVISION == 25,
14  "Non-compatible flatbuffers version included");
15 
18 
19 // For access to the binary schema that produced this file.
21 
22 namespace tt {
23 namespace target {
24 
25 struct SystemDescRoot;
26 struct SystemDescRootBuilder;
27 
28 struct SystemDescRoot FLATBUFFERS_FINAL_CLASS : private ::flatbuffers::Table {
31  struct Traits;
32  static FLATBUFFERS_CONSTEXPR_CPP11 const char *GetFullyQualifiedName() {
33  return "tt.target.SystemDescRoot";
34  }
35  enum FlatBuffersVTableOffset FLATBUFFERS_VTABLE_UNDERLYING_TYPE {
40  VT_SYSTEM_DESC = 12
41  };
42  const tt::target::Version *version() const {
43  return GetStruct<const tt::target::Version *>(VT_VERSION);
44  }
45  const ::flatbuffers::String *schema_hash() const {
46  return GetPointer<const ::flatbuffers::String *>(VT_SCHEMA_HASH);
47  }
48  const ::flatbuffers::String *ttmlir_git_hash() const {
49  return GetPointer<const ::flatbuffers::String *>(VT_TTMLIR_GIT_HASH);
50  }
51  const ::flatbuffers::String *product_identifier() const {
52  return GetPointer<const ::flatbuffers::String *>(VT_PRODUCT_IDENTIFIER);
53  }
54  const tt::target::SystemDesc *system_desc() const {
55  return GetPointer<const tt::target::SystemDesc *>(VT_SYSTEM_DESC);
56  }
57  bool Verify(::flatbuffers::Verifier &verifier) const {
58  return VerifyTableStart(verifier) &&
59  VerifyField<tt::target::Version>(verifier, VT_VERSION, 4) &&
60  VerifyOffset(verifier, VT_SCHEMA_HASH) &&
61  verifier.VerifyString(schema_hash()) &&
62  VerifyOffset(verifier, VT_TTMLIR_GIT_HASH) &&
63  verifier.VerifyString(ttmlir_git_hash()) &&
64  VerifyOffset(verifier, VT_PRODUCT_IDENTIFIER) &&
65  verifier.VerifyString(product_identifier()) &&
66  VerifyOffset(verifier, VT_SYSTEM_DESC) &&
67  verifier.VerifyTable(system_desc()) &&
68  verifier.EndTable();
69  }
70 };
71 
73  typedef SystemDescRoot Table;
74  ::flatbuffers::FlatBufferBuilder &fbb_;
75  ::flatbuffers::uoffset_t start_;
76  void add_version(const tt::target::Version *version) {
77  fbb_.AddStruct(SystemDescRoot::VT_VERSION, version);
78  }
79  void add_schema_hash(::flatbuffers::Offset<::flatbuffers::String> schema_hash) {
80  fbb_.AddOffset(SystemDescRoot::VT_SCHEMA_HASH, schema_hash);
81  }
82  void add_ttmlir_git_hash(::flatbuffers::Offset<::flatbuffers::String> ttmlir_git_hash) {
83  fbb_.AddOffset(SystemDescRoot::VT_TTMLIR_GIT_HASH, ttmlir_git_hash);
84  }
85  void add_product_identifier(::flatbuffers::Offset<::flatbuffers::String> product_identifier) {
86  fbb_.AddOffset(SystemDescRoot::VT_PRODUCT_IDENTIFIER, product_identifier);
87  }
88  void add_system_desc(::flatbuffers::Offset<tt::target::SystemDesc> system_desc) {
89  fbb_.AddOffset(SystemDescRoot::VT_SYSTEM_DESC, system_desc);
90  }
91  explicit SystemDescRootBuilder(::flatbuffers::FlatBufferBuilder &_fbb)
92  : fbb_(_fbb) {
93  start_ = fbb_.StartTable();
94  }
95  ::flatbuffers::Offset<SystemDescRoot> Finish() {
96  const auto end = fbb_.EndTable(start_);
97  auto o = ::flatbuffers::Offset<SystemDescRoot>(end);
98  return o;
99  }
100 };
101 
102 inline ::flatbuffers::Offset<SystemDescRoot> CreateSystemDescRoot(
103  ::flatbuffers::FlatBufferBuilder &_fbb,
104  const tt::target::Version *version = nullptr,
105  ::flatbuffers::Offset<::flatbuffers::String> schema_hash = 0,
106  ::flatbuffers::Offset<::flatbuffers::String> ttmlir_git_hash = 0,
107  ::flatbuffers::Offset<::flatbuffers::String> product_identifier = 0,
108  ::flatbuffers::Offset<tt::target::SystemDesc> system_desc = 0) {
109  SystemDescRootBuilder builder_(_fbb);
110  builder_.add_system_desc(system_desc);
111  builder_.add_product_identifier(product_identifier);
112  builder_.add_ttmlir_git_hash(ttmlir_git_hash);
113  builder_.add_schema_hash(schema_hash);
114  builder_.add_version(version);
115  return builder_.Finish();
116 }
117 
119  using type = SystemDescRoot;
120  static auto constexpr Create = CreateSystemDescRoot;
121 };
122 
123 inline ::flatbuffers::Offset<SystemDescRoot> CreateSystemDescRootDirect(
124  ::flatbuffers::FlatBufferBuilder &_fbb,
125  const tt::target::Version *version = nullptr,
126  const char *schema_hash = nullptr,
127  const char *ttmlir_git_hash = nullptr,
128  const char *product_identifier = nullptr,
129  ::flatbuffers::Offset<tt::target::SystemDesc> system_desc = 0) {
130  auto schema_hash__ = schema_hash ? _fbb.CreateString(schema_hash) : 0;
131  auto ttmlir_git_hash__ = ttmlir_git_hash ? _fbb.CreateString(ttmlir_git_hash) : 0;
132  auto product_identifier__ = product_identifier ? _fbb.CreateString(product_identifier) : 0;
134  _fbb,
135  version,
136  schema_hash__,
137  ttmlir_git_hash__,
138  product_identifier__,
139  system_desc);
140 }
141 
142 inline const tt::target::SystemDescRoot *GetSystemDescRoot(const void *buf) {
143  return ::flatbuffers::GetRoot<tt::target::SystemDescRoot>(buf);
144 }
145 
146 inline const tt::target::SystemDescRoot *GetSizePrefixedSystemDescRoot(const void *buf) {
147  return ::flatbuffers::GetSizePrefixedRoot<tt::target::SystemDescRoot>(buf);
148 }
149 
150 inline const char *SystemDescRootIdentifier() {
151  return "TTSY";
152 }
153 
154 inline bool SystemDescRootBufferHasIdentifier(const void *buf) {
155  return ::flatbuffers::BufferHasIdentifier(
156  buf, SystemDescRootIdentifier());
157 }
158 
159 inline bool SizePrefixedSystemDescRootBufferHasIdentifier(const void *buf) {
160  return ::flatbuffers::BufferHasIdentifier(
161  buf, SystemDescRootIdentifier(), true);
162 }
163 
165  ::flatbuffers::Verifier &verifier) {
166  return verifier.VerifyBuffer<tt::target::SystemDescRoot>(SystemDescRootIdentifier());
167 }
168 
170  ::flatbuffers::Verifier &verifier) {
171  return verifier.VerifySizePrefixedBuffer<tt::target::SystemDescRoot>(SystemDescRootIdentifier());
172 }
173 
174 inline const char *SystemDescRootExtension() {
175  return "ttsys";
176 }
177 
179  ::flatbuffers::FlatBufferBuilder &fbb,
180  ::flatbuffers::Offset<tt::target::SystemDescRoot> root) {
181  fbb.Finish(root, SystemDescRootIdentifier());
182 }
183 
185  ::flatbuffers::FlatBufferBuilder &fbb,
186  ::flatbuffers::Offset<tt::target::SystemDescRoot> root) {
187  fbb.FinishSizePrefixed(root, SystemDescRootIdentifier());
188 }
189 
190 } // namespace target
191 } // namespace tt
192 
193 #endif // FLATBUFFERS_GENERATED_SYSTEMDESC_TT_TARGET_H_
VT_SYSTEM_DESC
Definition: binary_generated.h:551
bool SystemDescRootBufferHasIdentifier(const void *buf)
Definition: system_desc_generated.h:154
inline ::flatbuffers::Offset< SystemDescRoot > CreateSystemDescRootDirect(::flatbuffers::FlatBufferBuilder &_fbb, const tt::target::Version *version=nullptr, const char *schema_hash=nullptr, const char *ttmlir_git_hash=nullptr, const char *product_identifier=nullptr, ::flatbuffers::Offset< tt::target::SystemDesc > system_desc=0)
Definition: system_desc_generated.h:123
const char * SystemDescRootExtension()
Definition: system_desc_generated.h:174
bool VerifySystemDescRootBuffer(::flatbuffers::Verifier &verifier)
Definition: system_desc_generated.h:164
const tt::target::SystemDescRoot * GetSystemDescRoot(const void *buf)
Definition: system_desc_generated.h:142
bool SizePrefixedSystemDescRootBufferHasIdentifier(const void *buf)
Definition: system_desc_generated.h:159
void FinishSystemDescRootBuffer(::flatbuffers::FlatBufferBuilder &fbb, ::flatbuffers::Offset< tt::target::SystemDescRoot > root)
Definition: system_desc_generated.h:178
inline ::flatbuffers::Offset< SystemDescRoot > CreateSystemDescRoot(::flatbuffers::FlatBufferBuilder &_fbb, const tt::target::Version *version=nullptr, ::flatbuffers::Offset<::flatbuffers::String > schema_hash=0, ::flatbuffers::Offset<::flatbuffers::String > ttmlir_git_hash=0, ::flatbuffers::Offset<::flatbuffers::String > product_identifier=0, ::flatbuffers::Offset< tt::target::SystemDesc > system_desc=0)
Definition: system_desc_generated.h:102
const tt::target::SystemDescRoot * GetSizePrefixedSystemDescRoot(const void *buf)
Definition: system_desc_generated.h:146
bool VerifySizePrefixedSystemDescRootBuffer(::flatbuffers::Verifier &verifier)
Definition: system_desc_generated.h:169
void FinishSizePrefixedSystemDescRootBuffer(::flatbuffers::FlatBufferBuilder &fbb, ::flatbuffers::Offset< tt::target::SystemDescRoot > root)
Definition: system_desc_generated.h:184
const char * SystemDescRootIdentifier()
Definition: system_desc_generated.h:150
Definition: debug_info_bfbs_hash_generated.h:4
const tt::target::SystemDesc * system_desc() const
Definition: system_desc_generated.h:54
const ::flatbuffers::String * ttmlir_git_hash() const
Definition: system_desc_generated.h:48
static FLATBUFFERS_CONSTEXPR_CPP11 const char * GetFullyQualifiedName()
Definition: system_desc_generated.h:32
tt::target::SystemDescRootBinarySchema BinarySchema
Definition: system_desc_generated.h:30
SystemDescRootBuilder Builder
Definition: system_desc_generated.h:29
const ::flatbuffers::String * schema_hash() const
Definition: system_desc_generated.h:45
const tt::target::Version * version() const
Definition: system_desc_generated.h:42
const ::flatbuffers::String * product_identifier() const
Definition: system_desc_generated.h:51
bool Verify(::flatbuffers::Verifier &verifier) const
Definition: system_desc_generated.h:57
Definition: system_desc_bfbs_generated.h:12
Definition: system_desc_generated.h:72
SystemDescRoot Table
Definition: system_desc_generated.h:73
::flatbuffers::uoffset_t start_
Definition: system_desc_generated.h:75
::flatbuffers::FlatBufferBuilder & fbb_
Definition: system_desc_generated.h:74
void add_version(const tt::target::Version *version)
Definition: system_desc_generated.h:76
SystemDescRootBuilder(::flatbuffers::FlatBufferBuilder &_fbb)
Definition: system_desc_generated.h:91
void add_schema_hash(::flatbuffers::Offset<::flatbuffers::String > schema_hash)
Definition: system_desc_generated.h:79
void add_product_identifier(::flatbuffers::Offset<::flatbuffers::String > product_identifier)
Definition: system_desc_generated.h:85
::flatbuffers::Offset< SystemDescRoot > Finish()
Definition: system_desc_generated.h:95
void add_ttmlir_git_hash(::flatbuffers::Offset<::flatbuffers::String > ttmlir_git_hash)
Definition: system_desc_generated.h:82
void add_system_desc(::flatbuffers::Offset< tt::target::SystemDesc > system_desc)
Definition: system_desc_generated.h:88
Definition: system_desc_generated.h:118
SystemDescRoot type
Definition: system_desc_generated.h:119
static constexpr auto Create
Definition: system_desc_generated.h:120
VT_SCHEMA_HASH
Definition: system_desc_generated.h:37
VT_VERSION
Definition: system_desc_generated.h:36
VT_PRODUCT_IDENTIFIER
Definition: system_desc_generated.h:39
VT_TTMLIR_GIT_HASH
Definition: system_desc_generated.h:38