1 | // Generated by the protocol buffer compiler. DO NOT EDIT! |
2 | // source: tensorflow/core/debug/debugger_event_metadata.proto |
3 | |
4 | #include "tensorflow/core/debug/debugger_event_metadata.pb.h" |
5 | |
6 | #include <algorithm> |
7 | |
8 | #include <google/protobuf/stubs/common.h> |
9 | #include <google/protobuf/io/coded_stream.h> |
10 | #include <google/protobuf/extension_set.h> |
11 | #include <google/protobuf/wire_format_lite.h> |
12 | #include <google/protobuf/descriptor.h> |
13 | #include <google/protobuf/generated_message_reflection.h> |
14 | #include <google/protobuf/reflection_ops.h> |
15 | #include <google/protobuf/wire_format.h> |
16 | // @@protoc_insertion_point(includes) |
17 | #include <google/protobuf/port_def.inc> |
18 | namespace third_party { |
19 | namespace tensorflow { |
20 | namespace core { |
21 | namespace debug { |
22 | class DebuggerEventMetadataDefaultTypeInternal { |
23 | public: |
24 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<DebuggerEventMetadata> _instance; |
25 | } _DebuggerEventMetadata_default_instance_; |
26 | } // namespace debug |
27 | } // namespace core |
28 | } // namespace tensorflow |
29 | } // namespace third_party |
30 | static void InitDefaultsscc_info_DebuggerEventMetadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto() { |
31 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
32 | |
33 | { |
34 | void* ptr = &::third_party::tensorflow::core::debug::_DebuggerEventMetadata_default_instance_; |
35 | new (ptr) ::third_party::tensorflow::core::debug::DebuggerEventMetadata(); |
36 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
37 | } |
38 | ::third_party::tensorflow::core::debug::DebuggerEventMetadata::InitAsDefaultInstance(); |
39 | } |
40 | |
41 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_DebuggerEventMetadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto = |
42 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_DebuggerEventMetadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto}, {}}; |
43 | |
44 | static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto[1]; |
45 | static constexpr ::PROTOBUF_NAMESPACE_ID::EnumDescriptor const** file_level_enum_descriptors_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto = nullptr; |
46 | static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto = nullptr; |
47 | |
48 | const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { |
49 | ~0u, // no _has_bits_ |
50 | PROTOBUF_FIELD_OFFSET(::third_party::tensorflow::core::debug::DebuggerEventMetadata, _internal_metadata_), |
51 | ~0u, // no _extensions_ |
52 | ~0u, // no _oneof_case_ |
53 | ~0u, // no _weak_field_map_ |
54 | PROTOBUF_FIELD_OFFSET(::third_party::tensorflow::core::debug::DebuggerEventMetadata, device_), |
55 | PROTOBUF_FIELD_OFFSET(::third_party::tensorflow::core::debug::DebuggerEventMetadata, output_slot_), |
56 | PROTOBUF_FIELD_OFFSET(::third_party::tensorflow::core::debug::DebuggerEventMetadata, num_chunks_), |
57 | PROTOBUF_FIELD_OFFSET(::third_party::tensorflow::core::debug::DebuggerEventMetadata, chunk_index_), |
58 | }; |
59 | static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { |
60 | { 0, -1, sizeof(::third_party::tensorflow::core::debug::DebuggerEventMetadata)}, |
61 | }; |
62 | |
63 | static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = { |
64 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::third_party::tensorflow::core::debug::_DebuggerEventMetadata_default_instance_), |
65 | }; |
66 | |
67 | const char descriptor_table_protodef_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = |
68 | "\n3tensorflow/core/debug/debugger_event_m" |
69 | "etadata.proto\022!third_party.tensorflow.co" |
70 | "re.debug\"e\n\025DebuggerEventMetadata\022\016\n\006dev" |
71 | "ice\030\001 \001(\t\022\023\n\013output_slot\030\002 \001(\005\022\022\n\nnum_ch" |
72 | "unks\030\003 \001(\005\022\023\n\013chunk_index\030\004 \001(\005b\006proto3" |
73 | ; |
74 | static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_deps[1] = { |
75 | }; |
76 | static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_sccs[1] = { |
77 | &scc_info_DebuggerEventMetadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto.base, |
78 | }; |
79 | static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_once; |
80 | static bool descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_initialized = false; |
81 | const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto = { |
82 | &descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_initialized, descriptor_table_protodef_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto, "tensorflow/core/debug/debugger_event_metadata.proto" , 199, |
83 | &descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_once, descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_sccs, descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto_deps, 1, 0, |
84 | schemas, file_default_instances, TableStruct_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto::offsets, |
85 | file_level_metadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto, 1, file_level_enum_descriptors_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto, file_level_service_descriptors_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto, |
86 | }; |
87 | |
88 | // Force running AddDescriptors() at dynamic initialization time. |
89 | static bool dynamic_init_dummy_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto = ( ::PROTOBUF_NAMESPACE_ID::internal::AddDescriptors(&descriptor_table_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto), true); |
90 | namespace third_party { |
91 | namespace tensorflow { |
92 | namespace core { |
93 | namespace debug { |
94 | |
95 | // =================================================================== |
96 | |
97 | void DebuggerEventMetadata::InitAsDefaultInstance() { |
98 | } |
99 | class DebuggerEventMetadata::_Internal { |
100 | public: |
101 | }; |
102 | |
103 | DebuggerEventMetadata::DebuggerEventMetadata() |
104 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
105 | SharedCtor(); |
106 | // @@protoc_insertion_point(constructor:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
107 | } |
108 | DebuggerEventMetadata::DebuggerEventMetadata(const DebuggerEventMetadata& from) |
109 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
110 | _internal_metadata_(nullptr) { |
111 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
112 | device_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
113 | if (!from.device().empty()) { |
114 | device_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.device_); |
115 | } |
116 | ::memcpy(&output_slot_, &from.output_slot_, |
117 | static_cast<size_t>(reinterpret_cast<char*>(&chunk_index_) - |
118 | reinterpret_cast<char*>(&output_slot_)) + sizeof(chunk_index_)); |
119 | // @@protoc_insertion_point(copy_constructor:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
120 | } |
121 | |
122 | void DebuggerEventMetadata::SharedCtor() { |
123 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_DebuggerEventMetadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto.base); |
124 | device_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
125 | ::memset(&output_slot_, 0, static_cast<size_t>( |
126 | reinterpret_cast<char*>(&chunk_index_) - |
127 | reinterpret_cast<char*>(&output_slot_)) + sizeof(chunk_index_)); |
128 | } |
129 | |
130 | DebuggerEventMetadata::~DebuggerEventMetadata() { |
131 | // @@protoc_insertion_point(destructor:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
132 | SharedDtor(); |
133 | } |
134 | |
135 | void DebuggerEventMetadata::SharedDtor() { |
136 | device_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
137 | } |
138 | |
139 | void DebuggerEventMetadata::SetCachedSize(int size) const { |
140 | _cached_size_.Set(size); |
141 | } |
142 | const DebuggerEventMetadata& DebuggerEventMetadata::default_instance() { |
143 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_DebuggerEventMetadata_tensorflow_2fcore_2fdebug_2fdebugger_5fevent_5fmetadata_2eproto.base); |
144 | return *internal_default_instance(); |
145 | } |
146 | |
147 | |
148 | void DebuggerEventMetadata::Clear() { |
149 | // @@protoc_insertion_point(message_clear_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
150 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
151 | // Prevent compiler warnings about cached_has_bits being unused |
152 | (void) cached_has_bits; |
153 | |
154 | device_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
155 | ::memset(&output_slot_, 0, static_cast<size_t>( |
156 | reinterpret_cast<char*>(&chunk_index_) - |
157 | reinterpret_cast<char*>(&output_slot_)) + sizeof(chunk_index_)); |
158 | _internal_metadata_.Clear(); |
159 | } |
160 | |
161 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
162 | const char* DebuggerEventMetadata::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
163 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
164 | while (!ctx->Done(&ptr)) { |
165 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
166 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
167 | CHK_(ptr); |
168 | switch (tag >> 3) { |
169 | // string device = 1; |
170 | case 1: |
171 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { |
172 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_device(), ptr, ctx, "third_party.tensorflow.core.debug.DebuggerEventMetadata.device" ); |
173 | CHK_(ptr); |
174 | } else goto handle_unusual; |
175 | continue; |
176 | // int32 output_slot = 2; |
177 | case 2: |
178 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 16)) { |
179 | output_slot_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
180 | CHK_(ptr); |
181 | } else goto handle_unusual; |
182 | continue; |
183 | // int32 num_chunks = 3; |
184 | case 3: |
185 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 24)) { |
186 | num_chunks_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
187 | CHK_(ptr); |
188 | } else goto handle_unusual; |
189 | continue; |
190 | // int32 chunk_index = 4; |
191 | case 4: |
192 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 32)) { |
193 | chunk_index_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
194 | CHK_(ptr); |
195 | } else goto handle_unusual; |
196 | continue; |
197 | default: { |
198 | handle_unusual: |
199 | if ((tag & 7) == 4 || tag == 0) { |
200 | ctx->SetLastTag(tag); |
201 | goto success; |
202 | } |
203 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
204 | CHK_(ptr != nullptr); |
205 | continue; |
206 | } |
207 | } // switch |
208 | } // while |
209 | success: |
210 | return ptr; |
211 | failure: |
212 | ptr = nullptr; |
213 | goto success; |
214 | #undef CHK_ |
215 | } |
216 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
217 | bool DebuggerEventMetadata::MergePartialFromCodedStream( |
218 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
219 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
220 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
221 | // @@protoc_insertion_point(parse_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
222 | for (;;) { |
223 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
224 | tag = p.first; |
225 | if (!p.second) goto handle_unusual; |
226 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
227 | // string device = 1; |
228 | case 1: { |
229 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) { |
230 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
231 | input, this->mutable_device())); |
232 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
233 | this->device().data(), static_cast<int>(this->device().length()), |
234 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
235 | "third_party.tensorflow.core.debug.DebuggerEventMetadata.device" )); |
236 | } else { |
237 | goto handle_unusual; |
238 | } |
239 | break; |
240 | } |
241 | |
242 | // int32 output_slot = 2; |
243 | case 2: { |
244 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (16 & 0xFF)) { |
245 | |
246 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
247 | ::PROTOBUF_NAMESPACE_ID::int32, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT32>( |
248 | input, &output_slot_))); |
249 | } else { |
250 | goto handle_unusual; |
251 | } |
252 | break; |
253 | } |
254 | |
255 | // int32 num_chunks = 3; |
256 | case 3: { |
257 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (24 & 0xFF)) { |
258 | |
259 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
260 | ::PROTOBUF_NAMESPACE_ID::int32, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT32>( |
261 | input, &num_chunks_))); |
262 | } else { |
263 | goto handle_unusual; |
264 | } |
265 | break; |
266 | } |
267 | |
268 | // int32 chunk_index = 4; |
269 | case 4: { |
270 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (32 & 0xFF)) { |
271 | |
272 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
273 | ::PROTOBUF_NAMESPACE_ID::int32, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT32>( |
274 | input, &chunk_index_))); |
275 | } else { |
276 | goto handle_unusual; |
277 | } |
278 | break; |
279 | } |
280 | |
281 | default: { |
282 | handle_unusual: |
283 | if (tag == 0) { |
284 | goto success; |
285 | } |
286 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
287 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
288 | break; |
289 | } |
290 | } |
291 | } |
292 | success: |
293 | // @@protoc_insertion_point(parse_success:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
294 | return true; |
295 | failure: |
296 | // @@protoc_insertion_point(parse_failure:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
297 | return false; |
298 | #undef DO_ |
299 | } |
300 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
301 | |
302 | void DebuggerEventMetadata::SerializeWithCachedSizes( |
303 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
304 | // @@protoc_insertion_point(serialize_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
305 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
306 | (void) cached_has_bits; |
307 | |
308 | // string device = 1; |
309 | if (this->device().size() > 0) { |
310 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
311 | this->device().data(), static_cast<int>(this->device().length()), |
312 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
313 | "third_party.tensorflow.core.debug.DebuggerEventMetadata.device" ); |
314 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
315 | 1, this->device(), output); |
316 | } |
317 | |
318 | // int32 output_slot = 2; |
319 | if (this->output_slot() != 0) { |
320 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32(2, this->output_slot(), output); |
321 | } |
322 | |
323 | // int32 num_chunks = 3; |
324 | if (this->num_chunks() != 0) { |
325 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32(3, this->num_chunks(), output); |
326 | } |
327 | |
328 | // int32 chunk_index = 4; |
329 | if (this->chunk_index() != 0) { |
330 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32(4, this->chunk_index(), output); |
331 | } |
332 | |
333 | if (_internal_metadata_.have_unknown_fields()) { |
334 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
335 | _internal_metadata_.unknown_fields(), output); |
336 | } |
337 | // @@protoc_insertion_point(serialize_end:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
338 | } |
339 | |
340 | ::PROTOBUF_NAMESPACE_ID::uint8* DebuggerEventMetadata::InternalSerializeWithCachedSizesToArray( |
341 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
342 | // @@protoc_insertion_point(serialize_to_array_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
343 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
344 | (void) cached_has_bits; |
345 | |
346 | // string device = 1; |
347 | if (this->device().size() > 0) { |
348 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
349 | this->device().data(), static_cast<int>(this->device().length()), |
350 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
351 | "third_party.tensorflow.core.debug.DebuggerEventMetadata.device" ); |
352 | target = |
353 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
354 | 1, this->device(), target); |
355 | } |
356 | |
357 | // int32 output_slot = 2; |
358 | if (this->output_slot() != 0) { |
359 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32ToArray(2, this->output_slot(), target); |
360 | } |
361 | |
362 | // int32 num_chunks = 3; |
363 | if (this->num_chunks() != 0) { |
364 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32ToArray(3, this->num_chunks(), target); |
365 | } |
366 | |
367 | // int32 chunk_index = 4; |
368 | if (this->chunk_index() != 0) { |
369 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32ToArray(4, this->chunk_index(), target); |
370 | } |
371 | |
372 | if (_internal_metadata_.have_unknown_fields()) { |
373 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
374 | _internal_metadata_.unknown_fields(), target); |
375 | } |
376 | // @@protoc_insertion_point(serialize_to_array_end:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
377 | return target; |
378 | } |
379 | |
380 | size_t DebuggerEventMetadata::ByteSizeLong() const { |
381 | // @@protoc_insertion_point(message_byte_size_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
382 | size_t total_size = 0; |
383 | |
384 | if (_internal_metadata_.have_unknown_fields()) { |
385 | total_size += |
386 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
387 | _internal_metadata_.unknown_fields()); |
388 | } |
389 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
390 | // Prevent compiler warnings about cached_has_bits being unused |
391 | (void) cached_has_bits; |
392 | |
393 | // string device = 1; |
394 | if (this->device().size() > 0) { |
395 | total_size += 1 + |
396 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
397 | this->device()); |
398 | } |
399 | |
400 | // int32 output_slot = 2; |
401 | if (this->output_slot() != 0) { |
402 | total_size += 1 + |
403 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int32Size( |
404 | this->output_slot()); |
405 | } |
406 | |
407 | // int32 num_chunks = 3; |
408 | if (this->num_chunks() != 0) { |
409 | total_size += 1 + |
410 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int32Size( |
411 | this->num_chunks()); |
412 | } |
413 | |
414 | // int32 chunk_index = 4; |
415 | if (this->chunk_index() != 0) { |
416 | total_size += 1 + |
417 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int32Size( |
418 | this->chunk_index()); |
419 | } |
420 | |
421 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
422 | SetCachedSize(cached_size); |
423 | return total_size; |
424 | } |
425 | |
426 | void DebuggerEventMetadata::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
427 | // @@protoc_insertion_point(generalized_merge_from_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
428 | GOOGLE_DCHECK_NE(&from, this); |
429 | const DebuggerEventMetadata* source = |
430 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<DebuggerEventMetadata>( |
431 | &from); |
432 | if (source == nullptr) { |
433 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
434 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
435 | } else { |
436 | // @@protoc_insertion_point(generalized_merge_from_cast_success:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
437 | MergeFrom(*source); |
438 | } |
439 | } |
440 | |
441 | void DebuggerEventMetadata::MergeFrom(const DebuggerEventMetadata& from) { |
442 | // @@protoc_insertion_point(class_specific_merge_from_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
443 | GOOGLE_DCHECK_NE(&from, this); |
444 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
445 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
446 | (void) cached_has_bits; |
447 | |
448 | if (from.device().size() > 0) { |
449 | |
450 | device_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.device_); |
451 | } |
452 | if (from.output_slot() != 0) { |
453 | set_output_slot(from.output_slot()); |
454 | } |
455 | if (from.num_chunks() != 0) { |
456 | set_num_chunks(from.num_chunks()); |
457 | } |
458 | if (from.chunk_index() != 0) { |
459 | set_chunk_index(from.chunk_index()); |
460 | } |
461 | } |
462 | |
463 | void DebuggerEventMetadata::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
464 | // @@protoc_insertion_point(generalized_copy_from_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
465 | if (&from == this) return; |
466 | Clear(); |
467 | MergeFrom(from); |
468 | } |
469 | |
470 | void DebuggerEventMetadata::CopyFrom(const DebuggerEventMetadata& from) { |
471 | // @@protoc_insertion_point(class_specific_copy_from_start:third_party.tensorflow.core.debug.DebuggerEventMetadata) |
472 | if (&from == this) return; |
473 | Clear(); |
474 | MergeFrom(from); |
475 | } |
476 | |
477 | bool DebuggerEventMetadata::IsInitialized() const { |
478 | return true; |
479 | } |
480 | |
481 | void DebuggerEventMetadata::InternalSwap(DebuggerEventMetadata* other) { |
482 | using std::swap; |
483 | _internal_metadata_.Swap(&other->_internal_metadata_); |
484 | device_.Swap(&other->device_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
485 | GetArenaNoVirtual()); |
486 | swap(output_slot_, other->output_slot_); |
487 | swap(num_chunks_, other->num_chunks_); |
488 | swap(chunk_index_, other->chunk_index_); |
489 | } |
490 | |
491 | ::PROTOBUF_NAMESPACE_ID::Metadata DebuggerEventMetadata::GetMetadata() const { |
492 | return GetMetadataStatic(); |
493 | } |
494 | |
495 | |
496 | // @@protoc_insertion_point(namespace_scope) |
497 | } // namespace debug |
498 | } // namespace core |
499 | } // namespace tensorflow |
500 | } // namespace third_party |
501 | PROTOBUF_NAMESPACE_OPEN |
502 | template<> PROTOBUF_NOINLINE ::third_party::tensorflow::core::debug::DebuggerEventMetadata* Arena::CreateMaybeMessage< ::third_party::tensorflow::core::debug::DebuggerEventMetadata >(Arena* arena) { |
503 | return Arena::CreateInternal< ::third_party::tensorflow::core::debug::DebuggerEventMetadata >(arena); |
504 | } |
505 | PROTOBUF_NAMESPACE_CLOSE |
506 | |
507 | // @@protoc_insertion_point(global_scope) |
508 | #include <google/protobuf/port_undef.inc> |
509 | |