1 | // Generated by the protocol buffer compiler. DO NOT EDIT! |
2 | // source: tensorflow/core/profiler/profiler_service.proto |
3 | |
4 | #include "tensorflow/core/profiler/profiler_service.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 | extern PROTOBUF_INTERNAL_EXPORT_tensorflow_2fcore_2fprofiler_2fprofiler_5foptions_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_ProfileOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5foptions_2eproto; |
19 | extern PROTOBUF_INTERNAL_EXPORT_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_ProfileRequest_ToolOptionsEntry_DoNotUse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto; |
20 | extern PROTOBUF_INTERNAL_EXPORT_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto; |
21 | extern PROTOBUF_INTERNAL_EXPORT_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_5fmonitor_5fresult_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_ProfilerServiceMonitorResult_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_5fmonitor_5fresult_2eproto; |
22 | extern PROTOBUF_INTERNAL_EXPORT_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto; |
23 | namespace tensorflow { |
24 | class ToolRequestOptionsDefaultTypeInternal { |
25 | public: |
26 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<ToolRequestOptions> _instance; |
27 | } _ToolRequestOptions_default_instance_; |
28 | class ProfileRequest_ToolOptionsEntry_DoNotUseDefaultTypeInternal { |
29 | public: |
30 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<ProfileRequest_ToolOptionsEntry_DoNotUse> _instance; |
31 | } _ProfileRequest_ToolOptionsEntry_DoNotUse_default_instance_; |
32 | class ProfileRequestDefaultTypeInternal { |
33 | public: |
34 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<ProfileRequest> _instance; |
35 | } _ProfileRequest_default_instance_; |
36 | class ProfileToolDataDefaultTypeInternal { |
37 | public: |
38 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<ProfileToolData> _instance; |
39 | } _ProfileToolData_default_instance_; |
40 | class ProfileResponseDefaultTypeInternal { |
41 | public: |
42 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<ProfileResponse> _instance; |
43 | } _ProfileResponse_default_instance_; |
44 | class TerminateRequestDefaultTypeInternal { |
45 | public: |
46 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<TerminateRequest> _instance; |
47 | } _TerminateRequest_default_instance_; |
48 | class TerminateResponseDefaultTypeInternal { |
49 | public: |
50 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<TerminateResponse> _instance; |
51 | } _TerminateResponse_default_instance_; |
52 | class MonitorRequestDefaultTypeInternal { |
53 | public: |
54 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<MonitorRequest> _instance; |
55 | } _MonitorRequest_default_instance_; |
56 | class MonitorResponseDefaultTypeInternal { |
57 | public: |
58 | ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<MonitorResponse> _instance; |
59 | } _MonitorResponse_default_instance_; |
60 | } // namespace tensorflow |
61 | static void InitDefaultsscc_info_MonitorRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
62 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
63 | |
64 | { |
65 | void* ptr = &::tensorflow::_MonitorRequest_default_instance_; |
66 | new (ptr) ::tensorflow::MonitorRequest(); |
67 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
68 | } |
69 | ::tensorflow::MonitorRequest::InitAsDefaultInstance(); |
70 | } |
71 | |
72 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_MonitorRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
73 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_MonitorRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, {}}; |
74 | |
75 | static void InitDefaultsscc_info_MonitorResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
76 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
77 | |
78 | { |
79 | void* ptr = &::tensorflow::_MonitorResponse_default_instance_; |
80 | new (ptr) ::tensorflow::MonitorResponse(); |
81 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
82 | } |
83 | ::tensorflow::MonitorResponse::InitAsDefaultInstance(); |
84 | } |
85 | |
86 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_MonitorResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
87 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsscc_info_MonitorResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, { |
88 | &scc_info_ProfilerServiceMonitorResult_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_5fmonitor_5fresult_2eproto.base,}}; |
89 | |
90 | static void InitDefaultsscc_info_ProfileRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
91 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
92 | |
93 | { |
94 | void* ptr = &::tensorflow::_ProfileRequest_default_instance_; |
95 | new (ptr) ::tensorflow::ProfileRequest(); |
96 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
97 | } |
98 | ::tensorflow::ProfileRequest::InitAsDefaultInstance(); |
99 | } |
100 | |
101 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<2> scc_info_ProfileRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
102 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 2, InitDefaultsscc_info_ProfileRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, { |
103 | &scc_info_ProfileRequest_ToolOptionsEntry_DoNotUse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
104 | &scc_info_ProfileOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5foptions_2eproto.base,}}; |
105 | |
106 | static void InitDefaultsscc_info_ProfileRequest_ToolOptionsEntry_DoNotUse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
107 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
108 | |
109 | { |
110 | void* ptr = &::tensorflow::_ProfileRequest_ToolOptionsEntry_DoNotUse_default_instance_; |
111 | new (ptr) ::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse(); |
112 | } |
113 | ::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse::InitAsDefaultInstance(); |
114 | } |
115 | |
116 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_ProfileRequest_ToolOptionsEntry_DoNotUse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
117 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsscc_info_ProfileRequest_ToolOptionsEntry_DoNotUse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, { |
118 | &scc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base,}}; |
119 | |
120 | static void InitDefaultsscc_info_ProfileResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
121 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
122 | |
123 | { |
124 | void* ptr = &::tensorflow::_ProfileResponse_default_instance_; |
125 | new (ptr) ::tensorflow::ProfileResponse(); |
126 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
127 | } |
128 | ::tensorflow::ProfileResponse::InitAsDefaultInstance(); |
129 | } |
130 | |
131 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<1> scc_info_ProfileResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
132 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 1, InitDefaultsscc_info_ProfileResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, { |
133 | &scc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base,}}; |
134 | |
135 | static void InitDefaultsscc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
136 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
137 | |
138 | { |
139 | void* ptr = &::tensorflow::_ProfileToolData_default_instance_; |
140 | new (ptr) ::tensorflow::ProfileToolData(); |
141 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
142 | } |
143 | ::tensorflow::ProfileToolData::InitAsDefaultInstance(); |
144 | } |
145 | |
146 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
147 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, {}}; |
148 | |
149 | static void InitDefaultsscc_info_TerminateRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
150 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
151 | |
152 | { |
153 | void* ptr = &::tensorflow::_TerminateRequest_default_instance_; |
154 | new (ptr) ::tensorflow::TerminateRequest(); |
155 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
156 | } |
157 | ::tensorflow::TerminateRequest::InitAsDefaultInstance(); |
158 | } |
159 | |
160 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_TerminateRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
161 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_TerminateRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, {}}; |
162 | |
163 | static void InitDefaultsscc_info_TerminateResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
164 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
165 | |
166 | { |
167 | void* ptr = &::tensorflow::_TerminateResponse_default_instance_; |
168 | new (ptr) ::tensorflow::TerminateResponse(); |
169 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
170 | } |
171 | ::tensorflow::TerminateResponse::InitAsDefaultInstance(); |
172 | } |
173 | |
174 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_TerminateResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
175 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_TerminateResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, {}}; |
176 | |
177 | static void InitDefaultsscc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto() { |
178 | GOOGLE_PROTOBUF_VERIFY_VERSION; |
179 | |
180 | { |
181 | void* ptr = &::tensorflow::_ToolRequestOptions_default_instance_; |
182 | new (ptr) ::tensorflow::ToolRequestOptions(); |
183 | ::PROTOBUF_NAMESPACE_ID::internal::OnShutdownDestroyMessage(ptr); |
184 | } |
185 | ::tensorflow::ToolRequestOptions::InitAsDefaultInstance(); |
186 | } |
187 | |
188 | ::PROTOBUF_NAMESPACE_ID::internal::SCCInfo<0> scc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = |
189 | {{ATOMIC_VAR_INIT(::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase::kUninitialized), 0, InitDefaultsscc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto}, {}}; |
190 | |
191 | static ::PROTOBUF_NAMESPACE_ID::Metadata file_level_metadata_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto[9]; |
192 | static constexpr ::PROTOBUF_NAMESPACE_ID::EnumDescriptor const** file_level_enum_descriptors_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = nullptr; |
193 | static constexpr ::PROTOBUF_NAMESPACE_ID::ServiceDescriptor const** file_level_service_descriptors_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = nullptr; |
194 | |
195 | const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { |
196 | ~0u, // no _has_bits_ |
197 | PROTOBUF_FIELD_OFFSET(::tensorflow::ToolRequestOptions, _internal_metadata_), |
198 | ~0u, // no _extensions_ |
199 | ~0u, // no _oneof_case_ |
200 | ~0u, // no _weak_field_map_ |
201 | PROTOBUF_FIELD_OFFSET(::tensorflow::ToolRequestOptions, output_formats_), |
202 | PROTOBUF_FIELD_OFFSET(::tensorflow::ToolRequestOptions, save_to_repo_), |
203 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse, _has_bits_), |
204 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse, _internal_metadata_), |
205 | ~0u, // no _extensions_ |
206 | ~0u, // no _oneof_case_ |
207 | ~0u, // no _weak_field_map_ |
208 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse, key_), |
209 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse, value_), |
210 | 0, |
211 | 1, |
212 | ~0u, // no _has_bits_ |
213 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, _internal_metadata_), |
214 | ~0u, // no _extensions_ |
215 | ~0u, // no _oneof_case_ |
216 | ~0u, // no _weak_field_map_ |
217 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, duration_ms_), |
218 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, max_events_), |
219 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, tools_), |
220 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, tool_options_), |
221 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, opts_), |
222 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, repository_root_), |
223 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, session_id_), |
224 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileRequest, host_name_), |
225 | ~0u, // no _has_bits_ |
226 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileToolData, _internal_metadata_), |
227 | ~0u, // no _extensions_ |
228 | ~0u, // no _oneof_case_ |
229 | ~0u, // no _weak_field_map_ |
230 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileToolData, name_), |
231 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileToolData, data_), |
232 | ~0u, // no _has_bits_ |
233 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileResponse, _internal_metadata_), |
234 | ~0u, // no _extensions_ |
235 | ~0u, // no _oneof_case_ |
236 | ~0u, // no _weak_field_map_ |
237 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileResponse, tool_data_), |
238 | PROTOBUF_FIELD_OFFSET(::tensorflow::ProfileResponse, empty_trace_), |
239 | ~0u, // no _has_bits_ |
240 | PROTOBUF_FIELD_OFFSET(::tensorflow::TerminateRequest, _internal_metadata_), |
241 | ~0u, // no _extensions_ |
242 | ~0u, // no _oneof_case_ |
243 | ~0u, // no _weak_field_map_ |
244 | PROTOBUF_FIELD_OFFSET(::tensorflow::TerminateRequest, session_id_), |
245 | ~0u, // no _has_bits_ |
246 | PROTOBUF_FIELD_OFFSET(::tensorflow::TerminateResponse, _internal_metadata_), |
247 | ~0u, // no _extensions_ |
248 | ~0u, // no _oneof_case_ |
249 | ~0u, // no _weak_field_map_ |
250 | ~0u, // no _has_bits_ |
251 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorRequest, _internal_metadata_), |
252 | ~0u, // no _extensions_ |
253 | ~0u, // no _oneof_case_ |
254 | ~0u, // no _weak_field_map_ |
255 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorRequest, duration_ms_), |
256 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorRequest, monitoring_level_), |
257 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorRequest, timestamp_), |
258 | ~0u, // no _has_bits_ |
259 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorResponse, _internal_metadata_), |
260 | ~0u, // no _extensions_ |
261 | ~0u, // no _oneof_case_ |
262 | ~0u, // no _weak_field_map_ |
263 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorResponse, data_), |
264 | PROTOBUF_FIELD_OFFSET(::tensorflow::MonitorResponse, monitor_result_), |
265 | }; |
266 | static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = { |
267 | { 0, -1, sizeof(::tensorflow::ToolRequestOptions)}, |
268 | { 7, 14, sizeof(::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse)}, |
269 | { 16, -1, sizeof(::tensorflow::ProfileRequest)}, |
270 | { 29, -1, sizeof(::tensorflow::ProfileToolData)}, |
271 | { 36, -1, sizeof(::tensorflow::ProfileResponse)}, |
272 | { 43, -1, sizeof(::tensorflow::TerminateRequest)}, |
273 | { 49, -1, sizeof(::tensorflow::TerminateResponse)}, |
274 | { 54, -1, sizeof(::tensorflow::MonitorRequest)}, |
275 | { 62, -1, sizeof(::tensorflow::MonitorResponse)}, |
276 | }; |
277 | |
278 | static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = { |
279 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_ToolRequestOptions_default_instance_), |
280 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_ProfileRequest_ToolOptionsEntry_DoNotUse_default_instance_), |
281 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_ProfileRequest_default_instance_), |
282 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_ProfileToolData_default_instance_), |
283 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_ProfileResponse_default_instance_), |
284 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_TerminateRequest_default_instance_), |
285 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_TerminateResponse_default_instance_), |
286 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_MonitorRequest_default_instance_), |
287 | reinterpret_cast<const ::PROTOBUF_NAMESPACE_ID::Message*>(&::tensorflow::_MonitorResponse_default_instance_), |
288 | }; |
289 | |
290 | const char descriptor_table_protodef_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = |
291 | "\n/tensorflow/core/profiler/profiler_serv" |
292 | "ice.proto\022\ntensorflow\032/tensorflow/core/p" |
293 | "rofiler/profiler_options.proto\032>tensorfl" |
294 | "ow/core/profiler/profiler_service_monito" |
295 | "r_result.proto\"B\n\022ToolRequestOptions\022\026\n\016" |
296 | "output_formats\030\002 \001(\t\022\024\n\014save_to_repo\030\003 \001" |
297 | "(\010\"\311\002\n\016ProfileRequest\022\023\n\013duration_ms\030\001 \001" |
298 | "(\004\022\022\n\nmax_events\030\002 \001(\004\022\r\n\005tools\030\003 \003(\t\022A\n" |
299 | "\014tool_options\030\010 \003(\0132+.tensorflow.Profile" |
300 | "Request.ToolOptionsEntry\022(\n\004opts\030\004 \001(\0132\032" |
301 | ".tensorflow.ProfileOptions\022\027\n\017repository" |
302 | "_root\030\005 \001(\t\022\022\n\nsession_id\030\006 \001(\t\022\021\n\thost_" |
303 | "name\030\007 \001(\t\032R\n\020ToolOptionsEntry\022\013\n\003key\030\001 " |
304 | "\001(\t\022-\n\005value\030\002 \001(\0132\036.tensorflow.ToolRequ" |
305 | "estOptions:\0028\001\"-\n\017ProfileToolData\022\014\n\004nam" |
306 | "e\030\001 \001(\t\022\014\n\004data\030\002 \001(\014\"t\n\017ProfileResponse" |
307 | "\022.\n\ttool_data\030\006 \003(\0132\033.tensorflow.Profile" |
308 | "ToolData\022\023\n\013empty_trace\030\007 \001(\010J\004\010\001\020\002J\004\010\002\020" |
309 | "\003J\004\010\003\020\004J\004\010\004\020\005J\004\010\005\020\006\"&\n\020TerminateRequest\022" |
310 | "\022\n\nsession_id\030\001 \001(\t\"\023\n\021TerminateResponse" |
311 | "\"R\n\016MonitorRequest\022\023\n\013duration_ms\030\001 \001(\004\022" |
312 | "\030\n\020monitoring_level\030\002 \001(\005\022\021\n\ttimestamp\030\003" |
313 | " \001(\010\"\221\001\n\017MonitorResponse\022\014\n\004data\030\001 \001(\t\022@" |
314 | "\n\016monitor_result\030\n \001(\0132(.tensorflow.Prof" |
315 | "ilerServiceMonitorResultJ\004\010\002\020\003J\004\010\003\020\004J\004\010\004" |
316 | "\020\005J\004\010\005\020\006J\004\010\006\020\007J\004\010\007\020\010J\004\010\010\020\tJ\004\010\t\020\n2\351\001\n\017Pro" |
317 | "filerService\022D\n\007Profile\022\032.tensorflow.Pro" |
318 | "fileRequest\032\033.tensorflow.ProfileResponse" |
319 | "\"\000\022J\n\tTerminate\022\034.tensorflow.TerminateRe" |
320 | "quest\032\035.tensorflow.TerminateResponse\"\000\022D" |
321 | "\n\007Monitor\022\032.tensorflow.MonitorRequest\032\033." |
322 | "tensorflow.MonitorResponse\"\000b\006proto3" |
323 | ; |
324 | static const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable*const descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_deps[2] = { |
325 | &::descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5foptions_2eproto, |
326 | &::descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_5fmonitor_5fresult_2eproto, |
327 | }; |
328 | static ::PROTOBUF_NAMESPACE_ID::internal::SCCInfoBase*const descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_sccs[9] = { |
329 | &scc_info_MonitorRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
330 | &scc_info_MonitorResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
331 | &scc_info_ProfileRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
332 | &scc_info_ProfileRequest_ToolOptionsEntry_DoNotUse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
333 | &scc_info_ProfileResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
334 | &scc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
335 | &scc_info_TerminateRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
336 | &scc_info_TerminateResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
337 | &scc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base, |
338 | }; |
339 | static ::PROTOBUF_NAMESPACE_ID::internal::once_flag descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_once; |
340 | static bool descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_initialized = false; |
341 | const ::PROTOBUF_NAMESPACE_ID::internal::DescriptorTable descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = { |
342 | &descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_initialized, descriptor_table_protodef_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto, "tensorflow/core/profiler/profiler_service.proto" , 1276, |
343 | &descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_once, descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_sccs, descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto_deps, 9, 2, |
344 | schemas, file_default_instances, TableStruct_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto::offsets, |
345 | file_level_metadata_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto, 9, file_level_enum_descriptors_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto, file_level_service_descriptors_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto, |
346 | }; |
347 | |
348 | // Force running AddDescriptors() at dynamic initialization time. |
349 | static bool dynamic_init_dummy_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto = ( ::PROTOBUF_NAMESPACE_ID::internal::AddDescriptors(&descriptor_table_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto), true); |
350 | namespace tensorflow { |
351 | |
352 | // =================================================================== |
353 | |
354 | void ToolRequestOptions::InitAsDefaultInstance() { |
355 | } |
356 | class ToolRequestOptions::_Internal { |
357 | public: |
358 | }; |
359 | |
360 | ToolRequestOptions::ToolRequestOptions() |
361 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
362 | SharedCtor(); |
363 | // @@protoc_insertion_point(constructor:tensorflow.ToolRequestOptions) |
364 | } |
365 | ToolRequestOptions::ToolRequestOptions(const ToolRequestOptions& from) |
366 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
367 | _internal_metadata_(nullptr) { |
368 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
369 | output_formats_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
370 | if (!from.output_formats().empty()) { |
371 | output_formats_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.output_formats_); |
372 | } |
373 | save_to_repo_ = from.save_to_repo_; |
374 | // @@protoc_insertion_point(copy_constructor:tensorflow.ToolRequestOptions) |
375 | } |
376 | |
377 | void ToolRequestOptions::SharedCtor() { |
378 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
379 | output_formats_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
380 | save_to_repo_ = false; |
381 | } |
382 | |
383 | ToolRequestOptions::~ToolRequestOptions() { |
384 | // @@protoc_insertion_point(destructor:tensorflow.ToolRequestOptions) |
385 | SharedDtor(); |
386 | } |
387 | |
388 | void ToolRequestOptions::SharedDtor() { |
389 | output_formats_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
390 | } |
391 | |
392 | void ToolRequestOptions::SetCachedSize(int size) const { |
393 | _cached_size_.Set(size); |
394 | } |
395 | const ToolRequestOptions& ToolRequestOptions::default_instance() { |
396 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_ToolRequestOptions_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
397 | return *internal_default_instance(); |
398 | } |
399 | |
400 | |
401 | void ToolRequestOptions::Clear() { |
402 | // @@protoc_insertion_point(message_clear_start:tensorflow.ToolRequestOptions) |
403 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
404 | // Prevent compiler warnings about cached_has_bits being unused |
405 | (void) cached_has_bits; |
406 | |
407 | output_formats_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
408 | save_to_repo_ = false; |
409 | _internal_metadata_.Clear(); |
410 | } |
411 | |
412 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
413 | const char* ToolRequestOptions::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
414 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
415 | while (!ctx->Done(&ptr)) { |
416 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
417 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
418 | CHK_(ptr); |
419 | switch (tag >> 3) { |
420 | // string output_formats = 2; |
421 | case 2: |
422 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { |
423 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_output_formats(), ptr, ctx, "tensorflow.ToolRequestOptions.output_formats" ); |
424 | CHK_(ptr); |
425 | } else goto handle_unusual; |
426 | continue; |
427 | // bool save_to_repo = 3; |
428 | case 3: |
429 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 24)) { |
430 | save_to_repo_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
431 | CHK_(ptr); |
432 | } else goto handle_unusual; |
433 | continue; |
434 | default: { |
435 | handle_unusual: |
436 | if ((tag & 7) == 4 || tag == 0) { |
437 | ctx->SetLastTag(tag); |
438 | goto success; |
439 | } |
440 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
441 | CHK_(ptr != nullptr); |
442 | continue; |
443 | } |
444 | } // switch |
445 | } // while |
446 | success: |
447 | return ptr; |
448 | failure: |
449 | ptr = nullptr; |
450 | goto success; |
451 | #undef CHK_ |
452 | } |
453 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
454 | bool ToolRequestOptions::MergePartialFromCodedStream( |
455 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
456 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
457 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
458 | // @@protoc_insertion_point(parse_start:tensorflow.ToolRequestOptions) |
459 | for (;;) { |
460 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
461 | tag = p.first; |
462 | if (!p.second) goto handle_unusual; |
463 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
464 | // string output_formats = 2; |
465 | case 2: { |
466 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (18 & 0xFF)) { |
467 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
468 | input, this->mutable_output_formats())); |
469 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
470 | this->output_formats().data(), static_cast<int>(this->output_formats().length()), |
471 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
472 | "tensorflow.ToolRequestOptions.output_formats" )); |
473 | } else { |
474 | goto handle_unusual; |
475 | } |
476 | break; |
477 | } |
478 | |
479 | // bool save_to_repo = 3; |
480 | case 3: { |
481 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (24 & 0xFF)) { |
482 | |
483 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
484 | bool, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_BOOL>( |
485 | input, &save_to_repo_))); |
486 | } else { |
487 | goto handle_unusual; |
488 | } |
489 | break; |
490 | } |
491 | |
492 | default: { |
493 | handle_unusual: |
494 | if (tag == 0) { |
495 | goto success; |
496 | } |
497 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
498 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
499 | break; |
500 | } |
501 | } |
502 | } |
503 | success: |
504 | // @@protoc_insertion_point(parse_success:tensorflow.ToolRequestOptions) |
505 | return true; |
506 | failure: |
507 | // @@protoc_insertion_point(parse_failure:tensorflow.ToolRequestOptions) |
508 | return false; |
509 | #undef DO_ |
510 | } |
511 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
512 | |
513 | void ToolRequestOptions::SerializeWithCachedSizes( |
514 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
515 | // @@protoc_insertion_point(serialize_start:tensorflow.ToolRequestOptions) |
516 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
517 | (void) cached_has_bits; |
518 | |
519 | // string output_formats = 2; |
520 | if (this->output_formats().size() > 0) { |
521 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
522 | this->output_formats().data(), static_cast<int>(this->output_formats().length()), |
523 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
524 | "tensorflow.ToolRequestOptions.output_formats" ); |
525 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
526 | 2, this->output_formats(), output); |
527 | } |
528 | |
529 | // bool save_to_repo = 3; |
530 | if (this->save_to_repo() != 0) { |
531 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBool(3, this->save_to_repo(), output); |
532 | } |
533 | |
534 | if (_internal_metadata_.have_unknown_fields()) { |
535 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
536 | _internal_metadata_.unknown_fields(), output); |
537 | } |
538 | // @@protoc_insertion_point(serialize_end:tensorflow.ToolRequestOptions) |
539 | } |
540 | |
541 | ::PROTOBUF_NAMESPACE_ID::uint8* ToolRequestOptions::InternalSerializeWithCachedSizesToArray( |
542 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
543 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.ToolRequestOptions) |
544 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
545 | (void) cached_has_bits; |
546 | |
547 | // string output_formats = 2; |
548 | if (this->output_formats().size() > 0) { |
549 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
550 | this->output_formats().data(), static_cast<int>(this->output_formats().length()), |
551 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
552 | "tensorflow.ToolRequestOptions.output_formats" ); |
553 | target = |
554 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
555 | 2, this->output_formats(), target); |
556 | } |
557 | |
558 | // bool save_to_repo = 3; |
559 | if (this->save_to_repo() != 0) { |
560 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBoolToArray(3, this->save_to_repo(), target); |
561 | } |
562 | |
563 | if (_internal_metadata_.have_unknown_fields()) { |
564 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
565 | _internal_metadata_.unknown_fields(), target); |
566 | } |
567 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.ToolRequestOptions) |
568 | return target; |
569 | } |
570 | |
571 | size_t ToolRequestOptions::ByteSizeLong() const { |
572 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.ToolRequestOptions) |
573 | size_t total_size = 0; |
574 | |
575 | if (_internal_metadata_.have_unknown_fields()) { |
576 | total_size += |
577 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
578 | _internal_metadata_.unknown_fields()); |
579 | } |
580 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
581 | // Prevent compiler warnings about cached_has_bits being unused |
582 | (void) cached_has_bits; |
583 | |
584 | // string output_formats = 2; |
585 | if (this->output_formats().size() > 0) { |
586 | total_size += 1 + |
587 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
588 | this->output_formats()); |
589 | } |
590 | |
591 | // bool save_to_repo = 3; |
592 | if (this->save_to_repo() != 0) { |
593 | total_size += 1 + 1; |
594 | } |
595 | |
596 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
597 | SetCachedSize(cached_size); |
598 | return total_size; |
599 | } |
600 | |
601 | void ToolRequestOptions::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
602 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.ToolRequestOptions) |
603 | GOOGLE_DCHECK_NE(&from, this); |
604 | const ToolRequestOptions* source = |
605 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<ToolRequestOptions>( |
606 | &from); |
607 | if (source == nullptr) { |
608 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.ToolRequestOptions) |
609 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
610 | } else { |
611 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.ToolRequestOptions) |
612 | MergeFrom(*source); |
613 | } |
614 | } |
615 | |
616 | void ToolRequestOptions::MergeFrom(const ToolRequestOptions& from) { |
617 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.ToolRequestOptions) |
618 | GOOGLE_DCHECK_NE(&from, this); |
619 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
620 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
621 | (void) cached_has_bits; |
622 | |
623 | if (from.output_formats().size() > 0) { |
624 | |
625 | output_formats_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.output_formats_); |
626 | } |
627 | if (from.save_to_repo() != 0) { |
628 | set_save_to_repo(from.save_to_repo()); |
629 | } |
630 | } |
631 | |
632 | void ToolRequestOptions::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
633 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.ToolRequestOptions) |
634 | if (&from == this) return; |
635 | Clear(); |
636 | MergeFrom(from); |
637 | } |
638 | |
639 | void ToolRequestOptions::CopyFrom(const ToolRequestOptions& from) { |
640 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.ToolRequestOptions) |
641 | if (&from == this) return; |
642 | Clear(); |
643 | MergeFrom(from); |
644 | } |
645 | |
646 | bool ToolRequestOptions::IsInitialized() const { |
647 | return true; |
648 | } |
649 | |
650 | void ToolRequestOptions::InternalSwap(ToolRequestOptions* other) { |
651 | using std::swap; |
652 | _internal_metadata_.Swap(&other->_internal_metadata_); |
653 | output_formats_.Swap(&other->output_formats_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
654 | GetArenaNoVirtual()); |
655 | swap(save_to_repo_, other->save_to_repo_); |
656 | } |
657 | |
658 | ::PROTOBUF_NAMESPACE_ID::Metadata ToolRequestOptions::GetMetadata() const { |
659 | return GetMetadataStatic(); |
660 | } |
661 | |
662 | |
663 | // =================================================================== |
664 | |
665 | ProfileRequest_ToolOptionsEntry_DoNotUse::ProfileRequest_ToolOptionsEntry_DoNotUse() {} |
666 | ProfileRequest_ToolOptionsEntry_DoNotUse::ProfileRequest_ToolOptionsEntry_DoNotUse(::PROTOBUF_NAMESPACE_ID::Arena* arena) |
667 | : SuperType(arena) {} |
668 | void ProfileRequest_ToolOptionsEntry_DoNotUse::MergeFrom(const ProfileRequest_ToolOptionsEntry_DoNotUse& other) { |
669 | MergeFromInternal(other); |
670 | } |
671 | ::PROTOBUF_NAMESPACE_ID::Metadata ProfileRequest_ToolOptionsEntry_DoNotUse::GetMetadata() const { |
672 | return GetMetadataStatic(); |
673 | } |
674 | void ProfileRequest_ToolOptionsEntry_DoNotUse::MergeFrom( |
675 | const ::PROTOBUF_NAMESPACE_ID::Message& other) { |
676 | ::PROTOBUF_NAMESPACE_ID::Message::MergeFrom(other); |
677 | } |
678 | |
679 | |
680 | // =================================================================== |
681 | |
682 | void ProfileRequest::InitAsDefaultInstance() { |
683 | ::tensorflow::_ProfileRequest_default_instance_._instance.get_mutable()->opts_ = const_cast< ::tensorflow::ProfileOptions*>( |
684 | ::tensorflow::ProfileOptions::internal_default_instance()); |
685 | } |
686 | class ProfileRequest::_Internal { |
687 | public: |
688 | static const ::tensorflow::ProfileOptions& opts(const ProfileRequest* msg); |
689 | }; |
690 | |
691 | const ::tensorflow::ProfileOptions& |
692 | ProfileRequest::_Internal::opts(const ProfileRequest* msg) { |
693 | return *msg->opts_; |
694 | } |
695 | void ProfileRequest::clear_opts() { |
696 | if (GetArenaNoVirtual() == nullptr && opts_ != nullptr) { |
697 | delete opts_; |
698 | } |
699 | opts_ = nullptr; |
700 | } |
701 | ProfileRequest::ProfileRequest() |
702 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
703 | SharedCtor(); |
704 | // @@protoc_insertion_point(constructor:tensorflow.ProfileRequest) |
705 | } |
706 | ProfileRequest::ProfileRequest(const ProfileRequest& from) |
707 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
708 | _internal_metadata_(nullptr), |
709 | tools_(from.tools_) { |
710 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
711 | tool_options_.MergeFrom(from.tool_options_); |
712 | repository_root_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
713 | if (!from.repository_root().empty()) { |
714 | repository_root_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.repository_root_); |
715 | } |
716 | session_id_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
717 | if (!from.session_id().empty()) { |
718 | session_id_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.session_id_); |
719 | } |
720 | host_name_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
721 | if (!from.host_name().empty()) { |
722 | host_name_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.host_name_); |
723 | } |
724 | if (from.has_opts()) { |
725 | opts_ = new ::tensorflow::ProfileOptions(*from.opts_); |
726 | } else { |
727 | opts_ = nullptr; |
728 | } |
729 | ::memcpy(&duration_ms_, &from.duration_ms_, |
730 | static_cast<size_t>(reinterpret_cast<char*>(&max_events_) - |
731 | reinterpret_cast<char*>(&duration_ms_)) + sizeof(max_events_)); |
732 | // @@protoc_insertion_point(copy_constructor:tensorflow.ProfileRequest) |
733 | } |
734 | |
735 | void ProfileRequest::SharedCtor() { |
736 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_ProfileRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
737 | repository_root_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
738 | session_id_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
739 | host_name_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
740 | ::memset(&opts_, 0, static_cast<size_t>( |
741 | reinterpret_cast<char*>(&max_events_) - |
742 | reinterpret_cast<char*>(&opts_)) + sizeof(max_events_)); |
743 | } |
744 | |
745 | ProfileRequest::~ProfileRequest() { |
746 | // @@protoc_insertion_point(destructor:tensorflow.ProfileRequest) |
747 | SharedDtor(); |
748 | } |
749 | |
750 | void ProfileRequest::SharedDtor() { |
751 | repository_root_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
752 | session_id_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
753 | host_name_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
754 | if (this != internal_default_instance()) delete opts_; |
755 | } |
756 | |
757 | void ProfileRequest::SetCachedSize(int size) const { |
758 | _cached_size_.Set(size); |
759 | } |
760 | const ProfileRequest& ProfileRequest::default_instance() { |
761 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_ProfileRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
762 | return *internal_default_instance(); |
763 | } |
764 | |
765 | |
766 | void ProfileRequest::Clear() { |
767 | // @@protoc_insertion_point(message_clear_start:tensorflow.ProfileRequest) |
768 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
769 | // Prevent compiler warnings about cached_has_bits being unused |
770 | (void) cached_has_bits; |
771 | |
772 | tools_.Clear(); |
773 | tool_options_.Clear(); |
774 | repository_root_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
775 | session_id_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
776 | host_name_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
777 | if (GetArenaNoVirtual() == nullptr && opts_ != nullptr) { |
778 | delete opts_; |
779 | } |
780 | opts_ = nullptr; |
781 | ::memset(&duration_ms_, 0, static_cast<size_t>( |
782 | reinterpret_cast<char*>(&max_events_) - |
783 | reinterpret_cast<char*>(&duration_ms_)) + sizeof(max_events_)); |
784 | _internal_metadata_.Clear(); |
785 | } |
786 | |
787 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
788 | const char* ProfileRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
789 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
790 | while (!ctx->Done(&ptr)) { |
791 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
792 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
793 | CHK_(ptr); |
794 | switch (tag >> 3) { |
795 | // uint64 duration_ms = 1; |
796 | case 1: |
797 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 8)) { |
798 | duration_ms_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
799 | CHK_(ptr); |
800 | } else goto handle_unusual; |
801 | continue; |
802 | // uint64 max_events = 2; |
803 | case 2: |
804 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 16)) { |
805 | max_events_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
806 | CHK_(ptr); |
807 | } else goto handle_unusual; |
808 | continue; |
809 | // repeated string tools = 3; |
810 | case 3: |
811 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 26)) { |
812 | ptr -= 1; |
813 | do { |
814 | ptr += 1; |
815 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(add_tools(), ptr, ctx, "tensorflow.ProfileRequest.tools" ); |
816 | CHK_(ptr); |
817 | if (!ctx->DataAvailable(ptr)) break; |
818 | } while (::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<::PROTOBUF_NAMESPACE_ID::uint8>(ptr) == 26); |
819 | } else goto handle_unusual; |
820 | continue; |
821 | // .tensorflow.ProfileOptions opts = 4; |
822 | case 4: |
823 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 34)) { |
824 | ptr = ctx->ParseMessage(mutable_opts(), ptr); |
825 | CHK_(ptr); |
826 | } else goto handle_unusual; |
827 | continue; |
828 | // string repository_root = 5; |
829 | case 5: |
830 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 42)) { |
831 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_repository_root(), ptr, ctx, "tensorflow.ProfileRequest.repository_root" ); |
832 | CHK_(ptr); |
833 | } else goto handle_unusual; |
834 | continue; |
835 | // string session_id = 6; |
836 | case 6: |
837 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 50)) { |
838 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_session_id(), ptr, ctx, "tensorflow.ProfileRequest.session_id" ); |
839 | CHK_(ptr); |
840 | } else goto handle_unusual; |
841 | continue; |
842 | // string host_name = 7; |
843 | case 7: |
844 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 58)) { |
845 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_host_name(), ptr, ctx, "tensorflow.ProfileRequest.host_name" ); |
846 | CHK_(ptr); |
847 | } else goto handle_unusual; |
848 | continue; |
849 | // map<string, .tensorflow.ToolRequestOptions> tool_options = 8; |
850 | case 8: |
851 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 66)) { |
852 | ptr -= 1; |
853 | do { |
854 | ptr += 1; |
855 | ptr = ctx->ParseMessage(&tool_options_, ptr); |
856 | CHK_(ptr); |
857 | if (!ctx->DataAvailable(ptr)) break; |
858 | } while (::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<::PROTOBUF_NAMESPACE_ID::uint8>(ptr) == 66); |
859 | } else goto handle_unusual; |
860 | continue; |
861 | default: { |
862 | handle_unusual: |
863 | if ((tag & 7) == 4 || tag == 0) { |
864 | ctx->SetLastTag(tag); |
865 | goto success; |
866 | } |
867 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
868 | CHK_(ptr != nullptr); |
869 | continue; |
870 | } |
871 | } // switch |
872 | } // while |
873 | success: |
874 | return ptr; |
875 | failure: |
876 | ptr = nullptr; |
877 | goto success; |
878 | #undef CHK_ |
879 | } |
880 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
881 | bool ProfileRequest::MergePartialFromCodedStream( |
882 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
883 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
884 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
885 | // @@protoc_insertion_point(parse_start:tensorflow.ProfileRequest) |
886 | for (;;) { |
887 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
888 | tag = p.first; |
889 | if (!p.second) goto handle_unusual; |
890 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
891 | // uint64 duration_ms = 1; |
892 | case 1: { |
893 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (8 & 0xFF)) { |
894 | |
895 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
896 | ::PROTOBUF_NAMESPACE_ID::uint64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_UINT64>( |
897 | input, &duration_ms_))); |
898 | } else { |
899 | goto handle_unusual; |
900 | } |
901 | break; |
902 | } |
903 | |
904 | // uint64 max_events = 2; |
905 | case 2: { |
906 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (16 & 0xFF)) { |
907 | |
908 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
909 | ::PROTOBUF_NAMESPACE_ID::uint64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_UINT64>( |
910 | input, &max_events_))); |
911 | } else { |
912 | goto handle_unusual; |
913 | } |
914 | break; |
915 | } |
916 | |
917 | // repeated string tools = 3; |
918 | case 3: { |
919 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (26 & 0xFF)) { |
920 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
921 | input, this->add_tools())); |
922 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
923 | this->tools(this->tools_size() - 1).data(), |
924 | static_cast<int>(this->tools(this->tools_size() - 1).length()), |
925 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
926 | "tensorflow.ProfileRequest.tools" )); |
927 | } else { |
928 | goto handle_unusual; |
929 | } |
930 | break; |
931 | } |
932 | |
933 | // .tensorflow.ProfileOptions opts = 4; |
934 | case 4: { |
935 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (34 & 0xFF)) { |
936 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage( |
937 | input, mutable_opts())); |
938 | } else { |
939 | goto handle_unusual; |
940 | } |
941 | break; |
942 | } |
943 | |
944 | // string repository_root = 5; |
945 | case 5: { |
946 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (42 & 0xFF)) { |
947 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
948 | input, this->mutable_repository_root())); |
949 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
950 | this->repository_root().data(), static_cast<int>(this->repository_root().length()), |
951 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
952 | "tensorflow.ProfileRequest.repository_root" )); |
953 | } else { |
954 | goto handle_unusual; |
955 | } |
956 | break; |
957 | } |
958 | |
959 | // string session_id = 6; |
960 | case 6: { |
961 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (50 & 0xFF)) { |
962 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
963 | input, this->mutable_session_id())); |
964 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
965 | this->session_id().data(), static_cast<int>(this->session_id().length()), |
966 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
967 | "tensorflow.ProfileRequest.session_id" )); |
968 | } else { |
969 | goto handle_unusual; |
970 | } |
971 | break; |
972 | } |
973 | |
974 | // string host_name = 7; |
975 | case 7: { |
976 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (58 & 0xFF)) { |
977 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
978 | input, this->mutable_host_name())); |
979 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
980 | this->host_name().data(), static_cast<int>(this->host_name().length()), |
981 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
982 | "tensorflow.ProfileRequest.host_name" )); |
983 | } else { |
984 | goto handle_unusual; |
985 | } |
986 | break; |
987 | } |
988 | |
989 | // map<string, .tensorflow.ToolRequestOptions> tool_options = 8; |
990 | case 8: { |
991 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (66 & 0xFF)) { |
992 | ProfileRequest_ToolOptionsEntry_DoNotUse::Parser< ::PROTOBUF_NAMESPACE_ID::internal::MapField< |
993 | ProfileRequest_ToolOptionsEntry_DoNotUse, |
994 | std::string, ::tensorflow::ToolRequestOptions, |
995 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_STRING, |
996 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_MESSAGE, |
997 | 0 >, |
998 | ::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions > > parser(&tool_options_); |
999 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessageNoVirtual( |
1000 | input, &parser)); |
1001 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1002 | parser.key().data(), static_cast<int>(parser.key().length()), |
1003 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
1004 | "tensorflow.ProfileRequest.ToolOptionsEntry.key" )); |
1005 | } else { |
1006 | goto handle_unusual; |
1007 | } |
1008 | break; |
1009 | } |
1010 | |
1011 | default: { |
1012 | handle_unusual: |
1013 | if (tag == 0) { |
1014 | goto success; |
1015 | } |
1016 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
1017 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
1018 | break; |
1019 | } |
1020 | } |
1021 | } |
1022 | success: |
1023 | // @@protoc_insertion_point(parse_success:tensorflow.ProfileRequest) |
1024 | return true; |
1025 | failure: |
1026 | // @@protoc_insertion_point(parse_failure:tensorflow.ProfileRequest) |
1027 | return false; |
1028 | #undef DO_ |
1029 | } |
1030 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1031 | |
1032 | void ProfileRequest::SerializeWithCachedSizes( |
1033 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
1034 | // @@protoc_insertion_point(serialize_start:tensorflow.ProfileRequest) |
1035 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1036 | (void) cached_has_bits; |
1037 | |
1038 | // uint64 duration_ms = 1; |
1039 | if (this->duration_ms() != 0) { |
1040 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt64(1, this->duration_ms(), output); |
1041 | } |
1042 | |
1043 | // uint64 max_events = 2; |
1044 | if (this->max_events() != 0) { |
1045 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt64(2, this->max_events(), output); |
1046 | } |
1047 | |
1048 | // repeated string tools = 3; |
1049 | for (int i = 0, n = this->tools_size(); i < n; i++) { |
1050 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1051 | this->tools(i).data(), static_cast<int>(this->tools(i).length()), |
1052 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1053 | "tensorflow.ProfileRequest.tools" ); |
1054 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteString( |
1055 | 3, this->tools(i), output); |
1056 | } |
1057 | |
1058 | // .tensorflow.ProfileOptions opts = 4; |
1059 | if (this->has_opts()) { |
1060 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray( |
1061 | 4, _Internal::opts(this), output); |
1062 | } |
1063 | |
1064 | // string repository_root = 5; |
1065 | if (this->repository_root().size() > 0) { |
1066 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1067 | this->repository_root().data(), static_cast<int>(this->repository_root().length()), |
1068 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1069 | "tensorflow.ProfileRequest.repository_root" ); |
1070 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
1071 | 5, this->repository_root(), output); |
1072 | } |
1073 | |
1074 | // string session_id = 6; |
1075 | if (this->session_id().size() > 0) { |
1076 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1077 | this->session_id().data(), static_cast<int>(this->session_id().length()), |
1078 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1079 | "tensorflow.ProfileRequest.session_id" ); |
1080 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
1081 | 6, this->session_id(), output); |
1082 | } |
1083 | |
1084 | // string host_name = 7; |
1085 | if (this->host_name().size() > 0) { |
1086 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1087 | this->host_name().data(), static_cast<int>(this->host_name().length()), |
1088 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1089 | "tensorflow.ProfileRequest.host_name" ); |
1090 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
1091 | 7, this->host_name(), output); |
1092 | } |
1093 | |
1094 | // map<string, .tensorflow.ToolRequestOptions> tool_options = 8; |
1095 | if (!this->tool_options().empty()) { |
1096 | typedef ::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_pointer |
1097 | ConstPtr; |
1098 | typedef ConstPtr SortItem; |
1099 | typedef ::PROTOBUF_NAMESPACE_ID::internal::CompareByDerefFirst<SortItem> Less; |
1100 | struct Utf8Check { |
1101 | static void Check(ConstPtr p) { |
1102 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1103 | p->first.data(), static_cast<int>(p->first.length()), |
1104 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1105 | "tensorflow.ProfileRequest.ToolOptionsEntry.key" ); |
1106 | } |
1107 | }; |
1108 | |
1109 | if (output->IsSerializationDeterministic() && |
1110 | this->tool_options().size() > 1) { |
1111 | ::std::unique_ptr<SortItem[]> items( |
1112 | new SortItem[this->tool_options().size()]); |
1113 | typedef ::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::size_type size_type; |
1114 | size_type n = 0; |
1115 | for (::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_iterator |
1116 | it = this->tool_options().begin(); |
1117 | it != this->tool_options().end(); ++it, ++n) { |
1118 | items[static_cast<ptrdiff_t>(n)] = SortItem(&*it); |
1119 | } |
1120 | ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less()); |
1121 | for (size_type i = 0; i < n; i++) { |
1122 | ProfileRequest_ToolOptionsEntry_DoNotUse::Funcs::SerializeToCodedStream(8, items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second, output); |
1123 | Utf8Check::Check(&(*items[static_cast<ptrdiff_t>(i)])); |
1124 | } |
1125 | } else { |
1126 | for (::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_iterator |
1127 | it = this->tool_options().begin(); |
1128 | it != this->tool_options().end(); ++it) { |
1129 | ProfileRequest_ToolOptionsEntry_DoNotUse::Funcs::SerializeToCodedStream(8, it->first, it->second, output); |
1130 | Utf8Check::Check(&(*it)); |
1131 | } |
1132 | } |
1133 | } |
1134 | |
1135 | if (_internal_metadata_.have_unknown_fields()) { |
1136 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
1137 | _internal_metadata_.unknown_fields(), output); |
1138 | } |
1139 | // @@protoc_insertion_point(serialize_end:tensorflow.ProfileRequest) |
1140 | } |
1141 | |
1142 | ::PROTOBUF_NAMESPACE_ID::uint8* ProfileRequest::InternalSerializeWithCachedSizesToArray( |
1143 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
1144 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.ProfileRequest) |
1145 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1146 | (void) cached_has_bits; |
1147 | |
1148 | // uint64 duration_ms = 1; |
1149 | if (this->duration_ms() != 0) { |
1150 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt64ToArray(1, this->duration_ms(), target); |
1151 | } |
1152 | |
1153 | // uint64 max_events = 2; |
1154 | if (this->max_events() != 0) { |
1155 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt64ToArray(2, this->max_events(), target); |
1156 | } |
1157 | |
1158 | // repeated string tools = 3; |
1159 | for (int i = 0, n = this->tools_size(); i < n; i++) { |
1160 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1161 | this->tools(i).data(), static_cast<int>(this->tools(i).length()), |
1162 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1163 | "tensorflow.ProfileRequest.tools" ); |
1164 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: |
1165 | WriteStringToArray(3, this->tools(i), target); |
1166 | } |
1167 | |
1168 | // .tensorflow.ProfileOptions opts = 4; |
1169 | if (this->has_opts()) { |
1170 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: |
1171 | InternalWriteMessageToArray( |
1172 | 4, _Internal::opts(this), target); |
1173 | } |
1174 | |
1175 | // string repository_root = 5; |
1176 | if (this->repository_root().size() > 0) { |
1177 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1178 | this->repository_root().data(), static_cast<int>(this->repository_root().length()), |
1179 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1180 | "tensorflow.ProfileRequest.repository_root" ); |
1181 | target = |
1182 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
1183 | 5, this->repository_root(), target); |
1184 | } |
1185 | |
1186 | // string session_id = 6; |
1187 | if (this->session_id().size() > 0) { |
1188 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1189 | this->session_id().data(), static_cast<int>(this->session_id().length()), |
1190 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1191 | "tensorflow.ProfileRequest.session_id" ); |
1192 | target = |
1193 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
1194 | 6, this->session_id(), target); |
1195 | } |
1196 | |
1197 | // string host_name = 7; |
1198 | if (this->host_name().size() > 0) { |
1199 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1200 | this->host_name().data(), static_cast<int>(this->host_name().length()), |
1201 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1202 | "tensorflow.ProfileRequest.host_name" ); |
1203 | target = |
1204 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
1205 | 7, this->host_name(), target); |
1206 | } |
1207 | |
1208 | // map<string, .tensorflow.ToolRequestOptions> tool_options = 8; |
1209 | if (!this->tool_options().empty()) { |
1210 | typedef ::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_pointer |
1211 | ConstPtr; |
1212 | typedef ConstPtr SortItem; |
1213 | typedef ::PROTOBUF_NAMESPACE_ID::internal::CompareByDerefFirst<SortItem> Less; |
1214 | struct Utf8Check { |
1215 | static void Check(ConstPtr p) { |
1216 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1217 | p->first.data(), static_cast<int>(p->first.length()), |
1218 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1219 | "tensorflow.ProfileRequest.ToolOptionsEntry.key" ); |
1220 | } |
1221 | }; |
1222 | |
1223 | if (false && |
1224 | this->tool_options().size() > 1) { |
1225 | ::std::unique_ptr<SortItem[]> items( |
1226 | new SortItem[this->tool_options().size()]); |
1227 | typedef ::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::size_type size_type; |
1228 | size_type n = 0; |
1229 | for (::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_iterator |
1230 | it = this->tool_options().begin(); |
1231 | it != this->tool_options().end(); ++it, ++n) { |
1232 | items[static_cast<ptrdiff_t>(n)] = SortItem(&*it); |
1233 | } |
1234 | ::std::sort(&items[0], &items[static_cast<ptrdiff_t>(n)], Less()); |
1235 | for (size_type i = 0; i < n; i++) { |
1236 | target = ProfileRequest_ToolOptionsEntry_DoNotUse::Funcs::SerializeToArray(8, items[static_cast<ptrdiff_t>(i)]->first, items[static_cast<ptrdiff_t>(i)]->second, target); |
1237 | Utf8Check::Check(&(*items[static_cast<ptrdiff_t>(i)])); |
1238 | } |
1239 | } else { |
1240 | for (::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_iterator |
1241 | it = this->tool_options().begin(); |
1242 | it != this->tool_options().end(); ++it) { |
1243 | target = ProfileRequest_ToolOptionsEntry_DoNotUse::Funcs::SerializeToArray(8, it->first, it->second, target); |
1244 | Utf8Check::Check(&(*it)); |
1245 | } |
1246 | } |
1247 | } |
1248 | |
1249 | if (_internal_metadata_.have_unknown_fields()) { |
1250 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
1251 | _internal_metadata_.unknown_fields(), target); |
1252 | } |
1253 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.ProfileRequest) |
1254 | return target; |
1255 | } |
1256 | |
1257 | size_t ProfileRequest::ByteSizeLong() const { |
1258 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.ProfileRequest) |
1259 | size_t total_size = 0; |
1260 | |
1261 | if (_internal_metadata_.have_unknown_fields()) { |
1262 | total_size += |
1263 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
1264 | _internal_metadata_.unknown_fields()); |
1265 | } |
1266 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1267 | // Prevent compiler warnings about cached_has_bits being unused |
1268 | (void) cached_has_bits; |
1269 | |
1270 | // repeated string tools = 3; |
1271 | total_size += 1 * |
1272 | ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(this->tools_size()); |
1273 | for (int i = 0, n = this->tools_size(); i < n; i++) { |
1274 | total_size += ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
1275 | this->tools(i)); |
1276 | } |
1277 | |
1278 | // map<string, .tensorflow.ToolRequestOptions> tool_options = 8; |
1279 | total_size += 1 * |
1280 | ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(this->tool_options_size()); |
1281 | for (::PROTOBUF_NAMESPACE_ID::Map< std::string, ::tensorflow::ToolRequestOptions >::const_iterator |
1282 | it = this->tool_options().begin(); |
1283 | it != this->tool_options().end(); ++it) { |
1284 | total_size += ProfileRequest_ToolOptionsEntry_DoNotUse::Funcs::ByteSizeLong(it->first, it->second); |
1285 | } |
1286 | |
1287 | // string repository_root = 5; |
1288 | if (this->repository_root().size() > 0) { |
1289 | total_size += 1 + |
1290 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
1291 | this->repository_root()); |
1292 | } |
1293 | |
1294 | // string session_id = 6; |
1295 | if (this->session_id().size() > 0) { |
1296 | total_size += 1 + |
1297 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
1298 | this->session_id()); |
1299 | } |
1300 | |
1301 | // string host_name = 7; |
1302 | if (this->host_name().size() > 0) { |
1303 | total_size += 1 + |
1304 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
1305 | this->host_name()); |
1306 | } |
1307 | |
1308 | // .tensorflow.ProfileOptions opts = 4; |
1309 | if (this->has_opts()) { |
1310 | total_size += 1 + |
1311 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize( |
1312 | *opts_); |
1313 | } |
1314 | |
1315 | // uint64 duration_ms = 1; |
1316 | if (this->duration_ms() != 0) { |
1317 | total_size += 1 + |
1318 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::UInt64Size( |
1319 | this->duration_ms()); |
1320 | } |
1321 | |
1322 | // uint64 max_events = 2; |
1323 | if (this->max_events() != 0) { |
1324 | total_size += 1 + |
1325 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::UInt64Size( |
1326 | this->max_events()); |
1327 | } |
1328 | |
1329 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
1330 | SetCachedSize(cached_size); |
1331 | return total_size; |
1332 | } |
1333 | |
1334 | void ProfileRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
1335 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.ProfileRequest) |
1336 | GOOGLE_DCHECK_NE(&from, this); |
1337 | const ProfileRequest* source = |
1338 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<ProfileRequest>( |
1339 | &from); |
1340 | if (source == nullptr) { |
1341 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.ProfileRequest) |
1342 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
1343 | } else { |
1344 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.ProfileRequest) |
1345 | MergeFrom(*source); |
1346 | } |
1347 | } |
1348 | |
1349 | void ProfileRequest::MergeFrom(const ProfileRequest& from) { |
1350 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.ProfileRequest) |
1351 | GOOGLE_DCHECK_NE(&from, this); |
1352 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
1353 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1354 | (void) cached_has_bits; |
1355 | |
1356 | tools_.MergeFrom(from.tools_); |
1357 | tool_options_.MergeFrom(from.tool_options_); |
1358 | if (from.repository_root().size() > 0) { |
1359 | |
1360 | repository_root_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.repository_root_); |
1361 | } |
1362 | if (from.session_id().size() > 0) { |
1363 | |
1364 | session_id_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.session_id_); |
1365 | } |
1366 | if (from.host_name().size() > 0) { |
1367 | |
1368 | host_name_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.host_name_); |
1369 | } |
1370 | if (from.has_opts()) { |
1371 | mutable_opts()->::tensorflow::ProfileOptions::MergeFrom(from.opts()); |
1372 | } |
1373 | if (from.duration_ms() != 0) { |
1374 | set_duration_ms(from.duration_ms()); |
1375 | } |
1376 | if (from.max_events() != 0) { |
1377 | set_max_events(from.max_events()); |
1378 | } |
1379 | } |
1380 | |
1381 | void ProfileRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
1382 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.ProfileRequest) |
1383 | if (&from == this) return; |
1384 | Clear(); |
1385 | MergeFrom(from); |
1386 | } |
1387 | |
1388 | void ProfileRequest::CopyFrom(const ProfileRequest& from) { |
1389 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.ProfileRequest) |
1390 | if (&from == this) return; |
1391 | Clear(); |
1392 | MergeFrom(from); |
1393 | } |
1394 | |
1395 | bool ProfileRequest::IsInitialized() const { |
1396 | return true; |
1397 | } |
1398 | |
1399 | void ProfileRequest::InternalSwap(ProfileRequest* other) { |
1400 | using std::swap; |
1401 | _internal_metadata_.Swap(&other->_internal_metadata_); |
1402 | tools_.InternalSwap(CastToBase(&other->tools_)); |
1403 | tool_options_.Swap(&other->tool_options_); |
1404 | repository_root_.Swap(&other->repository_root_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
1405 | GetArenaNoVirtual()); |
1406 | session_id_.Swap(&other->session_id_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
1407 | GetArenaNoVirtual()); |
1408 | host_name_.Swap(&other->host_name_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
1409 | GetArenaNoVirtual()); |
1410 | swap(opts_, other->opts_); |
1411 | swap(duration_ms_, other->duration_ms_); |
1412 | swap(max_events_, other->max_events_); |
1413 | } |
1414 | |
1415 | ::PROTOBUF_NAMESPACE_ID::Metadata ProfileRequest::GetMetadata() const { |
1416 | return GetMetadataStatic(); |
1417 | } |
1418 | |
1419 | |
1420 | // =================================================================== |
1421 | |
1422 | void ProfileToolData::InitAsDefaultInstance() { |
1423 | } |
1424 | class ProfileToolData::_Internal { |
1425 | public: |
1426 | }; |
1427 | |
1428 | ProfileToolData::ProfileToolData() |
1429 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
1430 | SharedCtor(); |
1431 | // @@protoc_insertion_point(constructor:tensorflow.ProfileToolData) |
1432 | } |
1433 | ProfileToolData::ProfileToolData(const ProfileToolData& from) |
1434 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
1435 | _internal_metadata_(nullptr) { |
1436 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
1437 | name_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1438 | if (!from.name().empty()) { |
1439 | name_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.name_); |
1440 | } |
1441 | data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1442 | if (!from.data().empty()) { |
1443 | data_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.data_); |
1444 | } |
1445 | // @@protoc_insertion_point(copy_constructor:tensorflow.ProfileToolData) |
1446 | } |
1447 | |
1448 | void ProfileToolData::SharedCtor() { |
1449 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
1450 | name_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1451 | data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1452 | } |
1453 | |
1454 | ProfileToolData::~ProfileToolData() { |
1455 | // @@protoc_insertion_point(destructor:tensorflow.ProfileToolData) |
1456 | SharedDtor(); |
1457 | } |
1458 | |
1459 | void ProfileToolData::SharedDtor() { |
1460 | name_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1461 | data_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1462 | } |
1463 | |
1464 | void ProfileToolData::SetCachedSize(int size) const { |
1465 | _cached_size_.Set(size); |
1466 | } |
1467 | const ProfileToolData& ProfileToolData::default_instance() { |
1468 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_ProfileToolData_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
1469 | return *internal_default_instance(); |
1470 | } |
1471 | |
1472 | |
1473 | void ProfileToolData::Clear() { |
1474 | // @@protoc_insertion_point(message_clear_start:tensorflow.ProfileToolData) |
1475 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1476 | // Prevent compiler warnings about cached_has_bits being unused |
1477 | (void) cached_has_bits; |
1478 | |
1479 | name_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1480 | data_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
1481 | _internal_metadata_.Clear(); |
1482 | } |
1483 | |
1484 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1485 | const char* ProfileToolData::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
1486 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
1487 | while (!ctx->Done(&ptr)) { |
1488 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
1489 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
1490 | CHK_(ptr); |
1491 | switch (tag >> 3) { |
1492 | // string name = 1; |
1493 | case 1: |
1494 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { |
1495 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_name(), ptr, ctx, "tensorflow.ProfileToolData.name" ); |
1496 | CHK_(ptr); |
1497 | } else goto handle_unusual; |
1498 | continue; |
1499 | // bytes data = 2; |
1500 | case 2: |
1501 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 18)) { |
1502 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParser(mutable_data(), ptr, ctx); |
1503 | CHK_(ptr); |
1504 | } else goto handle_unusual; |
1505 | continue; |
1506 | default: { |
1507 | handle_unusual: |
1508 | if ((tag & 7) == 4 || tag == 0) { |
1509 | ctx->SetLastTag(tag); |
1510 | goto success; |
1511 | } |
1512 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
1513 | CHK_(ptr != nullptr); |
1514 | continue; |
1515 | } |
1516 | } // switch |
1517 | } // while |
1518 | success: |
1519 | return ptr; |
1520 | failure: |
1521 | ptr = nullptr; |
1522 | goto success; |
1523 | #undef CHK_ |
1524 | } |
1525 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1526 | bool ProfileToolData::MergePartialFromCodedStream( |
1527 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
1528 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
1529 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
1530 | // @@protoc_insertion_point(parse_start:tensorflow.ProfileToolData) |
1531 | for (;;) { |
1532 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
1533 | tag = p.first; |
1534 | if (!p.second) goto handle_unusual; |
1535 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
1536 | // string name = 1; |
1537 | case 1: { |
1538 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) { |
1539 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
1540 | input, this->mutable_name())); |
1541 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1542 | this->name().data(), static_cast<int>(this->name().length()), |
1543 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
1544 | "tensorflow.ProfileToolData.name" )); |
1545 | } else { |
1546 | goto handle_unusual; |
1547 | } |
1548 | break; |
1549 | } |
1550 | |
1551 | // bytes data = 2; |
1552 | case 2: { |
1553 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (18 & 0xFF)) { |
1554 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadBytes( |
1555 | input, this->mutable_data())); |
1556 | } else { |
1557 | goto handle_unusual; |
1558 | } |
1559 | break; |
1560 | } |
1561 | |
1562 | default: { |
1563 | handle_unusual: |
1564 | if (tag == 0) { |
1565 | goto success; |
1566 | } |
1567 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
1568 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
1569 | break; |
1570 | } |
1571 | } |
1572 | } |
1573 | success: |
1574 | // @@protoc_insertion_point(parse_success:tensorflow.ProfileToolData) |
1575 | return true; |
1576 | failure: |
1577 | // @@protoc_insertion_point(parse_failure:tensorflow.ProfileToolData) |
1578 | return false; |
1579 | #undef DO_ |
1580 | } |
1581 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1582 | |
1583 | void ProfileToolData::SerializeWithCachedSizes( |
1584 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
1585 | // @@protoc_insertion_point(serialize_start:tensorflow.ProfileToolData) |
1586 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1587 | (void) cached_has_bits; |
1588 | |
1589 | // string name = 1; |
1590 | if (this->name().size() > 0) { |
1591 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1592 | this->name().data(), static_cast<int>(this->name().length()), |
1593 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1594 | "tensorflow.ProfileToolData.name" ); |
1595 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
1596 | 1, this->name(), output); |
1597 | } |
1598 | |
1599 | // bytes data = 2; |
1600 | if (this->data().size() > 0) { |
1601 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBytesMaybeAliased( |
1602 | 2, this->data(), output); |
1603 | } |
1604 | |
1605 | if (_internal_metadata_.have_unknown_fields()) { |
1606 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
1607 | _internal_metadata_.unknown_fields(), output); |
1608 | } |
1609 | // @@protoc_insertion_point(serialize_end:tensorflow.ProfileToolData) |
1610 | } |
1611 | |
1612 | ::PROTOBUF_NAMESPACE_ID::uint8* ProfileToolData::InternalSerializeWithCachedSizesToArray( |
1613 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
1614 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.ProfileToolData) |
1615 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1616 | (void) cached_has_bits; |
1617 | |
1618 | // string name = 1; |
1619 | if (this->name().size() > 0) { |
1620 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
1621 | this->name().data(), static_cast<int>(this->name().length()), |
1622 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
1623 | "tensorflow.ProfileToolData.name" ); |
1624 | target = |
1625 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
1626 | 1, this->name(), target); |
1627 | } |
1628 | |
1629 | // bytes data = 2; |
1630 | if (this->data().size() > 0) { |
1631 | target = |
1632 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBytesToArray( |
1633 | 2, this->data(), target); |
1634 | } |
1635 | |
1636 | if (_internal_metadata_.have_unknown_fields()) { |
1637 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
1638 | _internal_metadata_.unknown_fields(), target); |
1639 | } |
1640 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.ProfileToolData) |
1641 | return target; |
1642 | } |
1643 | |
1644 | size_t ProfileToolData::ByteSizeLong() const { |
1645 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.ProfileToolData) |
1646 | size_t total_size = 0; |
1647 | |
1648 | if (_internal_metadata_.have_unknown_fields()) { |
1649 | total_size += |
1650 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
1651 | _internal_metadata_.unknown_fields()); |
1652 | } |
1653 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1654 | // Prevent compiler warnings about cached_has_bits being unused |
1655 | (void) cached_has_bits; |
1656 | |
1657 | // string name = 1; |
1658 | if (this->name().size() > 0) { |
1659 | total_size += 1 + |
1660 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
1661 | this->name()); |
1662 | } |
1663 | |
1664 | // bytes data = 2; |
1665 | if (this->data().size() > 0) { |
1666 | total_size += 1 + |
1667 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::BytesSize( |
1668 | this->data()); |
1669 | } |
1670 | |
1671 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
1672 | SetCachedSize(cached_size); |
1673 | return total_size; |
1674 | } |
1675 | |
1676 | void ProfileToolData::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
1677 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.ProfileToolData) |
1678 | GOOGLE_DCHECK_NE(&from, this); |
1679 | const ProfileToolData* source = |
1680 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<ProfileToolData>( |
1681 | &from); |
1682 | if (source == nullptr) { |
1683 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.ProfileToolData) |
1684 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
1685 | } else { |
1686 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.ProfileToolData) |
1687 | MergeFrom(*source); |
1688 | } |
1689 | } |
1690 | |
1691 | void ProfileToolData::MergeFrom(const ProfileToolData& from) { |
1692 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.ProfileToolData) |
1693 | GOOGLE_DCHECK_NE(&from, this); |
1694 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
1695 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1696 | (void) cached_has_bits; |
1697 | |
1698 | if (from.name().size() > 0) { |
1699 | |
1700 | name_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.name_); |
1701 | } |
1702 | if (from.data().size() > 0) { |
1703 | |
1704 | data_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.data_); |
1705 | } |
1706 | } |
1707 | |
1708 | void ProfileToolData::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
1709 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.ProfileToolData) |
1710 | if (&from == this) return; |
1711 | Clear(); |
1712 | MergeFrom(from); |
1713 | } |
1714 | |
1715 | void ProfileToolData::CopyFrom(const ProfileToolData& from) { |
1716 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.ProfileToolData) |
1717 | if (&from == this) return; |
1718 | Clear(); |
1719 | MergeFrom(from); |
1720 | } |
1721 | |
1722 | bool ProfileToolData::IsInitialized() const { |
1723 | return true; |
1724 | } |
1725 | |
1726 | void ProfileToolData::InternalSwap(ProfileToolData* other) { |
1727 | using std::swap; |
1728 | _internal_metadata_.Swap(&other->_internal_metadata_); |
1729 | name_.Swap(&other->name_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
1730 | GetArenaNoVirtual()); |
1731 | data_.Swap(&other->data_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
1732 | GetArenaNoVirtual()); |
1733 | } |
1734 | |
1735 | ::PROTOBUF_NAMESPACE_ID::Metadata ProfileToolData::GetMetadata() const { |
1736 | return GetMetadataStatic(); |
1737 | } |
1738 | |
1739 | |
1740 | // =================================================================== |
1741 | |
1742 | void ProfileResponse::InitAsDefaultInstance() { |
1743 | } |
1744 | class ProfileResponse::_Internal { |
1745 | public: |
1746 | }; |
1747 | |
1748 | ProfileResponse::ProfileResponse() |
1749 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
1750 | SharedCtor(); |
1751 | // @@protoc_insertion_point(constructor:tensorflow.ProfileResponse) |
1752 | } |
1753 | ProfileResponse::ProfileResponse(const ProfileResponse& from) |
1754 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
1755 | _internal_metadata_(nullptr), |
1756 | tool_data_(from.tool_data_) { |
1757 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
1758 | empty_trace_ = from.empty_trace_; |
1759 | // @@protoc_insertion_point(copy_constructor:tensorflow.ProfileResponse) |
1760 | } |
1761 | |
1762 | void ProfileResponse::SharedCtor() { |
1763 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_ProfileResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
1764 | empty_trace_ = false; |
1765 | } |
1766 | |
1767 | ProfileResponse::~ProfileResponse() { |
1768 | // @@protoc_insertion_point(destructor:tensorflow.ProfileResponse) |
1769 | SharedDtor(); |
1770 | } |
1771 | |
1772 | void ProfileResponse::SharedDtor() { |
1773 | } |
1774 | |
1775 | void ProfileResponse::SetCachedSize(int size) const { |
1776 | _cached_size_.Set(size); |
1777 | } |
1778 | const ProfileResponse& ProfileResponse::default_instance() { |
1779 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_ProfileResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
1780 | return *internal_default_instance(); |
1781 | } |
1782 | |
1783 | |
1784 | void ProfileResponse::Clear() { |
1785 | // @@protoc_insertion_point(message_clear_start:tensorflow.ProfileResponse) |
1786 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1787 | // Prevent compiler warnings about cached_has_bits being unused |
1788 | (void) cached_has_bits; |
1789 | |
1790 | tool_data_.Clear(); |
1791 | empty_trace_ = false; |
1792 | _internal_metadata_.Clear(); |
1793 | } |
1794 | |
1795 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1796 | const char* ProfileResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
1797 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
1798 | while (!ctx->Done(&ptr)) { |
1799 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
1800 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
1801 | CHK_(ptr); |
1802 | switch (tag >> 3) { |
1803 | // repeated .tensorflow.ProfileToolData tool_data = 6; |
1804 | case 6: |
1805 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 50)) { |
1806 | ptr -= 1; |
1807 | do { |
1808 | ptr += 1; |
1809 | ptr = ctx->ParseMessage(add_tool_data(), ptr); |
1810 | CHK_(ptr); |
1811 | if (!ctx->DataAvailable(ptr)) break; |
1812 | } while (::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<::PROTOBUF_NAMESPACE_ID::uint8>(ptr) == 50); |
1813 | } else goto handle_unusual; |
1814 | continue; |
1815 | // bool empty_trace = 7; |
1816 | case 7: |
1817 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 56)) { |
1818 | empty_trace_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
1819 | CHK_(ptr); |
1820 | } else goto handle_unusual; |
1821 | continue; |
1822 | default: { |
1823 | handle_unusual: |
1824 | if ((tag & 7) == 4 || tag == 0) { |
1825 | ctx->SetLastTag(tag); |
1826 | goto success; |
1827 | } |
1828 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
1829 | CHK_(ptr != nullptr); |
1830 | continue; |
1831 | } |
1832 | } // switch |
1833 | } // while |
1834 | success: |
1835 | return ptr; |
1836 | failure: |
1837 | ptr = nullptr; |
1838 | goto success; |
1839 | #undef CHK_ |
1840 | } |
1841 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1842 | bool ProfileResponse::MergePartialFromCodedStream( |
1843 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
1844 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
1845 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
1846 | // @@protoc_insertion_point(parse_start:tensorflow.ProfileResponse) |
1847 | for (;;) { |
1848 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
1849 | tag = p.first; |
1850 | if (!p.second) goto handle_unusual; |
1851 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
1852 | // repeated .tensorflow.ProfileToolData tool_data = 6; |
1853 | case 6: { |
1854 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (50 & 0xFF)) { |
1855 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage( |
1856 | input, add_tool_data())); |
1857 | } else { |
1858 | goto handle_unusual; |
1859 | } |
1860 | break; |
1861 | } |
1862 | |
1863 | // bool empty_trace = 7; |
1864 | case 7: { |
1865 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (56 & 0xFF)) { |
1866 | |
1867 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
1868 | bool, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_BOOL>( |
1869 | input, &empty_trace_))); |
1870 | } else { |
1871 | goto handle_unusual; |
1872 | } |
1873 | break; |
1874 | } |
1875 | |
1876 | default: { |
1877 | handle_unusual: |
1878 | if (tag == 0) { |
1879 | goto success; |
1880 | } |
1881 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
1882 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
1883 | break; |
1884 | } |
1885 | } |
1886 | } |
1887 | success: |
1888 | // @@protoc_insertion_point(parse_success:tensorflow.ProfileResponse) |
1889 | return true; |
1890 | failure: |
1891 | // @@protoc_insertion_point(parse_failure:tensorflow.ProfileResponse) |
1892 | return false; |
1893 | #undef DO_ |
1894 | } |
1895 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
1896 | |
1897 | void ProfileResponse::SerializeWithCachedSizes( |
1898 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
1899 | // @@protoc_insertion_point(serialize_start:tensorflow.ProfileResponse) |
1900 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1901 | (void) cached_has_bits; |
1902 | |
1903 | // repeated .tensorflow.ProfileToolData tool_data = 6; |
1904 | for (unsigned int i = 0, |
1905 | n = static_cast<unsigned int>(this->tool_data_size()); i < n; i++) { |
1906 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray( |
1907 | 6, |
1908 | this->tool_data(static_cast<int>(i)), |
1909 | output); |
1910 | } |
1911 | |
1912 | // bool empty_trace = 7; |
1913 | if (this->empty_trace() != 0) { |
1914 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBool(7, this->empty_trace(), output); |
1915 | } |
1916 | |
1917 | if (_internal_metadata_.have_unknown_fields()) { |
1918 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
1919 | _internal_metadata_.unknown_fields(), output); |
1920 | } |
1921 | // @@protoc_insertion_point(serialize_end:tensorflow.ProfileResponse) |
1922 | } |
1923 | |
1924 | ::PROTOBUF_NAMESPACE_ID::uint8* ProfileResponse::InternalSerializeWithCachedSizesToArray( |
1925 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
1926 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.ProfileResponse) |
1927 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1928 | (void) cached_has_bits; |
1929 | |
1930 | // repeated .tensorflow.ProfileToolData tool_data = 6; |
1931 | for (unsigned int i = 0, |
1932 | n = static_cast<unsigned int>(this->tool_data_size()); i < n; i++) { |
1933 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: |
1934 | InternalWriteMessageToArray( |
1935 | 6, this->tool_data(static_cast<int>(i)), target); |
1936 | } |
1937 | |
1938 | // bool empty_trace = 7; |
1939 | if (this->empty_trace() != 0) { |
1940 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBoolToArray(7, this->empty_trace(), target); |
1941 | } |
1942 | |
1943 | if (_internal_metadata_.have_unknown_fields()) { |
1944 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
1945 | _internal_metadata_.unknown_fields(), target); |
1946 | } |
1947 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.ProfileResponse) |
1948 | return target; |
1949 | } |
1950 | |
1951 | size_t ProfileResponse::ByteSizeLong() const { |
1952 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.ProfileResponse) |
1953 | size_t total_size = 0; |
1954 | |
1955 | if (_internal_metadata_.have_unknown_fields()) { |
1956 | total_size += |
1957 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
1958 | _internal_metadata_.unknown_fields()); |
1959 | } |
1960 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
1961 | // Prevent compiler warnings about cached_has_bits being unused |
1962 | (void) cached_has_bits; |
1963 | |
1964 | // repeated .tensorflow.ProfileToolData tool_data = 6; |
1965 | { |
1966 | unsigned int count = static_cast<unsigned int>(this->tool_data_size()); |
1967 | total_size += 1UL * count; |
1968 | for (unsigned int i = 0; i < count; i++) { |
1969 | total_size += |
1970 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize( |
1971 | this->tool_data(static_cast<int>(i))); |
1972 | } |
1973 | } |
1974 | |
1975 | // bool empty_trace = 7; |
1976 | if (this->empty_trace() != 0) { |
1977 | total_size += 1 + 1; |
1978 | } |
1979 | |
1980 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
1981 | SetCachedSize(cached_size); |
1982 | return total_size; |
1983 | } |
1984 | |
1985 | void ProfileResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
1986 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.ProfileResponse) |
1987 | GOOGLE_DCHECK_NE(&from, this); |
1988 | const ProfileResponse* source = |
1989 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<ProfileResponse>( |
1990 | &from); |
1991 | if (source == nullptr) { |
1992 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.ProfileResponse) |
1993 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
1994 | } else { |
1995 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.ProfileResponse) |
1996 | MergeFrom(*source); |
1997 | } |
1998 | } |
1999 | |
2000 | void ProfileResponse::MergeFrom(const ProfileResponse& from) { |
2001 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.ProfileResponse) |
2002 | GOOGLE_DCHECK_NE(&from, this); |
2003 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2004 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2005 | (void) cached_has_bits; |
2006 | |
2007 | tool_data_.MergeFrom(from.tool_data_); |
2008 | if (from.empty_trace() != 0) { |
2009 | set_empty_trace(from.empty_trace()); |
2010 | } |
2011 | } |
2012 | |
2013 | void ProfileResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2014 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.ProfileResponse) |
2015 | if (&from == this) return; |
2016 | Clear(); |
2017 | MergeFrom(from); |
2018 | } |
2019 | |
2020 | void ProfileResponse::CopyFrom(const ProfileResponse& from) { |
2021 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.ProfileResponse) |
2022 | if (&from == this) return; |
2023 | Clear(); |
2024 | MergeFrom(from); |
2025 | } |
2026 | |
2027 | bool ProfileResponse::IsInitialized() const { |
2028 | return true; |
2029 | } |
2030 | |
2031 | void ProfileResponse::InternalSwap(ProfileResponse* other) { |
2032 | using std::swap; |
2033 | _internal_metadata_.Swap(&other->_internal_metadata_); |
2034 | CastToBase(&tool_data_)->InternalSwap(CastToBase(&other->tool_data_)); |
2035 | swap(empty_trace_, other->empty_trace_); |
2036 | } |
2037 | |
2038 | ::PROTOBUF_NAMESPACE_ID::Metadata ProfileResponse::GetMetadata() const { |
2039 | return GetMetadataStatic(); |
2040 | } |
2041 | |
2042 | |
2043 | // =================================================================== |
2044 | |
2045 | void TerminateRequest::InitAsDefaultInstance() { |
2046 | } |
2047 | class TerminateRequest::_Internal { |
2048 | public: |
2049 | }; |
2050 | |
2051 | TerminateRequest::TerminateRequest() |
2052 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
2053 | SharedCtor(); |
2054 | // @@protoc_insertion_point(constructor:tensorflow.TerminateRequest) |
2055 | } |
2056 | TerminateRequest::TerminateRequest(const TerminateRequest& from) |
2057 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
2058 | _internal_metadata_(nullptr) { |
2059 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2060 | session_id_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2061 | if (!from.session_id().empty()) { |
2062 | session_id_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.session_id_); |
2063 | } |
2064 | // @@protoc_insertion_point(copy_constructor:tensorflow.TerminateRequest) |
2065 | } |
2066 | |
2067 | void TerminateRequest::SharedCtor() { |
2068 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_TerminateRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
2069 | session_id_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2070 | } |
2071 | |
2072 | TerminateRequest::~TerminateRequest() { |
2073 | // @@protoc_insertion_point(destructor:tensorflow.TerminateRequest) |
2074 | SharedDtor(); |
2075 | } |
2076 | |
2077 | void TerminateRequest::SharedDtor() { |
2078 | session_id_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2079 | } |
2080 | |
2081 | void TerminateRequest::SetCachedSize(int size) const { |
2082 | _cached_size_.Set(size); |
2083 | } |
2084 | const TerminateRequest& TerminateRequest::default_instance() { |
2085 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_TerminateRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
2086 | return *internal_default_instance(); |
2087 | } |
2088 | |
2089 | |
2090 | void TerminateRequest::Clear() { |
2091 | // @@protoc_insertion_point(message_clear_start:tensorflow.TerminateRequest) |
2092 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2093 | // Prevent compiler warnings about cached_has_bits being unused |
2094 | (void) cached_has_bits; |
2095 | |
2096 | session_id_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2097 | _internal_metadata_.Clear(); |
2098 | } |
2099 | |
2100 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2101 | const char* TerminateRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
2102 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
2103 | while (!ctx->Done(&ptr)) { |
2104 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2105 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
2106 | CHK_(ptr); |
2107 | switch (tag >> 3) { |
2108 | // string session_id = 1; |
2109 | case 1: |
2110 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { |
2111 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_session_id(), ptr, ctx, "tensorflow.TerminateRequest.session_id" ); |
2112 | CHK_(ptr); |
2113 | } else goto handle_unusual; |
2114 | continue; |
2115 | default: { |
2116 | handle_unusual: |
2117 | if ((tag & 7) == 4 || tag == 0) { |
2118 | ctx->SetLastTag(tag); |
2119 | goto success; |
2120 | } |
2121 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
2122 | CHK_(ptr != nullptr); |
2123 | continue; |
2124 | } |
2125 | } // switch |
2126 | } // while |
2127 | success: |
2128 | return ptr; |
2129 | failure: |
2130 | ptr = nullptr; |
2131 | goto success; |
2132 | #undef CHK_ |
2133 | } |
2134 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2135 | bool TerminateRequest::MergePartialFromCodedStream( |
2136 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
2137 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
2138 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2139 | // @@protoc_insertion_point(parse_start:tensorflow.TerminateRequest) |
2140 | for (;;) { |
2141 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
2142 | tag = p.first; |
2143 | if (!p.second) goto handle_unusual; |
2144 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
2145 | // string session_id = 1; |
2146 | case 1: { |
2147 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) { |
2148 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
2149 | input, this->mutable_session_id())); |
2150 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
2151 | this->session_id().data(), static_cast<int>(this->session_id().length()), |
2152 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
2153 | "tensorflow.TerminateRequest.session_id" )); |
2154 | } else { |
2155 | goto handle_unusual; |
2156 | } |
2157 | break; |
2158 | } |
2159 | |
2160 | default: { |
2161 | handle_unusual: |
2162 | if (tag == 0) { |
2163 | goto success; |
2164 | } |
2165 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
2166 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
2167 | break; |
2168 | } |
2169 | } |
2170 | } |
2171 | success: |
2172 | // @@protoc_insertion_point(parse_success:tensorflow.TerminateRequest) |
2173 | return true; |
2174 | failure: |
2175 | // @@protoc_insertion_point(parse_failure:tensorflow.TerminateRequest) |
2176 | return false; |
2177 | #undef DO_ |
2178 | } |
2179 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2180 | |
2181 | void TerminateRequest::SerializeWithCachedSizes( |
2182 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
2183 | // @@protoc_insertion_point(serialize_start:tensorflow.TerminateRequest) |
2184 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2185 | (void) cached_has_bits; |
2186 | |
2187 | // string session_id = 1; |
2188 | if (this->session_id().size() > 0) { |
2189 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
2190 | this->session_id().data(), static_cast<int>(this->session_id().length()), |
2191 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
2192 | "tensorflow.TerminateRequest.session_id" ); |
2193 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
2194 | 1, this->session_id(), output); |
2195 | } |
2196 | |
2197 | if (_internal_metadata_.have_unknown_fields()) { |
2198 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
2199 | _internal_metadata_.unknown_fields(), output); |
2200 | } |
2201 | // @@protoc_insertion_point(serialize_end:tensorflow.TerminateRequest) |
2202 | } |
2203 | |
2204 | ::PROTOBUF_NAMESPACE_ID::uint8* TerminateRequest::InternalSerializeWithCachedSizesToArray( |
2205 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
2206 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.TerminateRequest) |
2207 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2208 | (void) cached_has_bits; |
2209 | |
2210 | // string session_id = 1; |
2211 | if (this->session_id().size() > 0) { |
2212 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
2213 | this->session_id().data(), static_cast<int>(this->session_id().length()), |
2214 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
2215 | "tensorflow.TerminateRequest.session_id" ); |
2216 | target = |
2217 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
2218 | 1, this->session_id(), target); |
2219 | } |
2220 | |
2221 | if (_internal_metadata_.have_unknown_fields()) { |
2222 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
2223 | _internal_metadata_.unknown_fields(), target); |
2224 | } |
2225 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.TerminateRequest) |
2226 | return target; |
2227 | } |
2228 | |
2229 | size_t TerminateRequest::ByteSizeLong() const { |
2230 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.TerminateRequest) |
2231 | size_t total_size = 0; |
2232 | |
2233 | if (_internal_metadata_.have_unknown_fields()) { |
2234 | total_size += |
2235 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
2236 | _internal_metadata_.unknown_fields()); |
2237 | } |
2238 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2239 | // Prevent compiler warnings about cached_has_bits being unused |
2240 | (void) cached_has_bits; |
2241 | |
2242 | // string session_id = 1; |
2243 | if (this->session_id().size() > 0) { |
2244 | total_size += 1 + |
2245 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
2246 | this->session_id()); |
2247 | } |
2248 | |
2249 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
2250 | SetCachedSize(cached_size); |
2251 | return total_size; |
2252 | } |
2253 | |
2254 | void TerminateRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2255 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.TerminateRequest) |
2256 | GOOGLE_DCHECK_NE(&from, this); |
2257 | const TerminateRequest* source = |
2258 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<TerminateRequest>( |
2259 | &from); |
2260 | if (source == nullptr) { |
2261 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.TerminateRequest) |
2262 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
2263 | } else { |
2264 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.TerminateRequest) |
2265 | MergeFrom(*source); |
2266 | } |
2267 | } |
2268 | |
2269 | void TerminateRequest::MergeFrom(const TerminateRequest& from) { |
2270 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.TerminateRequest) |
2271 | GOOGLE_DCHECK_NE(&from, this); |
2272 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2273 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2274 | (void) cached_has_bits; |
2275 | |
2276 | if (from.session_id().size() > 0) { |
2277 | |
2278 | session_id_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.session_id_); |
2279 | } |
2280 | } |
2281 | |
2282 | void TerminateRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2283 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.TerminateRequest) |
2284 | if (&from == this) return; |
2285 | Clear(); |
2286 | MergeFrom(from); |
2287 | } |
2288 | |
2289 | void TerminateRequest::CopyFrom(const TerminateRequest& from) { |
2290 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.TerminateRequest) |
2291 | if (&from == this) return; |
2292 | Clear(); |
2293 | MergeFrom(from); |
2294 | } |
2295 | |
2296 | bool TerminateRequest::IsInitialized() const { |
2297 | return true; |
2298 | } |
2299 | |
2300 | void TerminateRequest::InternalSwap(TerminateRequest* other) { |
2301 | using std::swap; |
2302 | _internal_metadata_.Swap(&other->_internal_metadata_); |
2303 | session_id_.Swap(&other->session_id_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
2304 | GetArenaNoVirtual()); |
2305 | } |
2306 | |
2307 | ::PROTOBUF_NAMESPACE_ID::Metadata TerminateRequest::GetMetadata() const { |
2308 | return GetMetadataStatic(); |
2309 | } |
2310 | |
2311 | |
2312 | // =================================================================== |
2313 | |
2314 | void TerminateResponse::InitAsDefaultInstance() { |
2315 | } |
2316 | class TerminateResponse::_Internal { |
2317 | public: |
2318 | }; |
2319 | |
2320 | TerminateResponse::TerminateResponse() |
2321 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
2322 | SharedCtor(); |
2323 | // @@protoc_insertion_point(constructor:tensorflow.TerminateResponse) |
2324 | } |
2325 | TerminateResponse::TerminateResponse(const TerminateResponse& from) |
2326 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
2327 | _internal_metadata_(nullptr) { |
2328 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2329 | // @@protoc_insertion_point(copy_constructor:tensorflow.TerminateResponse) |
2330 | } |
2331 | |
2332 | void TerminateResponse::SharedCtor() { |
2333 | } |
2334 | |
2335 | TerminateResponse::~TerminateResponse() { |
2336 | // @@protoc_insertion_point(destructor:tensorflow.TerminateResponse) |
2337 | SharedDtor(); |
2338 | } |
2339 | |
2340 | void TerminateResponse::SharedDtor() { |
2341 | } |
2342 | |
2343 | void TerminateResponse::SetCachedSize(int size) const { |
2344 | _cached_size_.Set(size); |
2345 | } |
2346 | const TerminateResponse& TerminateResponse::default_instance() { |
2347 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_TerminateResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
2348 | return *internal_default_instance(); |
2349 | } |
2350 | |
2351 | |
2352 | void TerminateResponse::Clear() { |
2353 | // @@protoc_insertion_point(message_clear_start:tensorflow.TerminateResponse) |
2354 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2355 | // Prevent compiler warnings about cached_has_bits being unused |
2356 | (void) cached_has_bits; |
2357 | |
2358 | _internal_metadata_.Clear(); |
2359 | } |
2360 | |
2361 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2362 | const char* TerminateResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
2363 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
2364 | while (!ctx->Done(&ptr)) { |
2365 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2366 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
2367 | CHK_(ptr); |
2368 | switch (tag >> 3) { |
2369 | default: { |
2370 | if ((tag & 7) == 4 || tag == 0) { |
2371 | ctx->SetLastTag(tag); |
2372 | goto success; |
2373 | } |
2374 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
2375 | CHK_(ptr != nullptr); |
2376 | continue; |
2377 | } |
2378 | } // switch |
2379 | } // while |
2380 | success: |
2381 | return ptr; |
2382 | failure: |
2383 | ptr = nullptr; |
2384 | goto success; |
2385 | #undef CHK_ |
2386 | } |
2387 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2388 | bool TerminateResponse::MergePartialFromCodedStream( |
2389 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
2390 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
2391 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2392 | // @@protoc_insertion_point(parse_start:tensorflow.TerminateResponse) |
2393 | for (;;) { |
2394 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
2395 | tag = p.first; |
2396 | if (!p.second) goto handle_unusual; |
2397 | handle_unusual: |
2398 | if (tag == 0) { |
2399 | goto success; |
2400 | } |
2401 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
2402 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
2403 | } |
2404 | success: |
2405 | // @@protoc_insertion_point(parse_success:tensorflow.TerminateResponse) |
2406 | return true; |
2407 | failure: |
2408 | // @@protoc_insertion_point(parse_failure:tensorflow.TerminateResponse) |
2409 | return false; |
2410 | #undef DO_ |
2411 | } |
2412 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2413 | |
2414 | void TerminateResponse::SerializeWithCachedSizes( |
2415 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
2416 | // @@protoc_insertion_point(serialize_start:tensorflow.TerminateResponse) |
2417 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2418 | (void) cached_has_bits; |
2419 | |
2420 | if (_internal_metadata_.have_unknown_fields()) { |
2421 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
2422 | _internal_metadata_.unknown_fields(), output); |
2423 | } |
2424 | // @@protoc_insertion_point(serialize_end:tensorflow.TerminateResponse) |
2425 | } |
2426 | |
2427 | ::PROTOBUF_NAMESPACE_ID::uint8* TerminateResponse::InternalSerializeWithCachedSizesToArray( |
2428 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
2429 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.TerminateResponse) |
2430 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2431 | (void) cached_has_bits; |
2432 | |
2433 | if (_internal_metadata_.have_unknown_fields()) { |
2434 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
2435 | _internal_metadata_.unknown_fields(), target); |
2436 | } |
2437 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.TerminateResponse) |
2438 | return target; |
2439 | } |
2440 | |
2441 | size_t TerminateResponse::ByteSizeLong() const { |
2442 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.TerminateResponse) |
2443 | size_t total_size = 0; |
2444 | |
2445 | if (_internal_metadata_.have_unknown_fields()) { |
2446 | total_size += |
2447 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
2448 | _internal_metadata_.unknown_fields()); |
2449 | } |
2450 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2451 | // Prevent compiler warnings about cached_has_bits being unused |
2452 | (void) cached_has_bits; |
2453 | |
2454 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
2455 | SetCachedSize(cached_size); |
2456 | return total_size; |
2457 | } |
2458 | |
2459 | void TerminateResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2460 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.TerminateResponse) |
2461 | GOOGLE_DCHECK_NE(&from, this); |
2462 | const TerminateResponse* source = |
2463 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<TerminateResponse>( |
2464 | &from); |
2465 | if (source == nullptr) { |
2466 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.TerminateResponse) |
2467 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
2468 | } else { |
2469 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.TerminateResponse) |
2470 | MergeFrom(*source); |
2471 | } |
2472 | } |
2473 | |
2474 | void TerminateResponse::MergeFrom(const TerminateResponse& from) { |
2475 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.TerminateResponse) |
2476 | GOOGLE_DCHECK_NE(&from, this); |
2477 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2478 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2479 | (void) cached_has_bits; |
2480 | |
2481 | } |
2482 | |
2483 | void TerminateResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2484 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.TerminateResponse) |
2485 | if (&from == this) return; |
2486 | Clear(); |
2487 | MergeFrom(from); |
2488 | } |
2489 | |
2490 | void TerminateResponse::CopyFrom(const TerminateResponse& from) { |
2491 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.TerminateResponse) |
2492 | if (&from == this) return; |
2493 | Clear(); |
2494 | MergeFrom(from); |
2495 | } |
2496 | |
2497 | bool TerminateResponse::IsInitialized() const { |
2498 | return true; |
2499 | } |
2500 | |
2501 | void TerminateResponse::InternalSwap(TerminateResponse* other) { |
2502 | using std::swap; |
2503 | _internal_metadata_.Swap(&other->_internal_metadata_); |
2504 | } |
2505 | |
2506 | ::PROTOBUF_NAMESPACE_ID::Metadata TerminateResponse::GetMetadata() const { |
2507 | return GetMetadataStatic(); |
2508 | } |
2509 | |
2510 | |
2511 | // =================================================================== |
2512 | |
2513 | void MonitorRequest::InitAsDefaultInstance() { |
2514 | } |
2515 | class MonitorRequest::_Internal { |
2516 | public: |
2517 | }; |
2518 | |
2519 | MonitorRequest::MonitorRequest() |
2520 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
2521 | SharedCtor(); |
2522 | // @@protoc_insertion_point(constructor:tensorflow.MonitorRequest) |
2523 | } |
2524 | MonitorRequest::MonitorRequest(const MonitorRequest& from) |
2525 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
2526 | _internal_metadata_(nullptr) { |
2527 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2528 | ::memcpy(&duration_ms_, &from.duration_ms_, |
2529 | static_cast<size_t>(reinterpret_cast<char*>(×tamp_) - |
2530 | reinterpret_cast<char*>(&duration_ms_)) + sizeof(timestamp_)); |
2531 | // @@protoc_insertion_point(copy_constructor:tensorflow.MonitorRequest) |
2532 | } |
2533 | |
2534 | void MonitorRequest::SharedCtor() { |
2535 | ::memset(&duration_ms_, 0, static_cast<size_t>( |
2536 | reinterpret_cast<char*>(×tamp_) - |
2537 | reinterpret_cast<char*>(&duration_ms_)) + sizeof(timestamp_)); |
2538 | } |
2539 | |
2540 | MonitorRequest::~MonitorRequest() { |
2541 | // @@protoc_insertion_point(destructor:tensorflow.MonitorRequest) |
2542 | SharedDtor(); |
2543 | } |
2544 | |
2545 | void MonitorRequest::SharedDtor() { |
2546 | } |
2547 | |
2548 | void MonitorRequest::SetCachedSize(int size) const { |
2549 | _cached_size_.Set(size); |
2550 | } |
2551 | const MonitorRequest& MonitorRequest::default_instance() { |
2552 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_MonitorRequest_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
2553 | return *internal_default_instance(); |
2554 | } |
2555 | |
2556 | |
2557 | void MonitorRequest::Clear() { |
2558 | // @@protoc_insertion_point(message_clear_start:tensorflow.MonitorRequest) |
2559 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2560 | // Prevent compiler warnings about cached_has_bits being unused |
2561 | (void) cached_has_bits; |
2562 | |
2563 | ::memset(&duration_ms_, 0, static_cast<size_t>( |
2564 | reinterpret_cast<char*>(×tamp_) - |
2565 | reinterpret_cast<char*>(&duration_ms_)) + sizeof(timestamp_)); |
2566 | _internal_metadata_.Clear(); |
2567 | } |
2568 | |
2569 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2570 | const char* MonitorRequest::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
2571 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
2572 | while (!ctx->Done(&ptr)) { |
2573 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2574 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
2575 | CHK_(ptr); |
2576 | switch (tag >> 3) { |
2577 | // uint64 duration_ms = 1; |
2578 | case 1: |
2579 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 8)) { |
2580 | duration_ms_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
2581 | CHK_(ptr); |
2582 | } else goto handle_unusual; |
2583 | continue; |
2584 | // int32 monitoring_level = 2; |
2585 | case 2: |
2586 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 16)) { |
2587 | monitoring_level_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
2588 | CHK_(ptr); |
2589 | } else goto handle_unusual; |
2590 | continue; |
2591 | // bool timestamp = 3; |
2592 | case 3: |
2593 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 24)) { |
2594 | timestamp_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint(&ptr); |
2595 | CHK_(ptr); |
2596 | } else goto handle_unusual; |
2597 | continue; |
2598 | default: { |
2599 | handle_unusual: |
2600 | if ((tag & 7) == 4 || tag == 0) { |
2601 | ctx->SetLastTag(tag); |
2602 | goto success; |
2603 | } |
2604 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
2605 | CHK_(ptr != nullptr); |
2606 | continue; |
2607 | } |
2608 | } // switch |
2609 | } // while |
2610 | success: |
2611 | return ptr; |
2612 | failure: |
2613 | ptr = nullptr; |
2614 | goto success; |
2615 | #undef CHK_ |
2616 | } |
2617 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2618 | bool MonitorRequest::MergePartialFromCodedStream( |
2619 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
2620 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
2621 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2622 | // @@protoc_insertion_point(parse_start:tensorflow.MonitorRequest) |
2623 | for (;;) { |
2624 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
2625 | tag = p.first; |
2626 | if (!p.second) goto handle_unusual; |
2627 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
2628 | // uint64 duration_ms = 1; |
2629 | case 1: { |
2630 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (8 & 0xFF)) { |
2631 | |
2632 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
2633 | ::PROTOBUF_NAMESPACE_ID::uint64, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_UINT64>( |
2634 | input, &duration_ms_))); |
2635 | } else { |
2636 | goto handle_unusual; |
2637 | } |
2638 | break; |
2639 | } |
2640 | |
2641 | // int32 monitoring_level = 2; |
2642 | case 2: { |
2643 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (16 & 0xFF)) { |
2644 | |
2645 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
2646 | ::PROTOBUF_NAMESPACE_ID::int32, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_INT32>( |
2647 | input, &monitoring_level_))); |
2648 | } else { |
2649 | goto handle_unusual; |
2650 | } |
2651 | break; |
2652 | } |
2653 | |
2654 | // bool timestamp = 3; |
2655 | case 3: { |
2656 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (24 & 0xFF)) { |
2657 | |
2658 | DO_((::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadPrimitive< |
2659 | bool, ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::TYPE_BOOL>( |
2660 | input, ×tamp_))); |
2661 | } else { |
2662 | goto handle_unusual; |
2663 | } |
2664 | break; |
2665 | } |
2666 | |
2667 | default: { |
2668 | handle_unusual: |
2669 | if (tag == 0) { |
2670 | goto success; |
2671 | } |
2672 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
2673 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
2674 | break; |
2675 | } |
2676 | } |
2677 | } |
2678 | success: |
2679 | // @@protoc_insertion_point(parse_success:tensorflow.MonitorRequest) |
2680 | return true; |
2681 | failure: |
2682 | // @@protoc_insertion_point(parse_failure:tensorflow.MonitorRequest) |
2683 | return false; |
2684 | #undef DO_ |
2685 | } |
2686 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2687 | |
2688 | void MonitorRequest::SerializeWithCachedSizes( |
2689 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
2690 | // @@protoc_insertion_point(serialize_start:tensorflow.MonitorRequest) |
2691 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2692 | (void) cached_has_bits; |
2693 | |
2694 | // uint64 duration_ms = 1; |
2695 | if (this->duration_ms() != 0) { |
2696 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt64(1, this->duration_ms(), output); |
2697 | } |
2698 | |
2699 | // int32 monitoring_level = 2; |
2700 | if (this->monitoring_level() != 0) { |
2701 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32(2, this->monitoring_level(), output); |
2702 | } |
2703 | |
2704 | // bool timestamp = 3; |
2705 | if (this->timestamp() != 0) { |
2706 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBool(3, this->timestamp(), output); |
2707 | } |
2708 | |
2709 | if (_internal_metadata_.have_unknown_fields()) { |
2710 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
2711 | _internal_metadata_.unknown_fields(), output); |
2712 | } |
2713 | // @@protoc_insertion_point(serialize_end:tensorflow.MonitorRequest) |
2714 | } |
2715 | |
2716 | ::PROTOBUF_NAMESPACE_ID::uint8* MonitorRequest::InternalSerializeWithCachedSizesToArray( |
2717 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
2718 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.MonitorRequest) |
2719 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2720 | (void) cached_has_bits; |
2721 | |
2722 | // uint64 duration_ms = 1; |
2723 | if (this->duration_ms() != 0) { |
2724 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt64ToArray(1, this->duration_ms(), target); |
2725 | } |
2726 | |
2727 | // int32 monitoring_level = 2; |
2728 | if (this->monitoring_level() != 0) { |
2729 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteInt32ToArray(2, this->monitoring_level(), target); |
2730 | } |
2731 | |
2732 | // bool timestamp = 3; |
2733 | if (this->timestamp() != 0) { |
2734 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteBoolToArray(3, this->timestamp(), target); |
2735 | } |
2736 | |
2737 | if (_internal_metadata_.have_unknown_fields()) { |
2738 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
2739 | _internal_metadata_.unknown_fields(), target); |
2740 | } |
2741 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.MonitorRequest) |
2742 | return target; |
2743 | } |
2744 | |
2745 | size_t MonitorRequest::ByteSizeLong() const { |
2746 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.MonitorRequest) |
2747 | size_t total_size = 0; |
2748 | |
2749 | if (_internal_metadata_.have_unknown_fields()) { |
2750 | total_size += |
2751 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
2752 | _internal_metadata_.unknown_fields()); |
2753 | } |
2754 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2755 | // Prevent compiler warnings about cached_has_bits being unused |
2756 | (void) cached_has_bits; |
2757 | |
2758 | // uint64 duration_ms = 1; |
2759 | if (this->duration_ms() != 0) { |
2760 | total_size += 1 + |
2761 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::UInt64Size( |
2762 | this->duration_ms()); |
2763 | } |
2764 | |
2765 | // int32 monitoring_level = 2; |
2766 | if (this->monitoring_level() != 0) { |
2767 | total_size += 1 + |
2768 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::Int32Size( |
2769 | this->monitoring_level()); |
2770 | } |
2771 | |
2772 | // bool timestamp = 3; |
2773 | if (this->timestamp() != 0) { |
2774 | total_size += 1 + 1; |
2775 | } |
2776 | |
2777 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
2778 | SetCachedSize(cached_size); |
2779 | return total_size; |
2780 | } |
2781 | |
2782 | void MonitorRequest::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2783 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.MonitorRequest) |
2784 | GOOGLE_DCHECK_NE(&from, this); |
2785 | const MonitorRequest* source = |
2786 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<MonitorRequest>( |
2787 | &from); |
2788 | if (source == nullptr) { |
2789 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.MonitorRequest) |
2790 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
2791 | } else { |
2792 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.MonitorRequest) |
2793 | MergeFrom(*source); |
2794 | } |
2795 | } |
2796 | |
2797 | void MonitorRequest::MergeFrom(const MonitorRequest& from) { |
2798 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.MonitorRequest) |
2799 | GOOGLE_DCHECK_NE(&from, this); |
2800 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2801 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2802 | (void) cached_has_bits; |
2803 | |
2804 | if (from.duration_ms() != 0) { |
2805 | set_duration_ms(from.duration_ms()); |
2806 | } |
2807 | if (from.monitoring_level() != 0) { |
2808 | set_monitoring_level(from.monitoring_level()); |
2809 | } |
2810 | if (from.timestamp() != 0) { |
2811 | set_timestamp(from.timestamp()); |
2812 | } |
2813 | } |
2814 | |
2815 | void MonitorRequest::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
2816 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.MonitorRequest) |
2817 | if (&from == this) return; |
2818 | Clear(); |
2819 | MergeFrom(from); |
2820 | } |
2821 | |
2822 | void MonitorRequest::CopyFrom(const MonitorRequest& from) { |
2823 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.MonitorRequest) |
2824 | if (&from == this) return; |
2825 | Clear(); |
2826 | MergeFrom(from); |
2827 | } |
2828 | |
2829 | bool MonitorRequest::IsInitialized() const { |
2830 | return true; |
2831 | } |
2832 | |
2833 | void MonitorRequest::InternalSwap(MonitorRequest* other) { |
2834 | using std::swap; |
2835 | _internal_metadata_.Swap(&other->_internal_metadata_); |
2836 | swap(duration_ms_, other->duration_ms_); |
2837 | swap(monitoring_level_, other->monitoring_level_); |
2838 | swap(timestamp_, other->timestamp_); |
2839 | } |
2840 | |
2841 | ::PROTOBUF_NAMESPACE_ID::Metadata MonitorRequest::GetMetadata() const { |
2842 | return GetMetadataStatic(); |
2843 | } |
2844 | |
2845 | |
2846 | // =================================================================== |
2847 | |
2848 | void MonitorResponse::InitAsDefaultInstance() { |
2849 | ::tensorflow::_MonitorResponse_default_instance_._instance.get_mutable()->monitor_result_ = const_cast< ::tensorflow::ProfilerServiceMonitorResult*>( |
2850 | ::tensorflow::ProfilerServiceMonitorResult::internal_default_instance()); |
2851 | } |
2852 | class MonitorResponse::_Internal { |
2853 | public: |
2854 | static const ::tensorflow::ProfilerServiceMonitorResult& monitor_result(const MonitorResponse* msg); |
2855 | }; |
2856 | |
2857 | const ::tensorflow::ProfilerServiceMonitorResult& |
2858 | MonitorResponse::_Internal::monitor_result(const MonitorResponse* msg) { |
2859 | return *msg->monitor_result_; |
2860 | } |
2861 | void MonitorResponse::clear_monitor_result() { |
2862 | if (GetArenaNoVirtual() == nullptr && monitor_result_ != nullptr) { |
2863 | delete monitor_result_; |
2864 | } |
2865 | monitor_result_ = nullptr; |
2866 | } |
2867 | MonitorResponse::MonitorResponse() |
2868 | : ::PROTOBUF_NAMESPACE_ID::Message(), _internal_metadata_(nullptr) { |
2869 | SharedCtor(); |
2870 | // @@protoc_insertion_point(constructor:tensorflow.MonitorResponse) |
2871 | } |
2872 | MonitorResponse::MonitorResponse(const MonitorResponse& from) |
2873 | : ::PROTOBUF_NAMESPACE_ID::Message(), |
2874 | _internal_metadata_(nullptr) { |
2875 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
2876 | data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2877 | if (!from.data().empty()) { |
2878 | data_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.data_); |
2879 | } |
2880 | if (from.has_monitor_result()) { |
2881 | monitor_result_ = new ::tensorflow::ProfilerServiceMonitorResult(*from.monitor_result_); |
2882 | } else { |
2883 | monitor_result_ = nullptr; |
2884 | } |
2885 | // @@protoc_insertion_point(copy_constructor:tensorflow.MonitorResponse) |
2886 | } |
2887 | |
2888 | void MonitorResponse::SharedCtor() { |
2889 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&scc_info_MonitorResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
2890 | data_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2891 | monitor_result_ = nullptr; |
2892 | } |
2893 | |
2894 | MonitorResponse::~MonitorResponse() { |
2895 | // @@protoc_insertion_point(destructor:tensorflow.MonitorResponse) |
2896 | SharedDtor(); |
2897 | } |
2898 | |
2899 | void MonitorResponse::SharedDtor() { |
2900 | data_.DestroyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2901 | if (this != internal_default_instance()) delete monitor_result_; |
2902 | } |
2903 | |
2904 | void MonitorResponse::SetCachedSize(int size) const { |
2905 | _cached_size_.Set(size); |
2906 | } |
2907 | const MonitorResponse& MonitorResponse::default_instance() { |
2908 | ::PROTOBUF_NAMESPACE_ID::internal::InitSCC(&::scc_info_MonitorResponse_tensorflow_2fcore_2fprofiler_2fprofiler_5fservice_2eproto.base); |
2909 | return *internal_default_instance(); |
2910 | } |
2911 | |
2912 | |
2913 | void MonitorResponse::Clear() { |
2914 | // @@protoc_insertion_point(message_clear_start:tensorflow.MonitorResponse) |
2915 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
2916 | // Prevent compiler warnings about cached_has_bits being unused |
2917 | (void) cached_has_bits; |
2918 | |
2919 | data_.ClearToEmptyNoArena(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); |
2920 | if (GetArenaNoVirtual() == nullptr && monitor_result_ != nullptr) { |
2921 | delete monitor_result_; |
2922 | } |
2923 | monitor_result_ = nullptr; |
2924 | _internal_metadata_.Clear(); |
2925 | } |
2926 | |
2927 | #if GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2928 | const char* MonitorResponse::_InternalParse(const char* ptr, ::PROTOBUF_NAMESPACE_ID::internal::ParseContext* ctx) { |
2929 | #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure |
2930 | while (!ctx->Done(&ptr)) { |
2931 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2932 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::ReadTag(ptr, &tag); |
2933 | CHK_(ptr); |
2934 | switch (tag >> 3) { |
2935 | // string data = 1; |
2936 | case 1: |
2937 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 10)) { |
2938 | ptr = ::PROTOBUF_NAMESPACE_ID::internal::InlineGreedyStringParserUTF8(mutable_data(), ptr, ctx, "tensorflow.MonitorResponse.data" ); |
2939 | CHK_(ptr); |
2940 | } else goto handle_unusual; |
2941 | continue; |
2942 | // .tensorflow.ProfilerServiceMonitorResult monitor_result = 10; |
2943 | case 10: |
2944 | if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 82)) { |
2945 | ptr = ctx->ParseMessage(mutable_monitor_result(), ptr); |
2946 | CHK_(ptr); |
2947 | } else goto handle_unusual; |
2948 | continue; |
2949 | default: { |
2950 | handle_unusual: |
2951 | if ((tag & 7) == 4 || tag == 0) { |
2952 | ctx->SetLastTag(tag); |
2953 | goto success; |
2954 | } |
2955 | ptr = UnknownFieldParse(tag, &_internal_metadata_, ptr, ctx); |
2956 | CHK_(ptr != nullptr); |
2957 | continue; |
2958 | } |
2959 | } // switch |
2960 | } // while |
2961 | success: |
2962 | return ptr; |
2963 | failure: |
2964 | ptr = nullptr; |
2965 | goto success; |
2966 | #undef CHK_ |
2967 | } |
2968 | #else // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
2969 | bool MonitorResponse::MergePartialFromCodedStream( |
2970 | ::PROTOBUF_NAMESPACE_ID::io::CodedInputStream* input) { |
2971 | #define DO_(EXPRESSION) if (!PROTOBUF_PREDICT_TRUE(EXPRESSION)) goto failure |
2972 | ::PROTOBUF_NAMESPACE_ID::uint32 tag; |
2973 | // @@protoc_insertion_point(parse_start:tensorflow.MonitorResponse) |
2974 | for (;;) { |
2975 | ::std::pair<::PROTOBUF_NAMESPACE_ID::uint32, bool> p = input->ReadTagWithCutoffNoLastTag(127u); |
2976 | tag = p.first; |
2977 | if (!p.second) goto handle_unusual; |
2978 | switch (::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::GetTagFieldNumber(tag)) { |
2979 | // string data = 1; |
2980 | case 1: { |
2981 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (10 & 0xFF)) { |
2982 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadString( |
2983 | input, this->mutable_data())); |
2984 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
2985 | this->data().data(), static_cast<int>(this->data().length()), |
2986 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::PARSE, |
2987 | "tensorflow.MonitorResponse.data" )); |
2988 | } else { |
2989 | goto handle_unusual; |
2990 | } |
2991 | break; |
2992 | } |
2993 | |
2994 | // .tensorflow.ProfilerServiceMonitorResult monitor_result = 10; |
2995 | case 10: { |
2996 | if (static_cast< ::PROTOBUF_NAMESPACE_ID::uint8>(tag) == (82 & 0xFF)) { |
2997 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::ReadMessage( |
2998 | input, mutable_monitor_result())); |
2999 | } else { |
3000 | goto handle_unusual; |
3001 | } |
3002 | break; |
3003 | } |
3004 | |
3005 | default: { |
3006 | handle_unusual: |
3007 | if (tag == 0) { |
3008 | goto success; |
3009 | } |
3010 | DO_(::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SkipField( |
3011 | input, tag, _internal_metadata_.mutable_unknown_fields())); |
3012 | break; |
3013 | } |
3014 | } |
3015 | } |
3016 | success: |
3017 | // @@protoc_insertion_point(parse_success:tensorflow.MonitorResponse) |
3018 | return true; |
3019 | failure: |
3020 | // @@protoc_insertion_point(parse_failure:tensorflow.MonitorResponse) |
3021 | return false; |
3022 | #undef DO_ |
3023 | } |
3024 | #endif // GOOGLE_PROTOBUF_ENABLE_EXPERIMENTAL_PARSER |
3025 | |
3026 | void MonitorResponse::SerializeWithCachedSizes( |
3027 | ::PROTOBUF_NAMESPACE_ID::io::CodedOutputStream* output) const { |
3028 | // @@protoc_insertion_point(serialize_start:tensorflow.MonitorResponse) |
3029 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
3030 | (void) cached_has_bits; |
3031 | |
3032 | // string data = 1; |
3033 | if (this->data().size() > 0) { |
3034 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
3035 | this->data().data(), static_cast<int>(this->data().length()), |
3036 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
3037 | "tensorflow.MonitorResponse.data" ); |
3038 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringMaybeAliased( |
3039 | 1, this->data(), output); |
3040 | } |
3041 | |
3042 | // .tensorflow.ProfilerServiceMonitorResult monitor_result = 10; |
3043 | if (this->has_monitor_result()) { |
3044 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteMessageMaybeToArray( |
3045 | 10, _Internal::monitor_result(this), output); |
3046 | } |
3047 | |
3048 | if (_internal_metadata_.have_unknown_fields()) { |
3049 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFields( |
3050 | _internal_metadata_.unknown_fields(), output); |
3051 | } |
3052 | // @@protoc_insertion_point(serialize_end:tensorflow.MonitorResponse) |
3053 | } |
3054 | |
3055 | ::PROTOBUF_NAMESPACE_ID::uint8* MonitorResponse::InternalSerializeWithCachedSizesToArray( |
3056 | ::PROTOBUF_NAMESPACE_ID::uint8* target) const { |
3057 | // @@protoc_insertion_point(serialize_to_array_start:tensorflow.MonitorResponse) |
3058 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
3059 | (void) cached_has_bits; |
3060 | |
3061 | // string data = 1; |
3062 | if (this->data().size() > 0) { |
3063 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::VerifyUtf8String( |
3064 | this->data().data(), static_cast<int>(this->data().length()), |
3065 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::SERIALIZE, |
3066 | "tensorflow.MonitorResponse.data" ); |
3067 | target = |
3068 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteStringToArray( |
3069 | 1, this->data(), target); |
3070 | } |
3071 | |
3072 | // .tensorflow.ProfilerServiceMonitorResult monitor_result = 10; |
3073 | if (this->has_monitor_result()) { |
3074 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite:: |
3075 | InternalWriteMessageToArray( |
3076 | 10, _Internal::monitor_result(this), target); |
3077 | } |
3078 | |
3079 | if (_internal_metadata_.have_unknown_fields()) { |
3080 | target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SerializeUnknownFieldsToArray( |
3081 | _internal_metadata_.unknown_fields(), target); |
3082 | } |
3083 | // @@protoc_insertion_point(serialize_to_array_end:tensorflow.MonitorResponse) |
3084 | return target; |
3085 | } |
3086 | |
3087 | size_t MonitorResponse::ByteSizeLong() const { |
3088 | // @@protoc_insertion_point(message_byte_size_start:tensorflow.MonitorResponse) |
3089 | size_t total_size = 0; |
3090 | |
3091 | if (_internal_metadata_.have_unknown_fields()) { |
3092 | total_size += |
3093 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::ComputeUnknownFieldsSize( |
3094 | _internal_metadata_.unknown_fields()); |
3095 | } |
3096 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
3097 | // Prevent compiler warnings about cached_has_bits being unused |
3098 | (void) cached_has_bits; |
3099 | |
3100 | // string data = 1; |
3101 | if (this->data().size() > 0) { |
3102 | total_size += 1 + |
3103 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize( |
3104 | this->data()); |
3105 | } |
3106 | |
3107 | // .tensorflow.ProfilerServiceMonitorResult monitor_result = 10; |
3108 | if (this->has_monitor_result()) { |
3109 | total_size += 1 + |
3110 | ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize( |
3111 | *monitor_result_); |
3112 | } |
3113 | |
3114 | int cached_size = ::PROTOBUF_NAMESPACE_ID::internal::ToCachedSize(total_size); |
3115 | SetCachedSize(cached_size); |
3116 | return total_size; |
3117 | } |
3118 | |
3119 | void MonitorResponse::MergeFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
3120 | // @@protoc_insertion_point(generalized_merge_from_start:tensorflow.MonitorResponse) |
3121 | GOOGLE_DCHECK_NE(&from, this); |
3122 | const MonitorResponse* source = |
3123 | ::PROTOBUF_NAMESPACE_ID::DynamicCastToGenerated<MonitorResponse>( |
3124 | &from); |
3125 | if (source == nullptr) { |
3126 | // @@protoc_insertion_point(generalized_merge_from_cast_fail:tensorflow.MonitorResponse) |
3127 | ::PROTOBUF_NAMESPACE_ID::internal::ReflectionOps::Merge(from, this); |
3128 | } else { |
3129 | // @@protoc_insertion_point(generalized_merge_from_cast_success:tensorflow.MonitorResponse) |
3130 | MergeFrom(*source); |
3131 | } |
3132 | } |
3133 | |
3134 | void MonitorResponse::MergeFrom(const MonitorResponse& from) { |
3135 | // @@protoc_insertion_point(class_specific_merge_from_start:tensorflow.MonitorResponse) |
3136 | GOOGLE_DCHECK_NE(&from, this); |
3137 | _internal_metadata_.MergeFrom(from._internal_metadata_); |
3138 | ::PROTOBUF_NAMESPACE_ID::uint32 cached_has_bits = 0; |
3139 | (void) cached_has_bits; |
3140 | |
3141 | if (from.data().size() > 0) { |
3142 | |
3143 | data_.AssignWithDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), from.data_); |
3144 | } |
3145 | if (from.has_monitor_result()) { |
3146 | mutable_monitor_result()->::tensorflow::ProfilerServiceMonitorResult::MergeFrom(from.monitor_result()); |
3147 | } |
3148 | } |
3149 | |
3150 | void MonitorResponse::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { |
3151 | // @@protoc_insertion_point(generalized_copy_from_start:tensorflow.MonitorResponse) |
3152 | if (&from == this) return; |
3153 | Clear(); |
3154 | MergeFrom(from); |
3155 | } |
3156 | |
3157 | void MonitorResponse::CopyFrom(const MonitorResponse& from) { |
3158 | // @@protoc_insertion_point(class_specific_copy_from_start:tensorflow.MonitorResponse) |
3159 | if (&from == this) return; |
3160 | Clear(); |
3161 | MergeFrom(from); |
3162 | } |
3163 | |
3164 | bool MonitorResponse::IsInitialized() const { |
3165 | return true; |
3166 | } |
3167 | |
3168 | void MonitorResponse::InternalSwap(MonitorResponse* other) { |
3169 | using std::swap; |
3170 | _internal_metadata_.Swap(&other->_internal_metadata_); |
3171 | data_.Swap(&other->data_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), |
3172 | GetArenaNoVirtual()); |
3173 | swap(monitor_result_, other->monitor_result_); |
3174 | } |
3175 | |
3176 | ::PROTOBUF_NAMESPACE_ID::Metadata MonitorResponse::GetMetadata() const { |
3177 | return GetMetadataStatic(); |
3178 | } |
3179 | |
3180 | |
3181 | // @@protoc_insertion_point(namespace_scope) |
3182 | } // namespace tensorflow |
3183 | PROTOBUF_NAMESPACE_OPEN |
3184 | template<> PROTOBUF_NOINLINE ::tensorflow::ToolRequestOptions* Arena::CreateMaybeMessage< ::tensorflow::ToolRequestOptions >(Arena* arena) { |
3185 | return Arena::CreateInternal< ::tensorflow::ToolRequestOptions >(arena); |
3186 | } |
3187 | template<> PROTOBUF_NOINLINE ::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse* Arena::CreateMaybeMessage< ::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse >(Arena* arena) { |
3188 | return Arena::CreateInternal< ::tensorflow::ProfileRequest_ToolOptionsEntry_DoNotUse >(arena); |
3189 | } |
3190 | template<> PROTOBUF_NOINLINE ::tensorflow::ProfileRequest* Arena::CreateMaybeMessage< ::tensorflow::ProfileRequest >(Arena* arena) { |
3191 | return Arena::CreateInternal< ::tensorflow::ProfileRequest >(arena); |
3192 | } |
3193 | template<> PROTOBUF_NOINLINE ::tensorflow::ProfileToolData* Arena::CreateMaybeMessage< ::tensorflow::ProfileToolData >(Arena* arena) { |
3194 | return Arena::CreateInternal< ::tensorflow::ProfileToolData >(arena); |
3195 | } |
3196 | template<> PROTOBUF_NOINLINE ::tensorflow::ProfileResponse* Arena::CreateMaybeMessage< ::tensorflow::ProfileResponse >(Arena* arena) { |
3197 | return Arena::CreateInternal< ::tensorflow::ProfileResponse >(arena); |
3198 | } |
3199 | template<> PROTOBUF_NOINLINE ::tensorflow::TerminateRequest* Arena::CreateMaybeMessage< ::tensorflow::TerminateRequest >(Arena* arena) { |
3200 | return Arena::CreateInternal< ::tensorflow::TerminateRequest >(arena); |
3201 | } |
3202 | template<> PROTOBUF_NOINLINE ::tensorflow::TerminateResponse* Arena::CreateMaybeMessage< ::tensorflow::TerminateResponse >(Arena* arena) { |
3203 | return Arena::CreateInternal< ::tensorflow::TerminateResponse >(arena); |
3204 | } |
3205 | template<> PROTOBUF_NOINLINE ::tensorflow::MonitorRequest* Arena::CreateMaybeMessage< ::tensorflow::MonitorRequest >(Arena* arena) { |
3206 | return Arena::CreateInternal< ::tensorflow::MonitorRequest >(arena); |
3207 | } |
3208 | template<> PROTOBUF_NOINLINE ::tensorflow::MonitorResponse* Arena::CreateMaybeMessage< ::tensorflow::MonitorResponse >(Arena* arena) { |
3209 | return Arena::CreateInternal< ::tensorflow::MonitorResponse >(arena); |
3210 | } |
3211 | PROTOBUF_NAMESPACE_CLOSE |
3212 | |
3213 | // @@protoc_insertion_point(global_scope) |
3214 | #include <google/protobuf/port_undef.inc> |
3215 | |