1 // Generated by the protocol buffer compiler. DO NOT EDIT!
2 // source: protos/perfetto/trace/track_event/chrome_compositor_scheduler_state.proto
3
4 #include "protos/perfetto/trace/track_event/chrome_compositor_scheduler_state.pb.h"
5
6 #include <algorithm>
7 #include <cstdint>
8
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/io/zero_copy_stream_impl_lite.h>
13 // @@protoc_insertion_point(includes)
14 #include <google/protobuf/port_def.inc>
15
16 PROTOBUF_PRAGMA_INIT_SEG
17
18 namespace _pb = ::PROTOBUF_NAMESPACE_ID;
19 namespace _pbi = _pb::internal;
20
21 namespace perfetto {
22 namespace protos {
ChromeCompositorSchedulerState(::_pbi::ConstantInitialized)23 PROTOBUF_CONSTEXPR ChromeCompositorSchedulerState::ChromeCompositorSchedulerState(
24 ::_pbi::ConstantInitialized): _impl_{
25 /*decltype(_impl_._has_bits_)*/{}
26 , /*decltype(_impl_._cached_size_)*/{}
27 , /*decltype(_impl_.state_machine_)*/nullptr
28 , /*decltype(_impl_.begin_impl_frame_args_)*/nullptr
29 , /*decltype(_impl_.begin_frame_observer_state_)*/nullptr
30 , /*decltype(_impl_.begin_frame_source_state_)*/nullptr
31 , /*decltype(_impl_.compositor_timing_history_)*/nullptr
32 , /*decltype(_impl_.observing_begin_frame_source_)*/false
33 , /*decltype(_impl_.begin_impl_frame_deadline_task_)*/false
34 , /*decltype(_impl_.pending_begin_frame_task_)*/false
35 , /*decltype(_impl_.skipped_last_frame_missed_exceeded_deadline_)*/false
36 , /*decltype(_impl_.inside_action_)*/0
37 , /*decltype(_impl_.deadline_us_)*/::int64_t{0}
38 , /*decltype(_impl_.deadline_scheduled_at_us_)*/::int64_t{0}
39 , /*decltype(_impl_.now_us_)*/::int64_t{0}
40 , /*decltype(_impl_.now_to_deadline_delta_us_)*/::int64_t{0}
41 , /*decltype(_impl_.now_to_deadline_scheduled_at_delta_us_)*/::int64_t{0}
42 , /*decltype(_impl_.deadline_mode_)*/0} {}
43 struct ChromeCompositorSchedulerStateDefaultTypeInternal {
ChromeCompositorSchedulerStateDefaultTypeInternalperfetto::protos::ChromeCompositorSchedulerStateDefaultTypeInternal44 PROTOBUF_CONSTEXPR ChromeCompositorSchedulerStateDefaultTypeInternal()
45 : _instance(::_pbi::ConstantInitialized{}) {}
~ChromeCompositorSchedulerStateDefaultTypeInternalperfetto::protos::ChromeCompositorSchedulerStateDefaultTypeInternal46 ~ChromeCompositorSchedulerStateDefaultTypeInternal() {}
47 union { // NOLINT(misc-non-private-member-variables-in-classes)
48 ChromeCompositorSchedulerState _instance;
49 };
50 };
51 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ChromeCompositorSchedulerStateDefaultTypeInternal _ChromeCompositorSchedulerState_default_instance_;
ChromeCompositorStateMachine_MajorState(::_pbi::ConstantInitialized)52 PROTOBUF_CONSTEXPR ChromeCompositorStateMachine_MajorState::ChromeCompositorStateMachine_MajorState(
53 ::_pbi::ConstantInitialized): _impl_{
54 /*decltype(_impl_._has_bits_)*/{}
55 , /*decltype(_impl_._cached_size_)*/{}
56 , /*decltype(_impl_.next_action_)*/0
57 , /*decltype(_impl_.begin_impl_frame_state_)*/0
58 , /*decltype(_impl_.begin_main_frame_state_)*/0
59 , /*decltype(_impl_.layer_tree_frame_sink_state_)*/0
60 , /*decltype(_impl_.forced_redraw_state_)*/0} {}
61 struct ChromeCompositorStateMachine_MajorStateDefaultTypeInternal {
ChromeCompositorStateMachine_MajorStateDefaultTypeInternalperfetto::protos::ChromeCompositorStateMachine_MajorStateDefaultTypeInternal62 PROTOBUF_CONSTEXPR ChromeCompositorStateMachine_MajorStateDefaultTypeInternal()
63 : _instance(::_pbi::ConstantInitialized{}) {}
~ChromeCompositorStateMachine_MajorStateDefaultTypeInternalperfetto::protos::ChromeCompositorStateMachine_MajorStateDefaultTypeInternal64 ~ChromeCompositorStateMachine_MajorStateDefaultTypeInternal() {}
65 union { // NOLINT(misc-non-private-member-variables-in-classes)
66 ChromeCompositorStateMachine_MajorState _instance;
67 };
68 };
69 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ChromeCompositorStateMachine_MajorStateDefaultTypeInternal _ChromeCompositorStateMachine_MajorState_default_instance_;
ChromeCompositorStateMachine_MinorState(::_pbi::ConstantInitialized)70 PROTOBUF_CONSTEXPR ChromeCompositorStateMachine_MinorState::ChromeCompositorStateMachine_MinorState(
71 ::_pbi::ConstantInitialized): _impl_{
72 /*decltype(_impl_._has_bits_)*/{}
73 , /*decltype(_impl_._cached_size_)*/{}
74 , /*decltype(_impl_.commit_count_)*/0
75 , /*decltype(_impl_.current_frame_number_)*/0
76 , /*decltype(_impl_.last_frame_number_submit_performed_)*/0
77 , /*decltype(_impl_.last_frame_number_draw_performed_)*/0
78 , /*decltype(_impl_.last_frame_number_begin_main_frame_sent_)*/0
79 , /*decltype(_impl_.did_draw_)*/false
80 , /*decltype(_impl_.did_send_begin_main_frame_for_current_frame_)*/false
81 , /*decltype(_impl_.did_notify_begin_main_frame_not_expected_until_)*/false
82 , /*decltype(_impl_.did_notify_begin_main_frame_not_expected_soon_)*/false
83 , /*decltype(_impl_.wants_begin_main_frame_not_expected_)*/false
84 , /*decltype(_impl_.did_commit_during_frame_)*/false
85 , /*decltype(_impl_.did_invalidate_layer_tree_frame_sink_)*/false
86 , /*decltype(_impl_.did_perform_impl_side_invalidaion_)*/false
87 , /*decltype(_impl_.consecutive_checkerboard_animations_)*/0
88 , /*decltype(_impl_.pending_submit_frames_)*/0
89 , /*decltype(_impl_.submit_frames_with_current_layer_tree_frame_sink_)*/0
90 , /*decltype(_impl_.did_prepare_tiles_)*/false
91 , /*decltype(_impl_.needs_redraw_)*/false
92 , /*decltype(_impl_.needs_prepare_tiles_)*/false
93 , /*decltype(_impl_.needs_begin_main_frame_)*/false
94 , /*decltype(_impl_.needs_one_begin_impl_frame_)*/false
95 , /*decltype(_impl_.visible_)*/false
96 , /*decltype(_impl_.begin_frame_source_paused_)*/false
97 , /*decltype(_impl_.can_draw_)*/false
98 , /*decltype(_impl_.resourceless_draw_)*/false
99 , /*decltype(_impl_.has_pending_tree_)*/false
100 , /*decltype(_impl_.pending_tree_is_ready_for_activation_)*/false
101 , /*decltype(_impl_.active_tree_needs_first_draw_)*/false
102 , /*decltype(_impl_.tree_priority_)*/0
103 , /*decltype(_impl_.active_tree_is_ready_to_draw_)*/false
104 , /*decltype(_impl_.did_create_and_initialize_first_layer_tree_frame_sink_)*/false
105 , /*decltype(_impl_.critical_begin_main_frame_to_activate_is_fast_)*/false
106 , /*decltype(_impl_.main_thread_missed_last_deadline_)*/false
107 , /*decltype(_impl_.scroll_handler_state_)*/0
108 , /*decltype(_impl_.video_needs_begin_frames_)*/false
109 , /*decltype(_impl_.defer_begin_main_frame_)*/false
110 , /*decltype(_impl_.last_commit_had_no_updates_)*/false
111 , /*decltype(_impl_.did_draw_in_last_frame_)*/false
112 , /*decltype(_impl_.did_submit_in_last_frame_)*/false
113 , /*decltype(_impl_.needs_impl_side_invalidation_)*/false
114 , /*decltype(_impl_.current_pending_tree_is_impl_side_)*/false
115 , /*decltype(_impl_.previous_pending_tree_was_impl_side_)*/false
116 , /*decltype(_impl_.processing_animation_worklets_for_active_tree_)*/false
117 , /*decltype(_impl_.processing_animation_worklets_for_pending_tree_)*/false
118 , /*decltype(_impl_.processing_paint_worklets_for_pending_tree_)*/false} {}
119 struct ChromeCompositorStateMachine_MinorStateDefaultTypeInternal {
ChromeCompositorStateMachine_MinorStateDefaultTypeInternalperfetto::protos::ChromeCompositorStateMachine_MinorStateDefaultTypeInternal120 PROTOBUF_CONSTEXPR ChromeCompositorStateMachine_MinorStateDefaultTypeInternal()
121 : _instance(::_pbi::ConstantInitialized{}) {}
~ChromeCompositorStateMachine_MinorStateDefaultTypeInternalperfetto::protos::ChromeCompositorStateMachine_MinorStateDefaultTypeInternal122 ~ChromeCompositorStateMachine_MinorStateDefaultTypeInternal() {}
123 union { // NOLINT(misc-non-private-member-variables-in-classes)
124 ChromeCompositorStateMachine_MinorState _instance;
125 };
126 };
127 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ChromeCompositorStateMachine_MinorStateDefaultTypeInternal _ChromeCompositorStateMachine_MinorState_default_instance_;
ChromeCompositorStateMachine(::_pbi::ConstantInitialized)128 PROTOBUF_CONSTEXPR ChromeCompositorStateMachine::ChromeCompositorStateMachine(
129 ::_pbi::ConstantInitialized): _impl_{
130 /*decltype(_impl_._has_bits_)*/{}
131 , /*decltype(_impl_._cached_size_)*/{}
132 , /*decltype(_impl_.major_state_)*/nullptr
133 , /*decltype(_impl_.minor_state_)*/nullptr} {}
134 struct ChromeCompositorStateMachineDefaultTypeInternal {
ChromeCompositorStateMachineDefaultTypeInternalperfetto::protos::ChromeCompositorStateMachineDefaultTypeInternal135 PROTOBUF_CONSTEXPR ChromeCompositorStateMachineDefaultTypeInternal()
136 : _instance(::_pbi::ConstantInitialized{}) {}
~ChromeCompositorStateMachineDefaultTypeInternalperfetto::protos::ChromeCompositorStateMachineDefaultTypeInternal137 ~ChromeCompositorStateMachineDefaultTypeInternal() {}
138 union { // NOLINT(misc-non-private-member-variables-in-classes)
139 ChromeCompositorStateMachine _instance;
140 };
141 };
142 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 ChromeCompositorStateMachineDefaultTypeInternal _ChromeCompositorStateMachine_default_instance_;
BeginFrameArgs(::_pbi::ConstantInitialized)143 PROTOBUF_CONSTEXPR BeginFrameArgs::BeginFrameArgs(
144 ::_pbi::ConstantInitialized): _impl_{
145 /*decltype(_impl_._has_bits_)*/{}
146 , /*decltype(_impl_._cached_size_)*/{}
147 , /*decltype(_impl_.source_id_)*/::uint64_t{0u}
148 , /*decltype(_impl_.sequence_number_)*/::uint64_t{0u}
149 , /*decltype(_impl_.frame_time_us_)*/::int64_t{0}
150 , /*decltype(_impl_.deadline_us_)*/::int64_t{0}
151 , /*decltype(_impl_.type_)*/0
152 , /*decltype(_impl_.on_critical_path_)*/false
153 , /*decltype(_impl_.animate_only_)*/false
154 , /*decltype(_impl_.interval_delta_us_)*/::int64_t{0}
155 , /*decltype(_impl_.frames_throttled_since_last_)*/::int64_t{0}
156 , /*decltype(_impl_.created_from_)*/{}
157 , /*decltype(_impl_._oneof_case_)*/{}} {}
158 struct BeginFrameArgsDefaultTypeInternal {
BeginFrameArgsDefaultTypeInternalperfetto::protos::BeginFrameArgsDefaultTypeInternal159 PROTOBUF_CONSTEXPR BeginFrameArgsDefaultTypeInternal()
160 : _instance(::_pbi::ConstantInitialized{}) {}
~BeginFrameArgsDefaultTypeInternalperfetto::protos::BeginFrameArgsDefaultTypeInternal161 ~BeginFrameArgsDefaultTypeInternal() {}
162 union { // NOLINT(misc-non-private-member-variables-in-classes)
163 BeginFrameArgs _instance;
164 };
165 };
166 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 BeginFrameArgsDefaultTypeInternal _BeginFrameArgs_default_instance_;
BeginImplFrameArgs_TimestampsInUs(::_pbi::ConstantInitialized)167 PROTOBUF_CONSTEXPR BeginImplFrameArgs_TimestampsInUs::BeginImplFrameArgs_TimestampsInUs(
168 ::_pbi::ConstantInitialized): _impl_{
169 /*decltype(_impl_._has_bits_)*/{}
170 , /*decltype(_impl_._cached_size_)*/{}
171 , /*decltype(_impl_.interval_delta_)*/::int64_t{0}
172 , /*decltype(_impl_.now_to_deadline_delta_)*/::int64_t{0}
173 , /*decltype(_impl_.frame_time_to_now_delta_)*/::int64_t{0}
174 , /*decltype(_impl_.frame_time_to_deadline_delta_)*/::int64_t{0}
175 , /*decltype(_impl_.now_)*/::int64_t{0}
176 , /*decltype(_impl_.frame_time_)*/::int64_t{0}
177 , /*decltype(_impl_.deadline_)*/::int64_t{0}} {}
178 struct BeginImplFrameArgs_TimestampsInUsDefaultTypeInternal {
BeginImplFrameArgs_TimestampsInUsDefaultTypeInternalperfetto::protos::BeginImplFrameArgs_TimestampsInUsDefaultTypeInternal179 PROTOBUF_CONSTEXPR BeginImplFrameArgs_TimestampsInUsDefaultTypeInternal()
180 : _instance(::_pbi::ConstantInitialized{}) {}
~BeginImplFrameArgs_TimestampsInUsDefaultTypeInternalperfetto::protos::BeginImplFrameArgs_TimestampsInUsDefaultTypeInternal181 ~BeginImplFrameArgs_TimestampsInUsDefaultTypeInternal() {}
182 union { // NOLINT(misc-non-private-member-variables-in-classes)
183 BeginImplFrameArgs_TimestampsInUs _instance;
184 };
185 };
186 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 BeginImplFrameArgs_TimestampsInUsDefaultTypeInternal _BeginImplFrameArgs_TimestampsInUs_default_instance_;
BeginImplFrameArgs(::_pbi::ConstantInitialized)187 PROTOBUF_CONSTEXPR BeginImplFrameArgs::BeginImplFrameArgs(
188 ::_pbi::ConstantInitialized): _impl_{
189 /*decltype(_impl_._has_bits_)*/{}
190 , /*decltype(_impl_._cached_size_)*/{}
191 , /*decltype(_impl_.timestamps_in_us_)*/nullptr
192 , /*decltype(_impl_.updated_at_us_)*/::int64_t{0}
193 , /*decltype(_impl_.finished_at_us_)*/::int64_t{0}
194 , /*decltype(_impl_.state_)*/0
195 , /*decltype(_impl_.args_)*/{}
196 , /*decltype(_impl_._oneof_case_)*/{}} {}
197 struct BeginImplFrameArgsDefaultTypeInternal {
BeginImplFrameArgsDefaultTypeInternalperfetto::protos::BeginImplFrameArgsDefaultTypeInternal198 PROTOBUF_CONSTEXPR BeginImplFrameArgsDefaultTypeInternal()
199 : _instance(::_pbi::ConstantInitialized{}) {}
~BeginImplFrameArgsDefaultTypeInternalperfetto::protos::BeginImplFrameArgsDefaultTypeInternal200 ~BeginImplFrameArgsDefaultTypeInternal() {}
201 union { // NOLINT(misc-non-private-member-variables-in-classes)
202 BeginImplFrameArgs _instance;
203 };
204 };
205 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 BeginImplFrameArgsDefaultTypeInternal _BeginImplFrameArgs_default_instance_;
BeginFrameObserverState(::_pbi::ConstantInitialized)206 PROTOBUF_CONSTEXPR BeginFrameObserverState::BeginFrameObserverState(
207 ::_pbi::ConstantInitialized): _impl_{
208 /*decltype(_impl_._has_bits_)*/{}
209 , /*decltype(_impl_._cached_size_)*/{}
210 , /*decltype(_impl_.last_begin_frame_args_)*/nullptr
211 , /*decltype(_impl_.dropped_begin_frame_args_)*/::int64_t{0}} {}
212 struct BeginFrameObserverStateDefaultTypeInternal {
BeginFrameObserverStateDefaultTypeInternalperfetto::protos::BeginFrameObserverStateDefaultTypeInternal213 PROTOBUF_CONSTEXPR BeginFrameObserverStateDefaultTypeInternal()
214 : _instance(::_pbi::ConstantInitialized{}) {}
~BeginFrameObserverStateDefaultTypeInternalperfetto::protos::BeginFrameObserverStateDefaultTypeInternal215 ~BeginFrameObserverStateDefaultTypeInternal() {}
216 union { // NOLINT(misc-non-private-member-variables-in-classes)
217 BeginFrameObserverState _instance;
218 };
219 };
220 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 BeginFrameObserverStateDefaultTypeInternal _BeginFrameObserverState_default_instance_;
BeginFrameSourceState(::_pbi::ConstantInitialized)221 PROTOBUF_CONSTEXPR BeginFrameSourceState::BeginFrameSourceState(
222 ::_pbi::ConstantInitialized): _impl_{
223 /*decltype(_impl_._has_bits_)*/{}
224 , /*decltype(_impl_._cached_size_)*/{}
225 , /*decltype(_impl_.last_begin_frame_args_)*/nullptr
226 , /*decltype(_impl_.source_id_)*/0u
227 , /*decltype(_impl_.paused_)*/false
228 , /*decltype(_impl_.num_observers_)*/0u} {}
229 struct BeginFrameSourceStateDefaultTypeInternal {
BeginFrameSourceStateDefaultTypeInternalperfetto::protos::BeginFrameSourceStateDefaultTypeInternal230 PROTOBUF_CONSTEXPR BeginFrameSourceStateDefaultTypeInternal()
231 : _instance(::_pbi::ConstantInitialized{}) {}
~BeginFrameSourceStateDefaultTypeInternalperfetto::protos::BeginFrameSourceStateDefaultTypeInternal232 ~BeginFrameSourceStateDefaultTypeInternal() {}
233 union { // NOLINT(misc-non-private-member-variables-in-classes)
234 BeginFrameSourceState _instance;
235 };
236 };
237 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 BeginFrameSourceStateDefaultTypeInternal _BeginFrameSourceState_default_instance_;
CompositorTimingHistory(::_pbi::ConstantInitialized)238 PROTOBUF_CONSTEXPR CompositorTimingHistory::CompositorTimingHistory(
239 ::_pbi::ConstantInitialized): _impl_{
240 /*decltype(_impl_._has_bits_)*/{}
241 , /*decltype(_impl_._cached_size_)*/{}
242 , /*decltype(_impl_.begin_main_frame_queue_critical_estimate_delta_us_)*/::int64_t{0}
243 , /*decltype(_impl_.begin_main_frame_queue_not_critical_estimate_delta_us_)*/::int64_t{0}
244 , /*decltype(_impl_.begin_main_frame_start_to_ready_to_commit_estimate_delta_us_)*/::int64_t{0}
245 , /*decltype(_impl_.commit_to_ready_to_activate_estimate_delta_us_)*/::int64_t{0}
246 , /*decltype(_impl_.prepare_tiles_estimate_delta_us_)*/::int64_t{0}
247 , /*decltype(_impl_.activate_estimate_delta_us_)*/::int64_t{0}
248 , /*decltype(_impl_.draw_estimate_delta_us_)*/::int64_t{0}} {}
249 struct CompositorTimingHistoryDefaultTypeInternal {
CompositorTimingHistoryDefaultTypeInternalperfetto::protos::CompositorTimingHistoryDefaultTypeInternal250 PROTOBUF_CONSTEXPR CompositorTimingHistoryDefaultTypeInternal()
251 : _instance(::_pbi::ConstantInitialized{}) {}
~CompositorTimingHistoryDefaultTypeInternalperfetto::protos::CompositorTimingHistoryDefaultTypeInternal252 ~CompositorTimingHistoryDefaultTypeInternal() {}
253 union { // NOLINT(misc-non-private-member-variables-in-classes)
254 CompositorTimingHistory _instance;
255 };
256 };
257 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 CompositorTimingHistoryDefaultTypeInternal _CompositorTimingHistory_default_instance_;
258 } // namespace protos
259 } // namespace perfetto
260 namespace perfetto {
261 namespace protos {
ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_IsValid(int value)262 bool ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_IsValid(int value) {
263 switch (value) {
264 case 0:
265 case 1:
266 case 2:
267 case 3:
268 case 4:
269 case 5:
270 return true;
271 default:
272 return false;
273 }
274 }
275
276 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_strings[6] = {};
277
278 static const char ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names[] =
279 "DEADLINE_MODE_BLOCKED"
280 "DEADLINE_MODE_IMMEDIATE"
281 "DEADLINE_MODE_LATE"
282 "DEADLINE_MODE_NONE"
283 "DEADLINE_MODE_REGULAR"
284 "DEADLINE_MODE_UNSPECIFIED";
285
286 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries[] = {
287 { {ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names + 0, 21}, 5 },
288 { {ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names + 21, 23}, 2 },
289 { {ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names + 44, 18}, 4 },
290 { {ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names + 62, 18}, 1 },
291 { {ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names + 80, 21}, 3 },
292 { {ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_names + 101, 25}, 0 },
293 };
294
295 static const int ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries_by_number[] = {
296 5, // 0 -> DEADLINE_MODE_UNSPECIFIED
297 3, // 1 -> DEADLINE_MODE_NONE
298 1, // 2 -> DEADLINE_MODE_IMMEDIATE
299 4, // 3 -> DEADLINE_MODE_REGULAR
300 2, // 4 -> DEADLINE_MODE_LATE
301 0, // 5 -> DEADLINE_MODE_BLOCKED
302 };
303
ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_Name(ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode value)304 const std::string& ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_Name(
305 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode value) {
306 static const bool dummy =
307 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
308 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries,
309 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries_by_number,
310 6, ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_strings);
311 (void) dummy;
312 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
313 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries,
314 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries_by_number,
315 6, value);
316 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
317 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_strings[idx].get();
318 }
ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode * value)319 bool ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_Parse(
320 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode* value) {
321 int int_value;
322 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
323 ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_entries, 6, name, &int_value);
324 if (success) {
325 *value = static_cast<ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode>(int_value);
326 }
327 return success;
328 }
329 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
330 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::DEADLINE_MODE_UNSPECIFIED;
331 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::DEADLINE_MODE_NONE;
332 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::DEADLINE_MODE_IMMEDIATE;
333 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::DEADLINE_MODE_REGULAR;
334 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::DEADLINE_MODE_LATE;
335 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::DEADLINE_MODE_BLOCKED;
336 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::BeginImplFrameDeadlineMode_MIN;
337 constexpr ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode ChromeCompositorSchedulerState::BeginImplFrameDeadlineMode_MAX;
338 constexpr int ChromeCompositorSchedulerState::BeginImplFrameDeadlineMode_ARRAYSIZE;
339 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorStateMachine_MajorState_BeginImplFrameState_IsValid(int value)340 bool ChromeCompositorStateMachine_MajorState_BeginImplFrameState_IsValid(int value) {
341 switch (value) {
342 case 0:
343 case 1:
344 case 2:
345 case 3:
346 return true;
347 default:
348 return false;
349 }
350 }
351
352 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorStateMachine_MajorState_BeginImplFrameState_strings[4] = {};
353
354 static const char ChromeCompositorStateMachine_MajorState_BeginImplFrameState_names[] =
355 "BEGIN_IMPL_FRAME_IDLE"
356 "BEGIN_IMPL_FRAME_INSIDE_BEGIN_FRAME"
357 "BEGIN_IMPL_FRAME_INSIDE_DEADLINE"
358 "BEGIN_IMPL_FRAME_UNSPECIFIED";
359
360 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries[] = {
361 { {ChromeCompositorStateMachine_MajorState_BeginImplFrameState_names + 0, 21}, 1 },
362 { {ChromeCompositorStateMachine_MajorState_BeginImplFrameState_names + 21, 35}, 2 },
363 { {ChromeCompositorStateMachine_MajorState_BeginImplFrameState_names + 56, 32}, 3 },
364 { {ChromeCompositorStateMachine_MajorState_BeginImplFrameState_names + 88, 28}, 0 },
365 };
366
367 static const int ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries_by_number[] = {
368 3, // 0 -> BEGIN_IMPL_FRAME_UNSPECIFIED
369 0, // 1 -> BEGIN_IMPL_FRAME_IDLE
370 1, // 2 -> BEGIN_IMPL_FRAME_INSIDE_BEGIN_FRAME
371 2, // 3 -> BEGIN_IMPL_FRAME_INSIDE_DEADLINE
372 };
373
ChromeCompositorStateMachine_MajorState_BeginImplFrameState_Name(ChromeCompositorStateMachine_MajorState_BeginImplFrameState value)374 const std::string& ChromeCompositorStateMachine_MajorState_BeginImplFrameState_Name(
375 ChromeCompositorStateMachine_MajorState_BeginImplFrameState value) {
376 static const bool dummy =
377 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
378 ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries,
379 ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries_by_number,
380 4, ChromeCompositorStateMachine_MajorState_BeginImplFrameState_strings);
381 (void) dummy;
382 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
383 ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries,
384 ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries_by_number,
385 4, value);
386 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
387 ChromeCompositorStateMachine_MajorState_BeginImplFrameState_strings[idx].get();
388 }
ChromeCompositorStateMachine_MajorState_BeginImplFrameState_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorStateMachine_MajorState_BeginImplFrameState * value)389 bool ChromeCompositorStateMachine_MajorState_BeginImplFrameState_Parse(
390 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorStateMachine_MajorState_BeginImplFrameState* value) {
391 int int_value;
392 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
393 ChromeCompositorStateMachine_MajorState_BeginImplFrameState_entries, 4, name, &int_value);
394 if (success) {
395 *value = static_cast<ChromeCompositorStateMachine_MajorState_BeginImplFrameState>(int_value);
396 }
397 return success;
398 }
399 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
400 constexpr ChromeCompositorStateMachine_MajorState_BeginImplFrameState ChromeCompositorStateMachine_MajorState::BEGIN_IMPL_FRAME_UNSPECIFIED;
401 constexpr ChromeCompositorStateMachine_MajorState_BeginImplFrameState ChromeCompositorStateMachine_MajorState::BEGIN_IMPL_FRAME_IDLE;
402 constexpr ChromeCompositorStateMachine_MajorState_BeginImplFrameState ChromeCompositorStateMachine_MajorState::BEGIN_IMPL_FRAME_INSIDE_BEGIN_FRAME;
403 constexpr ChromeCompositorStateMachine_MajorState_BeginImplFrameState ChromeCompositorStateMachine_MajorState::BEGIN_IMPL_FRAME_INSIDE_DEADLINE;
404 constexpr ChromeCompositorStateMachine_MajorState_BeginImplFrameState ChromeCompositorStateMachine_MajorState::BeginImplFrameState_MIN;
405 constexpr ChromeCompositorStateMachine_MajorState_BeginImplFrameState ChromeCompositorStateMachine_MajorState::BeginImplFrameState_MAX;
406 constexpr int ChromeCompositorStateMachine_MajorState::BeginImplFrameState_ARRAYSIZE;
407 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorStateMachine_MajorState_BeginMainFrameState_IsValid(int value)408 bool ChromeCompositorStateMachine_MajorState_BeginMainFrameState_IsValid(int value) {
409 switch (value) {
410 case 0:
411 case 1:
412 case 2:
413 case 3:
414 return true;
415 default:
416 return false;
417 }
418 }
419
420 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorStateMachine_MajorState_BeginMainFrameState_strings[4] = {};
421
422 static const char ChromeCompositorStateMachine_MajorState_BeginMainFrameState_names[] =
423 "BEGIN_MAIN_FRAME_IDLE"
424 "BEGIN_MAIN_FRAME_READY_TO_COMMIT"
425 "BEGIN_MAIN_FRAME_SENT"
426 "BEGIN_MAIN_FRAME_UNSPECIFIED";
427
428 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries[] = {
429 { {ChromeCompositorStateMachine_MajorState_BeginMainFrameState_names + 0, 21}, 1 },
430 { {ChromeCompositorStateMachine_MajorState_BeginMainFrameState_names + 21, 32}, 3 },
431 { {ChromeCompositorStateMachine_MajorState_BeginMainFrameState_names + 53, 21}, 2 },
432 { {ChromeCompositorStateMachine_MajorState_BeginMainFrameState_names + 74, 28}, 0 },
433 };
434
435 static const int ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries_by_number[] = {
436 3, // 0 -> BEGIN_MAIN_FRAME_UNSPECIFIED
437 0, // 1 -> BEGIN_MAIN_FRAME_IDLE
438 2, // 2 -> BEGIN_MAIN_FRAME_SENT
439 1, // 3 -> BEGIN_MAIN_FRAME_READY_TO_COMMIT
440 };
441
ChromeCompositorStateMachine_MajorState_BeginMainFrameState_Name(ChromeCompositorStateMachine_MajorState_BeginMainFrameState value)442 const std::string& ChromeCompositorStateMachine_MajorState_BeginMainFrameState_Name(
443 ChromeCompositorStateMachine_MajorState_BeginMainFrameState value) {
444 static const bool dummy =
445 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
446 ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries,
447 ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries_by_number,
448 4, ChromeCompositorStateMachine_MajorState_BeginMainFrameState_strings);
449 (void) dummy;
450 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
451 ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries,
452 ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries_by_number,
453 4, value);
454 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
455 ChromeCompositorStateMachine_MajorState_BeginMainFrameState_strings[idx].get();
456 }
ChromeCompositorStateMachine_MajorState_BeginMainFrameState_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorStateMachine_MajorState_BeginMainFrameState * value)457 bool ChromeCompositorStateMachine_MajorState_BeginMainFrameState_Parse(
458 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorStateMachine_MajorState_BeginMainFrameState* value) {
459 int int_value;
460 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
461 ChromeCompositorStateMachine_MajorState_BeginMainFrameState_entries, 4, name, &int_value);
462 if (success) {
463 *value = static_cast<ChromeCompositorStateMachine_MajorState_BeginMainFrameState>(int_value);
464 }
465 return success;
466 }
467 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
468 constexpr ChromeCompositorStateMachine_MajorState_BeginMainFrameState ChromeCompositorStateMachine_MajorState::BEGIN_MAIN_FRAME_UNSPECIFIED;
469 constexpr ChromeCompositorStateMachine_MajorState_BeginMainFrameState ChromeCompositorStateMachine_MajorState::BEGIN_MAIN_FRAME_IDLE;
470 constexpr ChromeCompositorStateMachine_MajorState_BeginMainFrameState ChromeCompositorStateMachine_MajorState::BEGIN_MAIN_FRAME_SENT;
471 constexpr ChromeCompositorStateMachine_MajorState_BeginMainFrameState ChromeCompositorStateMachine_MajorState::BEGIN_MAIN_FRAME_READY_TO_COMMIT;
472 constexpr ChromeCompositorStateMachine_MajorState_BeginMainFrameState ChromeCompositorStateMachine_MajorState::BeginMainFrameState_MIN;
473 constexpr ChromeCompositorStateMachine_MajorState_BeginMainFrameState ChromeCompositorStateMachine_MajorState::BeginMainFrameState_MAX;
474 constexpr int ChromeCompositorStateMachine_MajorState::BeginMainFrameState_ARRAYSIZE;
475 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_IsValid(int value)476 bool ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_IsValid(int value) {
477 switch (value) {
478 case 0:
479 case 1:
480 case 2:
481 case 3:
482 case 4:
483 case 5:
484 return true;
485 default:
486 return false;
487 }
488 }
489
490 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_strings[6] = {};
491
492 static const char ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names[] =
493 "LAYER_TREE_FRAME_ACTIVE"
494 "LAYER_TREE_FRAME_CREATING"
495 "LAYER_TREE_FRAME_NONE"
496 "LAYER_TREE_FRAME_UNSPECIFIED"
497 "LAYER_TREE_FRAME_WAITING_FOR_FIRST_ACTIVATION"
498 "LAYER_TREE_FRAME_WAITING_FOR_FIRST_COMMIT";
499
500 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries[] = {
501 { {ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names + 0, 23}, 2 },
502 { {ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names + 23, 25}, 3 },
503 { {ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names + 48, 21}, 1 },
504 { {ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names + 69, 28}, 0 },
505 { {ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names + 97, 45}, 5 },
506 { {ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_names + 142, 41}, 4 },
507 };
508
509 static const int ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries_by_number[] = {
510 3, // 0 -> LAYER_TREE_FRAME_UNSPECIFIED
511 2, // 1 -> LAYER_TREE_FRAME_NONE
512 0, // 2 -> LAYER_TREE_FRAME_ACTIVE
513 1, // 3 -> LAYER_TREE_FRAME_CREATING
514 5, // 4 -> LAYER_TREE_FRAME_WAITING_FOR_FIRST_COMMIT
515 4, // 5 -> LAYER_TREE_FRAME_WAITING_FOR_FIRST_ACTIVATION
516 };
517
ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_Name(ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState value)518 const std::string& ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_Name(
519 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState value) {
520 static const bool dummy =
521 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
522 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries,
523 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries_by_number,
524 6, ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_strings);
525 (void) dummy;
526 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
527 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries,
528 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries_by_number,
529 6, value);
530 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
531 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_strings[idx].get();
532 }
ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState * value)533 bool ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_Parse(
534 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState* value) {
535 int int_value;
536 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
537 ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_entries, 6, name, &int_value);
538 if (success) {
539 *value = static_cast<ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState>(int_value);
540 }
541 return success;
542 }
543 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
544 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LAYER_TREE_FRAME_UNSPECIFIED;
545 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LAYER_TREE_FRAME_NONE;
546 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LAYER_TREE_FRAME_ACTIVE;
547 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LAYER_TREE_FRAME_CREATING;
548 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LAYER_TREE_FRAME_WAITING_FOR_FIRST_COMMIT;
549 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LAYER_TREE_FRAME_WAITING_FOR_FIRST_ACTIVATION;
550 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LayerTreeFrameSinkState_MIN;
551 constexpr ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState ChromeCompositorStateMachine_MajorState::LayerTreeFrameSinkState_MAX;
552 constexpr int ChromeCompositorStateMachine_MajorState::LayerTreeFrameSinkState_ARRAYSIZE;
553 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_IsValid(int value)554 bool ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_IsValid(int value) {
555 switch (value) {
556 case 0:
557 case 1:
558 case 2:
559 case 3:
560 case 4:
561 return true;
562 default:
563 return false;
564 }
565 }
566
567 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_strings[5] = {};
568
569 static const char ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_names[] =
570 "FORCED_REDRAW_IDLE"
571 "FORCED_REDRAW_UNSPECIFIED"
572 "FORCED_REDRAW_WAITING_FOR_ACTIVATION"
573 "FORCED_REDRAW_WAITING_FOR_COMMIT"
574 "FORCED_REDRAW_WAITING_FOR_DRAW";
575
576 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries[] = {
577 { {ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_names + 0, 18}, 1 },
578 { {ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_names + 18, 25}, 0 },
579 { {ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_names + 43, 36}, 3 },
580 { {ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_names + 79, 32}, 2 },
581 { {ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_names + 111, 30}, 4 },
582 };
583
584 static const int ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries_by_number[] = {
585 1, // 0 -> FORCED_REDRAW_UNSPECIFIED
586 0, // 1 -> FORCED_REDRAW_IDLE
587 3, // 2 -> FORCED_REDRAW_WAITING_FOR_COMMIT
588 2, // 3 -> FORCED_REDRAW_WAITING_FOR_ACTIVATION
589 4, // 4 -> FORCED_REDRAW_WAITING_FOR_DRAW
590 };
591
ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_Name(ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState value)592 const std::string& ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_Name(
593 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState value) {
594 static const bool dummy =
595 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
596 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries,
597 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries_by_number,
598 5, ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_strings);
599 (void) dummy;
600 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
601 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries,
602 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries_by_number,
603 5, value);
604 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
605 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_strings[idx].get();
606 }
ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState * value)607 bool ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_Parse(
608 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState* value) {
609 int int_value;
610 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
611 ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_entries, 5, name, &int_value);
612 if (success) {
613 *value = static_cast<ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState>(int_value);
614 }
615 return success;
616 }
617 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
618 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::FORCED_REDRAW_UNSPECIFIED;
619 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::FORCED_REDRAW_IDLE;
620 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::FORCED_REDRAW_WAITING_FOR_COMMIT;
621 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::FORCED_REDRAW_WAITING_FOR_ACTIVATION;
622 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::FORCED_REDRAW_WAITING_FOR_DRAW;
623 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::ForcedRedrawOnTimeoutState_MIN;
624 constexpr ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState ChromeCompositorStateMachine_MajorState::ForcedRedrawOnTimeoutState_MAX;
625 constexpr int ChromeCompositorStateMachine_MajorState::ForcedRedrawOnTimeoutState_ARRAYSIZE;
626 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorStateMachine_MinorState_TreePriority_IsValid(int value)627 bool ChromeCompositorStateMachine_MinorState_TreePriority_IsValid(int value) {
628 switch (value) {
629 case 0:
630 case 1:
631 case 2:
632 case 3:
633 return true;
634 default:
635 return false;
636 }
637 }
638
639 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorStateMachine_MinorState_TreePriority_strings[4] = {};
640
641 static const char ChromeCompositorStateMachine_MinorState_TreePriority_names[] =
642 "TREE_PRIORITY_NEW_CONTENT_TAKES_PRIORITY"
643 "TREE_PRIORITY_SAME_PRIORITY_FOR_BOTH_TREES"
644 "TREE_PRIORITY_SMOOTHNESS_TAKES_PRIORITY"
645 "TREE_PRIORITY_UNSPECIFIED";
646
647 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorStateMachine_MinorState_TreePriority_entries[] = {
648 { {ChromeCompositorStateMachine_MinorState_TreePriority_names + 0, 40}, 3 },
649 { {ChromeCompositorStateMachine_MinorState_TreePriority_names + 40, 42}, 1 },
650 { {ChromeCompositorStateMachine_MinorState_TreePriority_names + 82, 39}, 2 },
651 { {ChromeCompositorStateMachine_MinorState_TreePriority_names + 121, 25}, 0 },
652 };
653
654 static const int ChromeCompositorStateMachine_MinorState_TreePriority_entries_by_number[] = {
655 3, // 0 -> TREE_PRIORITY_UNSPECIFIED
656 1, // 1 -> TREE_PRIORITY_SAME_PRIORITY_FOR_BOTH_TREES
657 2, // 2 -> TREE_PRIORITY_SMOOTHNESS_TAKES_PRIORITY
658 0, // 3 -> TREE_PRIORITY_NEW_CONTENT_TAKES_PRIORITY
659 };
660
ChromeCompositorStateMachine_MinorState_TreePriority_Name(ChromeCompositorStateMachine_MinorState_TreePriority value)661 const std::string& ChromeCompositorStateMachine_MinorState_TreePriority_Name(
662 ChromeCompositorStateMachine_MinorState_TreePriority value) {
663 static const bool dummy =
664 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
665 ChromeCompositorStateMachine_MinorState_TreePriority_entries,
666 ChromeCompositorStateMachine_MinorState_TreePriority_entries_by_number,
667 4, ChromeCompositorStateMachine_MinorState_TreePriority_strings);
668 (void) dummy;
669 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
670 ChromeCompositorStateMachine_MinorState_TreePriority_entries,
671 ChromeCompositorStateMachine_MinorState_TreePriority_entries_by_number,
672 4, value);
673 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
674 ChromeCompositorStateMachine_MinorState_TreePriority_strings[idx].get();
675 }
ChromeCompositorStateMachine_MinorState_TreePriority_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorStateMachine_MinorState_TreePriority * value)676 bool ChromeCompositorStateMachine_MinorState_TreePriority_Parse(
677 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorStateMachine_MinorState_TreePriority* value) {
678 int int_value;
679 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
680 ChromeCompositorStateMachine_MinorState_TreePriority_entries, 4, name, &int_value);
681 if (success) {
682 *value = static_cast<ChromeCompositorStateMachine_MinorState_TreePriority>(int_value);
683 }
684 return success;
685 }
686 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
687 constexpr ChromeCompositorStateMachine_MinorState_TreePriority ChromeCompositorStateMachine_MinorState::TREE_PRIORITY_UNSPECIFIED;
688 constexpr ChromeCompositorStateMachine_MinorState_TreePriority ChromeCompositorStateMachine_MinorState::TREE_PRIORITY_SAME_PRIORITY_FOR_BOTH_TREES;
689 constexpr ChromeCompositorStateMachine_MinorState_TreePriority ChromeCompositorStateMachine_MinorState::TREE_PRIORITY_SMOOTHNESS_TAKES_PRIORITY;
690 constexpr ChromeCompositorStateMachine_MinorState_TreePriority ChromeCompositorStateMachine_MinorState::TREE_PRIORITY_NEW_CONTENT_TAKES_PRIORITY;
691 constexpr ChromeCompositorStateMachine_MinorState_TreePriority ChromeCompositorStateMachine_MinorState::TreePriority_MIN;
692 constexpr ChromeCompositorStateMachine_MinorState_TreePriority ChromeCompositorStateMachine_MinorState::TreePriority_MAX;
693 constexpr int ChromeCompositorStateMachine_MinorState::TreePriority_ARRAYSIZE;
694 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorStateMachine_MinorState_ScrollHandlerState_IsValid(int value)695 bool ChromeCompositorStateMachine_MinorState_ScrollHandlerState_IsValid(int value) {
696 switch (value) {
697 case 0:
698 case 1:
699 case 2:
700 return true;
701 default:
702 return false;
703 }
704 }
705
706 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorStateMachine_MinorState_ScrollHandlerState_strings[3] = {};
707
708 static const char ChromeCompositorStateMachine_MinorState_ScrollHandlerState_names[] =
709 "SCROLL_AFFECTS_SCROLL_HANDLER"
710 "SCROLL_DOES_NOT_AFFECT_SCROLL_HANDLER"
711 "SCROLL_HANDLER_UNSPECIFIED";
712
713 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries[] = {
714 { {ChromeCompositorStateMachine_MinorState_ScrollHandlerState_names + 0, 29}, 1 },
715 { {ChromeCompositorStateMachine_MinorState_ScrollHandlerState_names + 29, 37}, 2 },
716 { {ChromeCompositorStateMachine_MinorState_ScrollHandlerState_names + 66, 26}, 0 },
717 };
718
719 static const int ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries_by_number[] = {
720 2, // 0 -> SCROLL_HANDLER_UNSPECIFIED
721 0, // 1 -> SCROLL_AFFECTS_SCROLL_HANDLER
722 1, // 2 -> SCROLL_DOES_NOT_AFFECT_SCROLL_HANDLER
723 };
724
ChromeCompositorStateMachine_MinorState_ScrollHandlerState_Name(ChromeCompositorStateMachine_MinorState_ScrollHandlerState value)725 const std::string& ChromeCompositorStateMachine_MinorState_ScrollHandlerState_Name(
726 ChromeCompositorStateMachine_MinorState_ScrollHandlerState value) {
727 static const bool dummy =
728 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
729 ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries,
730 ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries_by_number,
731 3, ChromeCompositorStateMachine_MinorState_ScrollHandlerState_strings);
732 (void) dummy;
733 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
734 ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries,
735 ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries_by_number,
736 3, value);
737 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
738 ChromeCompositorStateMachine_MinorState_ScrollHandlerState_strings[idx].get();
739 }
ChromeCompositorStateMachine_MinorState_ScrollHandlerState_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorStateMachine_MinorState_ScrollHandlerState * value)740 bool ChromeCompositorStateMachine_MinorState_ScrollHandlerState_Parse(
741 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorStateMachine_MinorState_ScrollHandlerState* value) {
742 int int_value;
743 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
744 ChromeCompositorStateMachine_MinorState_ScrollHandlerState_entries, 3, name, &int_value);
745 if (success) {
746 *value = static_cast<ChromeCompositorStateMachine_MinorState_ScrollHandlerState>(int_value);
747 }
748 return success;
749 }
750 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
751 constexpr ChromeCompositorStateMachine_MinorState_ScrollHandlerState ChromeCompositorStateMachine_MinorState::SCROLL_HANDLER_UNSPECIFIED;
752 constexpr ChromeCompositorStateMachine_MinorState_ScrollHandlerState ChromeCompositorStateMachine_MinorState::SCROLL_AFFECTS_SCROLL_HANDLER;
753 constexpr ChromeCompositorStateMachine_MinorState_ScrollHandlerState ChromeCompositorStateMachine_MinorState::SCROLL_DOES_NOT_AFFECT_SCROLL_HANDLER;
754 constexpr ChromeCompositorStateMachine_MinorState_ScrollHandlerState ChromeCompositorStateMachine_MinorState::ScrollHandlerState_MIN;
755 constexpr ChromeCompositorStateMachine_MinorState_ScrollHandlerState ChromeCompositorStateMachine_MinorState::ScrollHandlerState_MAX;
756 constexpr int ChromeCompositorStateMachine_MinorState::ScrollHandlerState_ARRAYSIZE;
757 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
BeginFrameArgs_BeginFrameArgsType_IsValid(int value)758 bool BeginFrameArgs_BeginFrameArgsType_IsValid(int value) {
759 switch (value) {
760 case 0:
761 case 1:
762 case 2:
763 case 3:
764 return true;
765 default:
766 return false;
767 }
768 }
769
770 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> BeginFrameArgs_BeginFrameArgsType_strings[4] = {};
771
772 static const char BeginFrameArgs_BeginFrameArgsType_names[] =
773 "BEGIN_FRAME_ARGS_TYPE_INVALID"
774 "BEGIN_FRAME_ARGS_TYPE_MISSED"
775 "BEGIN_FRAME_ARGS_TYPE_NORMAL"
776 "BEGIN_FRAME_ARGS_TYPE_UNSPECIFIED";
777
778 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry BeginFrameArgs_BeginFrameArgsType_entries[] = {
779 { {BeginFrameArgs_BeginFrameArgsType_names + 0, 29}, 1 },
780 { {BeginFrameArgs_BeginFrameArgsType_names + 29, 28}, 3 },
781 { {BeginFrameArgs_BeginFrameArgsType_names + 57, 28}, 2 },
782 { {BeginFrameArgs_BeginFrameArgsType_names + 85, 33}, 0 },
783 };
784
785 static const int BeginFrameArgs_BeginFrameArgsType_entries_by_number[] = {
786 3, // 0 -> BEGIN_FRAME_ARGS_TYPE_UNSPECIFIED
787 0, // 1 -> BEGIN_FRAME_ARGS_TYPE_INVALID
788 2, // 2 -> BEGIN_FRAME_ARGS_TYPE_NORMAL
789 1, // 3 -> BEGIN_FRAME_ARGS_TYPE_MISSED
790 };
791
BeginFrameArgs_BeginFrameArgsType_Name(BeginFrameArgs_BeginFrameArgsType value)792 const std::string& BeginFrameArgs_BeginFrameArgsType_Name(
793 BeginFrameArgs_BeginFrameArgsType value) {
794 static const bool dummy =
795 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
796 BeginFrameArgs_BeginFrameArgsType_entries,
797 BeginFrameArgs_BeginFrameArgsType_entries_by_number,
798 4, BeginFrameArgs_BeginFrameArgsType_strings);
799 (void) dummy;
800 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
801 BeginFrameArgs_BeginFrameArgsType_entries,
802 BeginFrameArgs_BeginFrameArgsType_entries_by_number,
803 4, value);
804 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
805 BeginFrameArgs_BeginFrameArgsType_strings[idx].get();
806 }
BeginFrameArgs_BeginFrameArgsType_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,BeginFrameArgs_BeginFrameArgsType * value)807 bool BeginFrameArgs_BeginFrameArgsType_Parse(
808 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, BeginFrameArgs_BeginFrameArgsType* value) {
809 int int_value;
810 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
811 BeginFrameArgs_BeginFrameArgsType_entries, 4, name, &int_value);
812 if (success) {
813 *value = static_cast<BeginFrameArgs_BeginFrameArgsType>(int_value);
814 }
815 return success;
816 }
817 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
818 constexpr BeginFrameArgs_BeginFrameArgsType BeginFrameArgs::BEGIN_FRAME_ARGS_TYPE_UNSPECIFIED;
819 constexpr BeginFrameArgs_BeginFrameArgsType BeginFrameArgs::BEGIN_FRAME_ARGS_TYPE_INVALID;
820 constexpr BeginFrameArgs_BeginFrameArgsType BeginFrameArgs::BEGIN_FRAME_ARGS_TYPE_NORMAL;
821 constexpr BeginFrameArgs_BeginFrameArgsType BeginFrameArgs::BEGIN_FRAME_ARGS_TYPE_MISSED;
822 constexpr BeginFrameArgs_BeginFrameArgsType BeginFrameArgs::BeginFrameArgsType_MIN;
823 constexpr BeginFrameArgs_BeginFrameArgsType BeginFrameArgs::BeginFrameArgsType_MAX;
824 constexpr int BeginFrameArgs::BeginFrameArgsType_ARRAYSIZE;
825 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
BeginImplFrameArgs_State_IsValid(int value)826 bool BeginImplFrameArgs_State_IsValid(int value) {
827 switch (value) {
828 case 0:
829 case 1:
830 return true;
831 default:
832 return false;
833 }
834 }
835
836 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> BeginImplFrameArgs_State_strings[2] = {};
837
838 static const char BeginImplFrameArgs_State_names[] =
839 "BEGIN_FRAME_FINISHED"
840 "BEGIN_FRAME_USING";
841
842 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry BeginImplFrameArgs_State_entries[] = {
843 { {BeginImplFrameArgs_State_names + 0, 20}, 0 },
844 { {BeginImplFrameArgs_State_names + 20, 17}, 1 },
845 };
846
847 static const int BeginImplFrameArgs_State_entries_by_number[] = {
848 0, // 0 -> BEGIN_FRAME_FINISHED
849 1, // 1 -> BEGIN_FRAME_USING
850 };
851
BeginImplFrameArgs_State_Name(BeginImplFrameArgs_State value)852 const std::string& BeginImplFrameArgs_State_Name(
853 BeginImplFrameArgs_State value) {
854 static const bool dummy =
855 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
856 BeginImplFrameArgs_State_entries,
857 BeginImplFrameArgs_State_entries_by_number,
858 2, BeginImplFrameArgs_State_strings);
859 (void) dummy;
860 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
861 BeginImplFrameArgs_State_entries,
862 BeginImplFrameArgs_State_entries_by_number,
863 2, value);
864 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
865 BeginImplFrameArgs_State_strings[idx].get();
866 }
BeginImplFrameArgs_State_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,BeginImplFrameArgs_State * value)867 bool BeginImplFrameArgs_State_Parse(
868 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, BeginImplFrameArgs_State* value) {
869 int int_value;
870 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
871 BeginImplFrameArgs_State_entries, 2, name, &int_value);
872 if (success) {
873 *value = static_cast<BeginImplFrameArgs_State>(int_value);
874 }
875 return success;
876 }
877 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
878 constexpr BeginImplFrameArgs_State BeginImplFrameArgs::BEGIN_FRAME_FINISHED;
879 constexpr BeginImplFrameArgs_State BeginImplFrameArgs::BEGIN_FRAME_USING;
880 constexpr BeginImplFrameArgs_State BeginImplFrameArgs::State_MIN;
881 constexpr BeginImplFrameArgs_State BeginImplFrameArgs::State_MAX;
882 constexpr int BeginImplFrameArgs::State_ARRAYSIZE;
883 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
ChromeCompositorSchedulerAction_IsValid(int value)884 bool ChromeCompositorSchedulerAction_IsValid(int value) {
885 switch (value) {
886 case 0:
887 case 1:
888 case 2:
889 case 3:
890 case 4:
891 case 5:
892 case 6:
893 case 7:
894 case 8:
895 case 9:
896 case 10:
897 case 11:
898 case 12:
899 case 13:
900 return true;
901 default:
902 return false;
903 }
904 }
905
906 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> ChromeCompositorSchedulerAction_strings[14] = {};
907
908 static const char ChromeCompositorSchedulerAction_names[] =
909 "CC_SCHEDULER_ACTION_ACTIVATE_SYNC_TREE"
910 "CC_SCHEDULER_ACTION_BEGIN_LAYER_TREE_FRAME_SINK_CREATION"
911 "CC_SCHEDULER_ACTION_COMMIT"
912 "CC_SCHEDULER_ACTION_DRAW_ABORT"
913 "CC_SCHEDULER_ACTION_DRAW_FORCED"
914 "CC_SCHEDULER_ACTION_DRAW_IF_POSSIBLE"
915 "CC_SCHEDULER_ACTION_INVALIDATE_LAYER_TREE_FRAME_SINK"
916 "CC_SCHEDULER_ACTION_NONE"
917 "CC_SCHEDULER_ACTION_NOTIFY_BEGIN_MAIN_FRAME_NOT_EXPECTED_SOON"
918 "CC_SCHEDULER_ACTION_NOTIFY_BEGIN_MAIN_FRAME_NOT_EXPECTED_UNTIL"
919 "CC_SCHEDULER_ACTION_PERFORM_IMPL_SIDE_INVALIDATION"
920 "CC_SCHEDULER_ACTION_PREPARE_TILES"
921 "CC_SCHEDULER_ACTION_SEND_BEGIN_MAIN_FRAME"
922 "CC_SCHEDULER_ACTION_UNSPECIFIED";
923
924 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry ChromeCompositorSchedulerAction_entries[] = {
925 { {ChromeCompositorSchedulerAction_names + 0, 38}, 4 },
926 { {ChromeCompositorSchedulerAction_names + 38, 56}, 8 },
927 { {ChromeCompositorSchedulerAction_names + 94, 26}, 3 },
928 { {ChromeCompositorSchedulerAction_names + 120, 30}, 7 },
929 { {ChromeCompositorSchedulerAction_names + 150, 31}, 6 },
930 { {ChromeCompositorSchedulerAction_names + 181, 36}, 5 },
931 { {ChromeCompositorSchedulerAction_names + 217, 52}, 10 },
932 { {ChromeCompositorSchedulerAction_names + 269, 24}, 1 },
933 { {ChromeCompositorSchedulerAction_names + 293, 61}, 13 },
934 { {ChromeCompositorSchedulerAction_names + 354, 62}, 12 },
935 { {ChromeCompositorSchedulerAction_names + 416, 50}, 11 },
936 { {ChromeCompositorSchedulerAction_names + 466, 33}, 9 },
937 { {ChromeCompositorSchedulerAction_names + 499, 41}, 2 },
938 { {ChromeCompositorSchedulerAction_names + 540, 31}, 0 },
939 };
940
941 static const int ChromeCompositorSchedulerAction_entries_by_number[] = {
942 13, // 0 -> CC_SCHEDULER_ACTION_UNSPECIFIED
943 7, // 1 -> CC_SCHEDULER_ACTION_NONE
944 12, // 2 -> CC_SCHEDULER_ACTION_SEND_BEGIN_MAIN_FRAME
945 2, // 3 -> CC_SCHEDULER_ACTION_COMMIT
946 0, // 4 -> CC_SCHEDULER_ACTION_ACTIVATE_SYNC_TREE
947 5, // 5 -> CC_SCHEDULER_ACTION_DRAW_IF_POSSIBLE
948 4, // 6 -> CC_SCHEDULER_ACTION_DRAW_FORCED
949 3, // 7 -> CC_SCHEDULER_ACTION_DRAW_ABORT
950 1, // 8 -> CC_SCHEDULER_ACTION_BEGIN_LAYER_TREE_FRAME_SINK_CREATION
951 11, // 9 -> CC_SCHEDULER_ACTION_PREPARE_TILES
952 6, // 10 -> CC_SCHEDULER_ACTION_INVALIDATE_LAYER_TREE_FRAME_SINK
953 10, // 11 -> CC_SCHEDULER_ACTION_PERFORM_IMPL_SIDE_INVALIDATION
954 9, // 12 -> CC_SCHEDULER_ACTION_NOTIFY_BEGIN_MAIN_FRAME_NOT_EXPECTED_UNTIL
955 8, // 13 -> CC_SCHEDULER_ACTION_NOTIFY_BEGIN_MAIN_FRAME_NOT_EXPECTED_SOON
956 };
957
ChromeCompositorSchedulerAction_Name(ChromeCompositorSchedulerAction value)958 const std::string& ChromeCompositorSchedulerAction_Name(
959 ChromeCompositorSchedulerAction value) {
960 static const bool dummy =
961 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
962 ChromeCompositorSchedulerAction_entries,
963 ChromeCompositorSchedulerAction_entries_by_number,
964 14, ChromeCompositorSchedulerAction_strings);
965 (void) dummy;
966 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
967 ChromeCompositorSchedulerAction_entries,
968 ChromeCompositorSchedulerAction_entries_by_number,
969 14, value);
970 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
971 ChromeCompositorSchedulerAction_strings[idx].get();
972 }
ChromeCompositorSchedulerAction_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,ChromeCompositorSchedulerAction * value)973 bool ChromeCompositorSchedulerAction_Parse(
974 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, ChromeCompositorSchedulerAction* value) {
975 int int_value;
976 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
977 ChromeCompositorSchedulerAction_entries, 14, name, &int_value);
978 if (success) {
979 *value = static_cast<ChromeCompositorSchedulerAction>(int_value);
980 }
981 return success;
982 }
983
984 // ===================================================================
985
986 class ChromeCompositorSchedulerState::_Internal {
987 public:
988 using HasBits = decltype(std::declval<ChromeCompositorSchedulerState>()._impl_._has_bits_);
989 static const ::perfetto::protos::ChromeCompositorStateMachine& state_machine(const ChromeCompositorSchedulerState* msg);
set_has_state_machine(HasBits * has_bits)990 static void set_has_state_machine(HasBits* has_bits) {
991 (*has_bits)[0] |= 1u;
992 }
set_has_observing_begin_frame_source(HasBits * has_bits)993 static void set_has_observing_begin_frame_source(HasBits* has_bits) {
994 (*has_bits)[0] |= 32u;
995 }
set_has_begin_impl_frame_deadline_task(HasBits * has_bits)996 static void set_has_begin_impl_frame_deadline_task(HasBits* has_bits) {
997 (*has_bits)[0] |= 64u;
998 }
set_has_pending_begin_frame_task(HasBits * has_bits)999 static void set_has_pending_begin_frame_task(HasBits* has_bits) {
1000 (*has_bits)[0] |= 128u;
1001 }
set_has_skipped_last_frame_missed_exceeded_deadline(HasBits * has_bits)1002 static void set_has_skipped_last_frame_missed_exceeded_deadline(HasBits* has_bits) {
1003 (*has_bits)[0] |= 256u;
1004 }
set_has_inside_action(HasBits * has_bits)1005 static void set_has_inside_action(HasBits* has_bits) {
1006 (*has_bits)[0] |= 512u;
1007 }
set_has_deadline_mode(HasBits * has_bits)1008 static void set_has_deadline_mode(HasBits* has_bits) {
1009 (*has_bits)[0] |= 32768u;
1010 }
set_has_deadline_us(HasBits * has_bits)1011 static void set_has_deadline_us(HasBits* has_bits) {
1012 (*has_bits)[0] |= 1024u;
1013 }
set_has_deadline_scheduled_at_us(HasBits * has_bits)1014 static void set_has_deadline_scheduled_at_us(HasBits* has_bits) {
1015 (*has_bits)[0] |= 2048u;
1016 }
set_has_now_us(HasBits * has_bits)1017 static void set_has_now_us(HasBits* has_bits) {
1018 (*has_bits)[0] |= 4096u;
1019 }
set_has_now_to_deadline_delta_us(HasBits * has_bits)1020 static void set_has_now_to_deadline_delta_us(HasBits* has_bits) {
1021 (*has_bits)[0] |= 8192u;
1022 }
set_has_now_to_deadline_scheduled_at_delta_us(HasBits * has_bits)1023 static void set_has_now_to_deadline_scheduled_at_delta_us(HasBits* has_bits) {
1024 (*has_bits)[0] |= 16384u;
1025 }
1026 static const ::perfetto::protos::BeginImplFrameArgs& begin_impl_frame_args(const ChromeCompositorSchedulerState* msg);
set_has_begin_impl_frame_args(HasBits * has_bits)1027 static void set_has_begin_impl_frame_args(HasBits* has_bits) {
1028 (*has_bits)[0] |= 2u;
1029 }
1030 static const ::perfetto::protos::BeginFrameObserverState& begin_frame_observer_state(const ChromeCompositorSchedulerState* msg);
set_has_begin_frame_observer_state(HasBits * has_bits)1031 static void set_has_begin_frame_observer_state(HasBits* has_bits) {
1032 (*has_bits)[0] |= 4u;
1033 }
1034 static const ::perfetto::protos::BeginFrameSourceState& begin_frame_source_state(const ChromeCompositorSchedulerState* msg);
set_has_begin_frame_source_state(HasBits * has_bits)1035 static void set_has_begin_frame_source_state(HasBits* has_bits) {
1036 (*has_bits)[0] |= 8u;
1037 }
1038 static const ::perfetto::protos::CompositorTimingHistory& compositor_timing_history(const ChromeCompositorSchedulerState* msg);
set_has_compositor_timing_history(HasBits * has_bits)1039 static void set_has_compositor_timing_history(HasBits* has_bits) {
1040 (*has_bits)[0] |= 16u;
1041 }
1042 };
1043
1044 const ::perfetto::protos::ChromeCompositorStateMachine&
state_machine(const ChromeCompositorSchedulerState * msg)1045 ChromeCompositorSchedulerState::_Internal::state_machine(const ChromeCompositorSchedulerState* msg) {
1046 return *msg->_impl_.state_machine_;
1047 }
1048 const ::perfetto::protos::BeginImplFrameArgs&
begin_impl_frame_args(const ChromeCompositorSchedulerState * msg)1049 ChromeCompositorSchedulerState::_Internal::begin_impl_frame_args(const ChromeCompositorSchedulerState* msg) {
1050 return *msg->_impl_.begin_impl_frame_args_;
1051 }
1052 const ::perfetto::protos::BeginFrameObserverState&
begin_frame_observer_state(const ChromeCompositorSchedulerState * msg)1053 ChromeCompositorSchedulerState::_Internal::begin_frame_observer_state(const ChromeCompositorSchedulerState* msg) {
1054 return *msg->_impl_.begin_frame_observer_state_;
1055 }
1056 const ::perfetto::protos::BeginFrameSourceState&
begin_frame_source_state(const ChromeCompositorSchedulerState * msg)1057 ChromeCompositorSchedulerState::_Internal::begin_frame_source_state(const ChromeCompositorSchedulerState* msg) {
1058 return *msg->_impl_.begin_frame_source_state_;
1059 }
1060 const ::perfetto::protos::CompositorTimingHistory&
compositor_timing_history(const ChromeCompositorSchedulerState * msg)1061 ChromeCompositorSchedulerState::_Internal::compositor_timing_history(const ChromeCompositorSchedulerState* msg) {
1062 return *msg->_impl_.compositor_timing_history_;
1063 }
ChromeCompositorSchedulerState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)1064 ChromeCompositorSchedulerState::ChromeCompositorSchedulerState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
1065 bool is_message_owned)
1066 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
1067 SharedCtor(arena, is_message_owned);
1068 // @@protoc_insertion_point(arena_constructor:perfetto.protos.ChromeCompositorSchedulerState)
1069 }
ChromeCompositorSchedulerState(const ChromeCompositorSchedulerState & from)1070 ChromeCompositorSchedulerState::ChromeCompositorSchedulerState(const ChromeCompositorSchedulerState& from)
1071 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
1072 ChromeCompositorSchedulerState* const _this = this; (void)_this;
1073 new (&_impl_) Impl_{
1074 decltype(_impl_._has_bits_){from._impl_._has_bits_}
1075 , /*decltype(_impl_._cached_size_)*/{}
1076 , decltype(_impl_.state_machine_){nullptr}
1077 , decltype(_impl_.begin_impl_frame_args_){nullptr}
1078 , decltype(_impl_.begin_frame_observer_state_){nullptr}
1079 , decltype(_impl_.begin_frame_source_state_){nullptr}
1080 , decltype(_impl_.compositor_timing_history_){nullptr}
1081 , decltype(_impl_.observing_begin_frame_source_){}
1082 , decltype(_impl_.begin_impl_frame_deadline_task_){}
1083 , decltype(_impl_.pending_begin_frame_task_){}
1084 , decltype(_impl_.skipped_last_frame_missed_exceeded_deadline_){}
1085 , decltype(_impl_.inside_action_){}
1086 , decltype(_impl_.deadline_us_){}
1087 , decltype(_impl_.deadline_scheduled_at_us_){}
1088 , decltype(_impl_.now_us_){}
1089 , decltype(_impl_.now_to_deadline_delta_us_){}
1090 , decltype(_impl_.now_to_deadline_scheduled_at_delta_us_){}
1091 , decltype(_impl_.deadline_mode_){}};
1092
1093 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1094 if (from._internal_has_state_machine()) {
1095 _this->_impl_.state_machine_ = new ::perfetto::protos::ChromeCompositorStateMachine(*from._impl_.state_machine_);
1096 }
1097 if (from._internal_has_begin_impl_frame_args()) {
1098 _this->_impl_.begin_impl_frame_args_ = new ::perfetto::protos::BeginImplFrameArgs(*from._impl_.begin_impl_frame_args_);
1099 }
1100 if (from._internal_has_begin_frame_observer_state()) {
1101 _this->_impl_.begin_frame_observer_state_ = new ::perfetto::protos::BeginFrameObserverState(*from._impl_.begin_frame_observer_state_);
1102 }
1103 if (from._internal_has_begin_frame_source_state()) {
1104 _this->_impl_.begin_frame_source_state_ = new ::perfetto::protos::BeginFrameSourceState(*from._impl_.begin_frame_source_state_);
1105 }
1106 if (from._internal_has_compositor_timing_history()) {
1107 _this->_impl_.compositor_timing_history_ = new ::perfetto::protos::CompositorTimingHistory(*from._impl_.compositor_timing_history_);
1108 }
1109 ::memcpy(&_impl_.observing_begin_frame_source_, &from._impl_.observing_begin_frame_source_,
1110 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.deadline_mode_) -
1111 reinterpret_cast<char*>(&_impl_.observing_begin_frame_source_)) + sizeof(_impl_.deadline_mode_));
1112 // @@protoc_insertion_point(copy_constructor:perfetto.protos.ChromeCompositorSchedulerState)
1113 }
1114
SharedCtor(::_pb::Arena * arena,bool is_message_owned)1115 inline void ChromeCompositorSchedulerState::SharedCtor(
1116 ::_pb::Arena* arena, bool is_message_owned) {
1117 (void)arena;
1118 (void)is_message_owned;
1119 new (&_impl_) Impl_{
1120 decltype(_impl_._has_bits_){}
1121 , /*decltype(_impl_._cached_size_)*/{}
1122 , decltype(_impl_.state_machine_){nullptr}
1123 , decltype(_impl_.begin_impl_frame_args_){nullptr}
1124 , decltype(_impl_.begin_frame_observer_state_){nullptr}
1125 , decltype(_impl_.begin_frame_source_state_){nullptr}
1126 , decltype(_impl_.compositor_timing_history_){nullptr}
1127 , decltype(_impl_.observing_begin_frame_source_){false}
1128 , decltype(_impl_.begin_impl_frame_deadline_task_){false}
1129 , decltype(_impl_.pending_begin_frame_task_){false}
1130 , decltype(_impl_.skipped_last_frame_missed_exceeded_deadline_){false}
1131 , decltype(_impl_.inside_action_){0}
1132 , decltype(_impl_.deadline_us_){::int64_t{0}}
1133 , decltype(_impl_.deadline_scheduled_at_us_){::int64_t{0}}
1134 , decltype(_impl_.now_us_){::int64_t{0}}
1135 , decltype(_impl_.now_to_deadline_delta_us_){::int64_t{0}}
1136 , decltype(_impl_.now_to_deadline_scheduled_at_delta_us_){::int64_t{0}}
1137 , decltype(_impl_.deadline_mode_){0}
1138 };
1139 }
1140
~ChromeCompositorSchedulerState()1141 ChromeCompositorSchedulerState::~ChromeCompositorSchedulerState() {
1142 // @@protoc_insertion_point(destructor:perfetto.protos.ChromeCompositorSchedulerState)
1143 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
1144 (void)arena;
1145 return;
1146 }
1147 SharedDtor();
1148 }
1149
SharedDtor()1150 inline void ChromeCompositorSchedulerState::SharedDtor() {
1151 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
1152 if (this != internal_default_instance()) delete _impl_.state_machine_;
1153 if (this != internal_default_instance()) delete _impl_.begin_impl_frame_args_;
1154 if (this != internal_default_instance()) delete _impl_.begin_frame_observer_state_;
1155 if (this != internal_default_instance()) delete _impl_.begin_frame_source_state_;
1156 if (this != internal_default_instance()) delete _impl_.compositor_timing_history_;
1157 }
1158
SetCachedSize(int size) const1159 void ChromeCompositorSchedulerState::SetCachedSize(int size) const {
1160 _impl_._cached_size_.Set(size);
1161 }
1162
Clear()1163 void ChromeCompositorSchedulerState::Clear() {
1164 // @@protoc_insertion_point(message_clear_start:perfetto.protos.ChromeCompositorSchedulerState)
1165 ::uint32_t cached_has_bits = 0;
1166 // Prevent compiler warnings about cached_has_bits being unused
1167 (void) cached_has_bits;
1168
1169 cached_has_bits = _impl_._has_bits_[0];
1170 if (cached_has_bits & 0x0000001fu) {
1171 if (cached_has_bits & 0x00000001u) {
1172 GOOGLE_DCHECK(_impl_.state_machine_ != nullptr);
1173 _impl_.state_machine_->Clear();
1174 }
1175 if (cached_has_bits & 0x00000002u) {
1176 GOOGLE_DCHECK(_impl_.begin_impl_frame_args_ != nullptr);
1177 _impl_.begin_impl_frame_args_->Clear();
1178 }
1179 if (cached_has_bits & 0x00000004u) {
1180 GOOGLE_DCHECK(_impl_.begin_frame_observer_state_ != nullptr);
1181 _impl_.begin_frame_observer_state_->Clear();
1182 }
1183 if (cached_has_bits & 0x00000008u) {
1184 GOOGLE_DCHECK(_impl_.begin_frame_source_state_ != nullptr);
1185 _impl_.begin_frame_source_state_->Clear();
1186 }
1187 if (cached_has_bits & 0x00000010u) {
1188 GOOGLE_DCHECK(_impl_.compositor_timing_history_ != nullptr);
1189 _impl_.compositor_timing_history_->Clear();
1190 }
1191 }
1192 if (cached_has_bits & 0x000000e0u) {
1193 ::memset(&_impl_.observing_begin_frame_source_, 0, static_cast<size_t>(
1194 reinterpret_cast<char*>(&_impl_.pending_begin_frame_task_) -
1195 reinterpret_cast<char*>(&_impl_.observing_begin_frame_source_)) + sizeof(_impl_.pending_begin_frame_task_));
1196 }
1197 if (cached_has_bits & 0x0000ff00u) {
1198 ::memset(&_impl_.skipped_last_frame_missed_exceeded_deadline_, 0, static_cast<size_t>(
1199 reinterpret_cast<char*>(&_impl_.deadline_mode_) -
1200 reinterpret_cast<char*>(&_impl_.skipped_last_frame_missed_exceeded_deadline_)) + sizeof(_impl_.deadline_mode_));
1201 }
1202 _impl_._has_bits_.Clear();
1203 _internal_metadata_.Clear<std::string>();
1204 }
1205
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1206 const char* ChromeCompositorSchedulerState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1207 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1208 _Internal::HasBits has_bits{};
1209 while (!ctx->Done(&ptr)) {
1210 ::uint32_t tag;
1211 ptr = ::_pbi::ReadTag(ptr, &tag);
1212 switch (tag >> 3) {
1213 // optional .perfetto.protos.ChromeCompositorStateMachine state_machine = 1;
1214 case 1:
1215 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
1216 ptr = ctx->ParseMessage(_internal_mutable_state_machine(), ptr);
1217 CHK_(ptr);
1218 } else {
1219 goto handle_unusual;
1220 }
1221 continue;
1222 // optional bool observing_begin_frame_source = 2;
1223 case 2:
1224 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
1225 _Internal::set_has_observing_begin_frame_source(&has_bits);
1226 _impl_.observing_begin_frame_source_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1227 CHK_(ptr);
1228 } else {
1229 goto handle_unusual;
1230 }
1231 continue;
1232 // optional bool begin_impl_frame_deadline_task = 3;
1233 case 3:
1234 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
1235 _Internal::set_has_begin_impl_frame_deadline_task(&has_bits);
1236 _impl_.begin_impl_frame_deadline_task_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1237 CHK_(ptr);
1238 } else {
1239 goto handle_unusual;
1240 }
1241 continue;
1242 // optional bool pending_begin_frame_task = 4;
1243 case 4:
1244 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
1245 _Internal::set_has_pending_begin_frame_task(&has_bits);
1246 _impl_.pending_begin_frame_task_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1247 CHK_(ptr);
1248 } else {
1249 goto handle_unusual;
1250 }
1251 continue;
1252 // optional bool skipped_last_frame_missed_exceeded_deadline = 5;
1253 case 5:
1254 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
1255 _Internal::set_has_skipped_last_frame_missed_exceeded_deadline(&has_bits);
1256 _impl_.skipped_last_frame_missed_exceeded_deadline_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1257 CHK_(ptr);
1258 } else {
1259 goto handle_unusual;
1260 }
1261 continue;
1262 // optional .perfetto.protos.ChromeCompositorSchedulerAction inside_action = 7;
1263 case 7:
1264 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
1265 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1266 CHK_(ptr);
1267 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorSchedulerAction_IsValid(val))) {
1268 _internal_set_inside_action(static_cast<::perfetto::protos::ChromeCompositorSchedulerAction>(val));
1269 } else {
1270 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(7, val, mutable_unknown_fields());
1271 }
1272 } else {
1273 goto handle_unusual;
1274 }
1275 continue;
1276 // optional .perfetto.protos.ChromeCompositorSchedulerState.BeginImplFrameDeadlineMode deadline_mode = 8;
1277 case 8:
1278 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
1279 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1280 CHK_(ptr);
1281 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode_IsValid(val))) {
1282 _internal_set_deadline_mode(static_cast<::perfetto::protos::ChromeCompositorSchedulerState_BeginImplFrameDeadlineMode>(val));
1283 } else {
1284 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(8, val, mutable_unknown_fields());
1285 }
1286 } else {
1287 goto handle_unusual;
1288 }
1289 continue;
1290 // optional int64 deadline_us = 9;
1291 case 9:
1292 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
1293 _Internal::set_has_deadline_us(&has_bits);
1294 _impl_.deadline_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1295 CHK_(ptr);
1296 } else {
1297 goto handle_unusual;
1298 }
1299 continue;
1300 // optional int64 deadline_scheduled_at_us = 10;
1301 case 10:
1302 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 80)) {
1303 _Internal::set_has_deadline_scheduled_at_us(&has_bits);
1304 _impl_.deadline_scheduled_at_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1305 CHK_(ptr);
1306 } else {
1307 goto handle_unusual;
1308 }
1309 continue;
1310 // optional int64 now_us = 11;
1311 case 11:
1312 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 88)) {
1313 _Internal::set_has_now_us(&has_bits);
1314 _impl_.now_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1315 CHK_(ptr);
1316 } else {
1317 goto handle_unusual;
1318 }
1319 continue;
1320 // optional int64 now_to_deadline_delta_us = 12;
1321 case 12:
1322 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 96)) {
1323 _Internal::set_has_now_to_deadline_delta_us(&has_bits);
1324 _impl_.now_to_deadline_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1325 CHK_(ptr);
1326 } else {
1327 goto handle_unusual;
1328 }
1329 continue;
1330 // optional int64 now_to_deadline_scheduled_at_delta_us = 13;
1331 case 13:
1332 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 104)) {
1333 _Internal::set_has_now_to_deadline_scheduled_at_delta_us(&has_bits);
1334 _impl_.now_to_deadline_scheduled_at_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1335 CHK_(ptr);
1336 } else {
1337 goto handle_unusual;
1338 }
1339 continue;
1340 // optional .perfetto.protos.BeginImplFrameArgs begin_impl_frame_args = 14;
1341 case 14:
1342 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 114)) {
1343 ptr = ctx->ParseMessage(_internal_mutable_begin_impl_frame_args(), ptr);
1344 CHK_(ptr);
1345 } else {
1346 goto handle_unusual;
1347 }
1348 continue;
1349 // optional .perfetto.protos.BeginFrameObserverState begin_frame_observer_state = 15;
1350 case 15:
1351 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 122)) {
1352 ptr = ctx->ParseMessage(_internal_mutable_begin_frame_observer_state(), ptr);
1353 CHK_(ptr);
1354 } else {
1355 goto handle_unusual;
1356 }
1357 continue;
1358 // optional .perfetto.protos.BeginFrameSourceState begin_frame_source_state = 16;
1359 case 16:
1360 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 130)) {
1361 ptr = ctx->ParseMessage(_internal_mutable_begin_frame_source_state(), ptr);
1362 CHK_(ptr);
1363 } else {
1364 goto handle_unusual;
1365 }
1366 continue;
1367 // optional .perfetto.protos.CompositorTimingHistory compositor_timing_history = 17;
1368 case 17:
1369 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 138)) {
1370 ptr = ctx->ParseMessage(_internal_mutable_compositor_timing_history(), ptr);
1371 CHK_(ptr);
1372 } else {
1373 goto handle_unusual;
1374 }
1375 continue;
1376 default:
1377 goto handle_unusual;
1378 } // switch
1379 handle_unusual:
1380 if ((tag == 0) || ((tag & 7) == 4)) {
1381 CHK_(ptr);
1382 ctx->SetLastTag(tag);
1383 goto message_done;
1384 }
1385 ptr = UnknownFieldParse(
1386 tag,
1387 _internal_metadata_.mutable_unknown_fields<std::string>(),
1388 ptr, ctx);
1389 CHK_(ptr != nullptr);
1390 } // while
1391 message_done:
1392 _impl_._has_bits_.Or(has_bits);
1393 return ptr;
1394 failure:
1395 ptr = nullptr;
1396 goto message_done;
1397 #undef CHK_
1398 }
1399
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1400 ::uint8_t* ChromeCompositorSchedulerState::_InternalSerialize(
1401 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1402 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.ChromeCompositorSchedulerState)
1403 ::uint32_t cached_has_bits = 0;
1404 (void) cached_has_bits;
1405
1406 cached_has_bits = _impl_._has_bits_[0];
1407 // optional .perfetto.protos.ChromeCompositorStateMachine state_machine = 1;
1408 if (cached_has_bits & 0x00000001u) {
1409 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1410 InternalWriteMessage(1, _Internal::state_machine(this),
1411 _Internal::state_machine(this).GetCachedSize(), target, stream);
1412 }
1413
1414 // optional bool observing_begin_frame_source = 2;
1415 if (cached_has_bits & 0x00000020u) {
1416 target = stream->EnsureSpace(target);
1417 target = ::_pbi::WireFormatLite::WriteBoolToArray(2, this->_internal_observing_begin_frame_source(), target);
1418 }
1419
1420 // optional bool begin_impl_frame_deadline_task = 3;
1421 if (cached_has_bits & 0x00000040u) {
1422 target = stream->EnsureSpace(target);
1423 target = ::_pbi::WireFormatLite::WriteBoolToArray(3, this->_internal_begin_impl_frame_deadline_task(), target);
1424 }
1425
1426 // optional bool pending_begin_frame_task = 4;
1427 if (cached_has_bits & 0x00000080u) {
1428 target = stream->EnsureSpace(target);
1429 target = ::_pbi::WireFormatLite::WriteBoolToArray(4, this->_internal_pending_begin_frame_task(), target);
1430 }
1431
1432 // optional bool skipped_last_frame_missed_exceeded_deadline = 5;
1433 if (cached_has_bits & 0x00000100u) {
1434 target = stream->EnsureSpace(target);
1435 target = ::_pbi::WireFormatLite::WriteBoolToArray(5, this->_internal_skipped_last_frame_missed_exceeded_deadline(), target);
1436 }
1437
1438 // optional .perfetto.protos.ChromeCompositorSchedulerAction inside_action = 7;
1439 if (cached_has_bits & 0x00000200u) {
1440 target = stream->EnsureSpace(target);
1441 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1442 7, this->_internal_inside_action(), target);
1443 }
1444
1445 // optional .perfetto.protos.ChromeCompositorSchedulerState.BeginImplFrameDeadlineMode deadline_mode = 8;
1446 if (cached_has_bits & 0x00008000u) {
1447 target = stream->EnsureSpace(target);
1448 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1449 8, this->_internal_deadline_mode(), target);
1450 }
1451
1452 // optional int64 deadline_us = 9;
1453 if (cached_has_bits & 0x00000400u) {
1454 target = stream->EnsureSpace(target);
1455 target = ::_pbi::WireFormatLite::WriteInt64ToArray(9, this->_internal_deadline_us(), target);
1456 }
1457
1458 // optional int64 deadline_scheduled_at_us = 10;
1459 if (cached_has_bits & 0x00000800u) {
1460 target = stream->EnsureSpace(target);
1461 target = ::_pbi::WireFormatLite::WriteInt64ToArray(10, this->_internal_deadline_scheduled_at_us(), target);
1462 }
1463
1464 // optional int64 now_us = 11;
1465 if (cached_has_bits & 0x00001000u) {
1466 target = stream->EnsureSpace(target);
1467 target = ::_pbi::WireFormatLite::WriteInt64ToArray(11, this->_internal_now_us(), target);
1468 }
1469
1470 // optional int64 now_to_deadline_delta_us = 12;
1471 if (cached_has_bits & 0x00002000u) {
1472 target = stream->EnsureSpace(target);
1473 target = ::_pbi::WireFormatLite::WriteInt64ToArray(12, this->_internal_now_to_deadline_delta_us(), target);
1474 }
1475
1476 // optional int64 now_to_deadline_scheduled_at_delta_us = 13;
1477 if (cached_has_bits & 0x00004000u) {
1478 target = stream->EnsureSpace(target);
1479 target = ::_pbi::WireFormatLite::WriteInt64ToArray(13, this->_internal_now_to_deadline_scheduled_at_delta_us(), target);
1480 }
1481
1482 // optional .perfetto.protos.BeginImplFrameArgs begin_impl_frame_args = 14;
1483 if (cached_has_bits & 0x00000002u) {
1484 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1485 InternalWriteMessage(14, _Internal::begin_impl_frame_args(this),
1486 _Internal::begin_impl_frame_args(this).GetCachedSize(), target, stream);
1487 }
1488
1489 // optional .perfetto.protos.BeginFrameObserverState begin_frame_observer_state = 15;
1490 if (cached_has_bits & 0x00000004u) {
1491 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1492 InternalWriteMessage(15, _Internal::begin_frame_observer_state(this),
1493 _Internal::begin_frame_observer_state(this).GetCachedSize(), target, stream);
1494 }
1495
1496 // optional .perfetto.protos.BeginFrameSourceState begin_frame_source_state = 16;
1497 if (cached_has_bits & 0x00000008u) {
1498 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1499 InternalWriteMessage(16, _Internal::begin_frame_source_state(this),
1500 _Internal::begin_frame_source_state(this).GetCachedSize(), target, stream);
1501 }
1502
1503 // optional .perfetto.protos.CompositorTimingHistory compositor_timing_history = 17;
1504 if (cached_has_bits & 0x00000010u) {
1505 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1506 InternalWriteMessage(17, _Internal::compositor_timing_history(this),
1507 _Internal::compositor_timing_history(this).GetCachedSize(), target, stream);
1508 }
1509
1510 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1511 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
1512 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
1513 }
1514 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.ChromeCompositorSchedulerState)
1515 return target;
1516 }
1517
ByteSizeLong() const1518 size_t ChromeCompositorSchedulerState::ByteSizeLong() const {
1519 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.ChromeCompositorSchedulerState)
1520 size_t total_size = 0;
1521
1522 ::uint32_t cached_has_bits = 0;
1523 // Prevent compiler warnings about cached_has_bits being unused
1524 (void) cached_has_bits;
1525
1526 cached_has_bits = _impl_._has_bits_[0];
1527 if (cached_has_bits & 0x000000ffu) {
1528 // optional .perfetto.protos.ChromeCompositorStateMachine state_machine = 1;
1529 if (cached_has_bits & 0x00000001u) {
1530 total_size += 1 +
1531 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
1532 *_impl_.state_machine_);
1533 }
1534
1535 // optional .perfetto.protos.BeginImplFrameArgs begin_impl_frame_args = 14;
1536 if (cached_has_bits & 0x00000002u) {
1537 total_size += 1 +
1538 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
1539 *_impl_.begin_impl_frame_args_);
1540 }
1541
1542 // optional .perfetto.protos.BeginFrameObserverState begin_frame_observer_state = 15;
1543 if (cached_has_bits & 0x00000004u) {
1544 total_size += 1 +
1545 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
1546 *_impl_.begin_frame_observer_state_);
1547 }
1548
1549 // optional .perfetto.protos.BeginFrameSourceState begin_frame_source_state = 16;
1550 if (cached_has_bits & 0x00000008u) {
1551 total_size += 2 +
1552 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
1553 *_impl_.begin_frame_source_state_);
1554 }
1555
1556 // optional .perfetto.protos.CompositorTimingHistory compositor_timing_history = 17;
1557 if (cached_has_bits & 0x00000010u) {
1558 total_size += 2 +
1559 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
1560 *_impl_.compositor_timing_history_);
1561 }
1562
1563 // optional bool observing_begin_frame_source = 2;
1564 if (cached_has_bits & 0x00000020u) {
1565 total_size += 1 + 1;
1566 }
1567
1568 // optional bool begin_impl_frame_deadline_task = 3;
1569 if (cached_has_bits & 0x00000040u) {
1570 total_size += 1 + 1;
1571 }
1572
1573 // optional bool pending_begin_frame_task = 4;
1574 if (cached_has_bits & 0x00000080u) {
1575 total_size += 1 + 1;
1576 }
1577
1578 }
1579 if (cached_has_bits & 0x0000ff00u) {
1580 // optional bool skipped_last_frame_missed_exceeded_deadline = 5;
1581 if (cached_has_bits & 0x00000100u) {
1582 total_size += 1 + 1;
1583 }
1584
1585 // optional .perfetto.protos.ChromeCompositorSchedulerAction inside_action = 7;
1586 if (cached_has_bits & 0x00000200u) {
1587 total_size += 1 +
1588 ::_pbi::WireFormatLite::EnumSize(this->_internal_inside_action());
1589 }
1590
1591 // optional int64 deadline_us = 9;
1592 if (cached_has_bits & 0x00000400u) {
1593 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_deadline_us());
1594 }
1595
1596 // optional int64 deadline_scheduled_at_us = 10;
1597 if (cached_has_bits & 0x00000800u) {
1598 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_deadline_scheduled_at_us());
1599 }
1600
1601 // optional int64 now_us = 11;
1602 if (cached_has_bits & 0x00001000u) {
1603 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_now_us());
1604 }
1605
1606 // optional int64 now_to_deadline_delta_us = 12;
1607 if (cached_has_bits & 0x00002000u) {
1608 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_now_to_deadline_delta_us());
1609 }
1610
1611 // optional int64 now_to_deadline_scheduled_at_delta_us = 13;
1612 if (cached_has_bits & 0x00004000u) {
1613 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_now_to_deadline_scheduled_at_delta_us());
1614 }
1615
1616 // optional .perfetto.protos.ChromeCompositorSchedulerState.BeginImplFrameDeadlineMode deadline_mode = 8;
1617 if (cached_has_bits & 0x00008000u) {
1618 total_size += 1 +
1619 ::_pbi::WireFormatLite::EnumSize(this->_internal_deadline_mode());
1620 }
1621
1622 }
1623 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1624 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
1625 }
1626 int cached_size = ::_pbi::ToCachedSize(total_size);
1627 SetCachedSize(cached_size);
1628 return total_size;
1629 }
1630
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)1631 void ChromeCompositorSchedulerState::CheckTypeAndMergeFrom(
1632 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
1633 MergeFrom(*::_pbi::DownCast<const ChromeCompositorSchedulerState*>(
1634 &from));
1635 }
1636
MergeFrom(const ChromeCompositorSchedulerState & from)1637 void ChromeCompositorSchedulerState::MergeFrom(const ChromeCompositorSchedulerState& from) {
1638 ChromeCompositorSchedulerState* const _this = this;
1639 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.ChromeCompositorSchedulerState)
1640 GOOGLE_DCHECK_NE(&from, _this);
1641 ::uint32_t cached_has_bits = 0;
1642 (void) cached_has_bits;
1643
1644 cached_has_bits = from._impl_._has_bits_[0];
1645 if (cached_has_bits & 0x000000ffu) {
1646 if (cached_has_bits & 0x00000001u) {
1647 _this->_internal_mutable_state_machine()->::perfetto::protos::ChromeCompositorStateMachine::MergeFrom(
1648 from._internal_state_machine());
1649 }
1650 if (cached_has_bits & 0x00000002u) {
1651 _this->_internal_mutable_begin_impl_frame_args()->::perfetto::protos::BeginImplFrameArgs::MergeFrom(
1652 from._internal_begin_impl_frame_args());
1653 }
1654 if (cached_has_bits & 0x00000004u) {
1655 _this->_internal_mutable_begin_frame_observer_state()->::perfetto::protos::BeginFrameObserverState::MergeFrom(
1656 from._internal_begin_frame_observer_state());
1657 }
1658 if (cached_has_bits & 0x00000008u) {
1659 _this->_internal_mutable_begin_frame_source_state()->::perfetto::protos::BeginFrameSourceState::MergeFrom(
1660 from._internal_begin_frame_source_state());
1661 }
1662 if (cached_has_bits & 0x00000010u) {
1663 _this->_internal_mutable_compositor_timing_history()->::perfetto::protos::CompositorTimingHistory::MergeFrom(
1664 from._internal_compositor_timing_history());
1665 }
1666 if (cached_has_bits & 0x00000020u) {
1667 _this->_impl_.observing_begin_frame_source_ = from._impl_.observing_begin_frame_source_;
1668 }
1669 if (cached_has_bits & 0x00000040u) {
1670 _this->_impl_.begin_impl_frame_deadline_task_ = from._impl_.begin_impl_frame_deadline_task_;
1671 }
1672 if (cached_has_bits & 0x00000080u) {
1673 _this->_impl_.pending_begin_frame_task_ = from._impl_.pending_begin_frame_task_;
1674 }
1675 _this->_impl_._has_bits_[0] |= cached_has_bits;
1676 }
1677 if (cached_has_bits & 0x0000ff00u) {
1678 if (cached_has_bits & 0x00000100u) {
1679 _this->_impl_.skipped_last_frame_missed_exceeded_deadline_ = from._impl_.skipped_last_frame_missed_exceeded_deadline_;
1680 }
1681 if (cached_has_bits & 0x00000200u) {
1682 _this->_impl_.inside_action_ = from._impl_.inside_action_;
1683 }
1684 if (cached_has_bits & 0x00000400u) {
1685 _this->_impl_.deadline_us_ = from._impl_.deadline_us_;
1686 }
1687 if (cached_has_bits & 0x00000800u) {
1688 _this->_impl_.deadline_scheduled_at_us_ = from._impl_.deadline_scheduled_at_us_;
1689 }
1690 if (cached_has_bits & 0x00001000u) {
1691 _this->_impl_.now_us_ = from._impl_.now_us_;
1692 }
1693 if (cached_has_bits & 0x00002000u) {
1694 _this->_impl_.now_to_deadline_delta_us_ = from._impl_.now_to_deadline_delta_us_;
1695 }
1696 if (cached_has_bits & 0x00004000u) {
1697 _this->_impl_.now_to_deadline_scheduled_at_delta_us_ = from._impl_.now_to_deadline_scheduled_at_delta_us_;
1698 }
1699 if (cached_has_bits & 0x00008000u) {
1700 _this->_impl_.deadline_mode_ = from._impl_.deadline_mode_;
1701 }
1702 _this->_impl_._has_bits_[0] |= cached_has_bits;
1703 }
1704 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1705 }
1706
CopyFrom(const ChromeCompositorSchedulerState & from)1707 void ChromeCompositorSchedulerState::CopyFrom(const ChromeCompositorSchedulerState& from) {
1708 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.ChromeCompositorSchedulerState)
1709 if (&from == this) return;
1710 Clear();
1711 MergeFrom(from);
1712 }
1713
IsInitialized() const1714 bool ChromeCompositorSchedulerState::IsInitialized() const {
1715 return true;
1716 }
1717
InternalSwap(ChromeCompositorSchedulerState * other)1718 void ChromeCompositorSchedulerState::InternalSwap(ChromeCompositorSchedulerState* other) {
1719 using std::swap;
1720 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
1721 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
1722 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
1723 PROTOBUF_FIELD_OFFSET(ChromeCompositorSchedulerState, _impl_.deadline_mode_)
1724 + sizeof(ChromeCompositorSchedulerState::_impl_.deadline_mode_) // NOLINT
1725 - PROTOBUF_FIELD_OFFSET(ChromeCompositorSchedulerState, _impl_.state_machine_)>(
1726 reinterpret_cast<char*>(&_impl_.state_machine_),
1727 reinterpret_cast<char*>(&other->_impl_.state_machine_));
1728 }
1729
GetTypeName() const1730 std::string ChromeCompositorSchedulerState::GetTypeName() const {
1731 return "perfetto.protos.ChromeCompositorSchedulerState";
1732 }
1733
1734
1735 // ===================================================================
1736
1737 class ChromeCompositorStateMachine_MajorState::_Internal {
1738 public:
1739 using HasBits = decltype(std::declval<ChromeCompositorStateMachine_MajorState>()._impl_._has_bits_);
set_has_next_action(HasBits * has_bits)1740 static void set_has_next_action(HasBits* has_bits) {
1741 (*has_bits)[0] |= 1u;
1742 }
set_has_begin_impl_frame_state(HasBits * has_bits)1743 static void set_has_begin_impl_frame_state(HasBits* has_bits) {
1744 (*has_bits)[0] |= 2u;
1745 }
set_has_begin_main_frame_state(HasBits * has_bits)1746 static void set_has_begin_main_frame_state(HasBits* has_bits) {
1747 (*has_bits)[0] |= 4u;
1748 }
set_has_layer_tree_frame_sink_state(HasBits * has_bits)1749 static void set_has_layer_tree_frame_sink_state(HasBits* has_bits) {
1750 (*has_bits)[0] |= 8u;
1751 }
set_has_forced_redraw_state(HasBits * has_bits)1752 static void set_has_forced_redraw_state(HasBits* has_bits) {
1753 (*has_bits)[0] |= 16u;
1754 }
1755 };
1756
ChromeCompositorStateMachine_MajorState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)1757 ChromeCompositorStateMachine_MajorState::ChromeCompositorStateMachine_MajorState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
1758 bool is_message_owned)
1759 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
1760 SharedCtor(arena, is_message_owned);
1761 // @@protoc_insertion_point(arena_constructor:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1762 }
ChromeCompositorStateMachine_MajorState(const ChromeCompositorStateMachine_MajorState & from)1763 ChromeCompositorStateMachine_MajorState::ChromeCompositorStateMachine_MajorState(const ChromeCompositorStateMachine_MajorState& from)
1764 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
1765 ChromeCompositorStateMachine_MajorState* const _this = this; (void)_this;
1766 new (&_impl_) Impl_{
1767 decltype(_impl_._has_bits_){from._impl_._has_bits_}
1768 , /*decltype(_impl_._cached_size_)*/{}
1769 , decltype(_impl_.next_action_){}
1770 , decltype(_impl_.begin_impl_frame_state_){}
1771 , decltype(_impl_.begin_main_frame_state_){}
1772 , decltype(_impl_.layer_tree_frame_sink_state_){}
1773 , decltype(_impl_.forced_redraw_state_){}};
1774
1775 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1776 ::memcpy(&_impl_.next_action_, &from._impl_.next_action_,
1777 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.forced_redraw_state_) -
1778 reinterpret_cast<char*>(&_impl_.next_action_)) + sizeof(_impl_.forced_redraw_state_));
1779 // @@protoc_insertion_point(copy_constructor:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1780 }
1781
SharedCtor(::_pb::Arena * arena,bool is_message_owned)1782 inline void ChromeCompositorStateMachine_MajorState::SharedCtor(
1783 ::_pb::Arena* arena, bool is_message_owned) {
1784 (void)arena;
1785 (void)is_message_owned;
1786 new (&_impl_) Impl_{
1787 decltype(_impl_._has_bits_){}
1788 , /*decltype(_impl_._cached_size_)*/{}
1789 , decltype(_impl_.next_action_){0}
1790 , decltype(_impl_.begin_impl_frame_state_){0}
1791 , decltype(_impl_.begin_main_frame_state_){0}
1792 , decltype(_impl_.layer_tree_frame_sink_state_){0}
1793 , decltype(_impl_.forced_redraw_state_){0}
1794 };
1795 }
1796
~ChromeCompositorStateMachine_MajorState()1797 ChromeCompositorStateMachine_MajorState::~ChromeCompositorStateMachine_MajorState() {
1798 // @@protoc_insertion_point(destructor:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1799 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
1800 (void)arena;
1801 return;
1802 }
1803 SharedDtor();
1804 }
1805
SharedDtor()1806 inline void ChromeCompositorStateMachine_MajorState::SharedDtor() {
1807 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
1808 }
1809
SetCachedSize(int size) const1810 void ChromeCompositorStateMachine_MajorState::SetCachedSize(int size) const {
1811 _impl_._cached_size_.Set(size);
1812 }
1813
Clear()1814 void ChromeCompositorStateMachine_MajorState::Clear() {
1815 // @@protoc_insertion_point(message_clear_start:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1816 ::uint32_t cached_has_bits = 0;
1817 // Prevent compiler warnings about cached_has_bits being unused
1818 (void) cached_has_bits;
1819
1820 cached_has_bits = _impl_._has_bits_[0];
1821 if (cached_has_bits & 0x0000001fu) {
1822 ::memset(&_impl_.next_action_, 0, static_cast<size_t>(
1823 reinterpret_cast<char*>(&_impl_.forced_redraw_state_) -
1824 reinterpret_cast<char*>(&_impl_.next_action_)) + sizeof(_impl_.forced_redraw_state_));
1825 }
1826 _impl_._has_bits_.Clear();
1827 _internal_metadata_.Clear<std::string>();
1828 }
1829
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1830 const char* ChromeCompositorStateMachine_MajorState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1831 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1832 _Internal::HasBits has_bits{};
1833 while (!ctx->Done(&ptr)) {
1834 ::uint32_t tag;
1835 ptr = ::_pbi::ReadTag(ptr, &tag);
1836 switch (tag >> 3) {
1837 // optional .perfetto.protos.ChromeCompositorSchedulerAction next_action = 1;
1838 case 1:
1839 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
1840 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1841 CHK_(ptr);
1842 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorSchedulerAction_IsValid(val))) {
1843 _internal_set_next_action(static_cast<::perfetto::protos::ChromeCompositorSchedulerAction>(val));
1844 } else {
1845 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(1, val, mutable_unknown_fields());
1846 }
1847 } else {
1848 goto handle_unusual;
1849 }
1850 continue;
1851 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.BeginImplFrameState begin_impl_frame_state = 2;
1852 case 2:
1853 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
1854 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1855 CHK_(ptr);
1856 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorStateMachine_MajorState_BeginImplFrameState_IsValid(val))) {
1857 _internal_set_begin_impl_frame_state(static_cast<::perfetto::protos::ChromeCompositorStateMachine_MajorState_BeginImplFrameState>(val));
1858 } else {
1859 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(2, val, mutable_unknown_fields());
1860 }
1861 } else {
1862 goto handle_unusual;
1863 }
1864 continue;
1865 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.BeginMainFrameState begin_main_frame_state = 3;
1866 case 3:
1867 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
1868 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1869 CHK_(ptr);
1870 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorStateMachine_MajorState_BeginMainFrameState_IsValid(val))) {
1871 _internal_set_begin_main_frame_state(static_cast<::perfetto::protos::ChromeCompositorStateMachine_MajorState_BeginMainFrameState>(val));
1872 } else {
1873 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(3, val, mutable_unknown_fields());
1874 }
1875 } else {
1876 goto handle_unusual;
1877 }
1878 continue;
1879 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.LayerTreeFrameSinkState layer_tree_frame_sink_state = 4;
1880 case 4:
1881 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
1882 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1883 CHK_(ptr);
1884 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState_IsValid(val))) {
1885 _internal_set_layer_tree_frame_sink_state(static_cast<::perfetto::protos::ChromeCompositorStateMachine_MajorState_LayerTreeFrameSinkState>(val));
1886 } else {
1887 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(4, val, mutable_unknown_fields());
1888 }
1889 } else {
1890 goto handle_unusual;
1891 }
1892 continue;
1893 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.ForcedRedrawOnTimeoutState forced_redraw_state = 5;
1894 case 5:
1895 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
1896 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1897 CHK_(ptr);
1898 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState_IsValid(val))) {
1899 _internal_set_forced_redraw_state(static_cast<::perfetto::protos::ChromeCompositorStateMachine_MajorState_ForcedRedrawOnTimeoutState>(val));
1900 } else {
1901 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(5, val, mutable_unknown_fields());
1902 }
1903 } else {
1904 goto handle_unusual;
1905 }
1906 continue;
1907 default:
1908 goto handle_unusual;
1909 } // switch
1910 handle_unusual:
1911 if ((tag == 0) || ((tag & 7) == 4)) {
1912 CHK_(ptr);
1913 ctx->SetLastTag(tag);
1914 goto message_done;
1915 }
1916 ptr = UnknownFieldParse(
1917 tag,
1918 _internal_metadata_.mutable_unknown_fields<std::string>(),
1919 ptr, ctx);
1920 CHK_(ptr != nullptr);
1921 } // while
1922 message_done:
1923 _impl_._has_bits_.Or(has_bits);
1924 return ptr;
1925 failure:
1926 ptr = nullptr;
1927 goto message_done;
1928 #undef CHK_
1929 }
1930
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1931 ::uint8_t* ChromeCompositorStateMachine_MajorState::_InternalSerialize(
1932 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1933 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1934 ::uint32_t cached_has_bits = 0;
1935 (void) cached_has_bits;
1936
1937 cached_has_bits = _impl_._has_bits_[0];
1938 // optional .perfetto.protos.ChromeCompositorSchedulerAction next_action = 1;
1939 if (cached_has_bits & 0x00000001u) {
1940 target = stream->EnsureSpace(target);
1941 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1942 1, this->_internal_next_action(), target);
1943 }
1944
1945 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.BeginImplFrameState begin_impl_frame_state = 2;
1946 if (cached_has_bits & 0x00000002u) {
1947 target = stream->EnsureSpace(target);
1948 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1949 2, this->_internal_begin_impl_frame_state(), target);
1950 }
1951
1952 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.BeginMainFrameState begin_main_frame_state = 3;
1953 if (cached_has_bits & 0x00000004u) {
1954 target = stream->EnsureSpace(target);
1955 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1956 3, this->_internal_begin_main_frame_state(), target);
1957 }
1958
1959 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.LayerTreeFrameSinkState layer_tree_frame_sink_state = 4;
1960 if (cached_has_bits & 0x00000008u) {
1961 target = stream->EnsureSpace(target);
1962 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1963 4, this->_internal_layer_tree_frame_sink_state(), target);
1964 }
1965
1966 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.ForcedRedrawOnTimeoutState forced_redraw_state = 5;
1967 if (cached_has_bits & 0x00000010u) {
1968 target = stream->EnsureSpace(target);
1969 target = ::_pbi::WireFormatLite::WriteEnumToArray(
1970 5, this->_internal_forced_redraw_state(), target);
1971 }
1972
1973 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1974 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
1975 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
1976 }
1977 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1978 return target;
1979 }
1980
ByteSizeLong() const1981 size_t ChromeCompositorStateMachine_MajorState::ByteSizeLong() const {
1982 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.ChromeCompositorStateMachine.MajorState)
1983 size_t total_size = 0;
1984
1985 ::uint32_t cached_has_bits = 0;
1986 // Prevent compiler warnings about cached_has_bits being unused
1987 (void) cached_has_bits;
1988
1989 cached_has_bits = _impl_._has_bits_[0];
1990 if (cached_has_bits & 0x0000001fu) {
1991 // optional .perfetto.protos.ChromeCompositorSchedulerAction next_action = 1;
1992 if (cached_has_bits & 0x00000001u) {
1993 total_size += 1 +
1994 ::_pbi::WireFormatLite::EnumSize(this->_internal_next_action());
1995 }
1996
1997 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.BeginImplFrameState begin_impl_frame_state = 2;
1998 if (cached_has_bits & 0x00000002u) {
1999 total_size += 1 +
2000 ::_pbi::WireFormatLite::EnumSize(this->_internal_begin_impl_frame_state());
2001 }
2002
2003 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.BeginMainFrameState begin_main_frame_state = 3;
2004 if (cached_has_bits & 0x00000004u) {
2005 total_size += 1 +
2006 ::_pbi::WireFormatLite::EnumSize(this->_internal_begin_main_frame_state());
2007 }
2008
2009 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.LayerTreeFrameSinkState layer_tree_frame_sink_state = 4;
2010 if (cached_has_bits & 0x00000008u) {
2011 total_size += 1 +
2012 ::_pbi::WireFormatLite::EnumSize(this->_internal_layer_tree_frame_sink_state());
2013 }
2014
2015 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState.ForcedRedrawOnTimeoutState forced_redraw_state = 5;
2016 if (cached_has_bits & 0x00000010u) {
2017 total_size += 1 +
2018 ::_pbi::WireFormatLite::EnumSize(this->_internal_forced_redraw_state());
2019 }
2020
2021 }
2022 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
2023 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
2024 }
2025 int cached_size = ::_pbi::ToCachedSize(total_size);
2026 SetCachedSize(cached_size);
2027 return total_size;
2028 }
2029
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)2030 void ChromeCompositorStateMachine_MajorState::CheckTypeAndMergeFrom(
2031 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
2032 MergeFrom(*::_pbi::DownCast<const ChromeCompositorStateMachine_MajorState*>(
2033 &from));
2034 }
2035
MergeFrom(const ChromeCompositorStateMachine_MajorState & from)2036 void ChromeCompositorStateMachine_MajorState::MergeFrom(const ChromeCompositorStateMachine_MajorState& from) {
2037 ChromeCompositorStateMachine_MajorState* const _this = this;
2038 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.ChromeCompositorStateMachine.MajorState)
2039 GOOGLE_DCHECK_NE(&from, _this);
2040 ::uint32_t cached_has_bits = 0;
2041 (void) cached_has_bits;
2042
2043 cached_has_bits = from._impl_._has_bits_[0];
2044 if (cached_has_bits & 0x0000001fu) {
2045 if (cached_has_bits & 0x00000001u) {
2046 _this->_impl_.next_action_ = from._impl_.next_action_;
2047 }
2048 if (cached_has_bits & 0x00000002u) {
2049 _this->_impl_.begin_impl_frame_state_ = from._impl_.begin_impl_frame_state_;
2050 }
2051 if (cached_has_bits & 0x00000004u) {
2052 _this->_impl_.begin_main_frame_state_ = from._impl_.begin_main_frame_state_;
2053 }
2054 if (cached_has_bits & 0x00000008u) {
2055 _this->_impl_.layer_tree_frame_sink_state_ = from._impl_.layer_tree_frame_sink_state_;
2056 }
2057 if (cached_has_bits & 0x00000010u) {
2058 _this->_impl_.forced_redraw_state_ = from._impl_.forced_redraw_state_;
2059 }
2060 _this->_impl_._has_bits_[0] |= cached_has_bits;
2061 }
2062 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2063 }
2064
CopyFrom(const ChromeCompositorStateMachine_MajorState & from)2065 void ChromeCompositorStateMachine_MajorState::CopyFrom(const ChromeCompositorStateMachine_MajorState& from) {
2066 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.ChromeCompositorStateMachine.MajorState)
2067 if (&from == this) return;
2068 Clear();
2069 MergeFrom(from);
2070 }
2071
IsInitialized() const2072 bool ChromeCompositorStateMachine_MajorState::IsInitialized() const {
2073 return true;
2074 }
2075
InternalSwap(ChromeCompositorStateMachine_MajorState * other)2076 void ChromeCompositorStateMachine_MajorState::InternalSwap(ChromeCompositorStateMachine_MajorState* other) {
2077 using std::swap;
2078 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
2079 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
2080 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
2081 PROTOBUF_FIELD_OFFSET(ChromeCompositorStateMachine_MajorState, _impl_.forced_redraw_state_)
2082 + sizeof(ChromeCompositorStateMachine_MajorState::_impl_.forced_redraw_state_) // NOLINT
2083 - PROTOBUF_FIELD_OFFSET(ChromeCompositorStateMachine_MajorState, _impl_.next_action_)>(
2084 reinterpret_cast<char*>(&_impl_.next_action_),
2085 reinterpret_cast<char*>(&other->_impl_.next_action_));
2086 }
2087
GetTypeName() const2088 std::string ChromeCompositorStateMachine_MajorState::GetTypeName() const {
2089 return "perfetto.protos.ChromeCompositorStateMachine.MajorState";
2090 }
2091
2092
2093 // ===================================================================
2094
2095 class ChromeCompositorStateMachine_MinorState::_Internal {
2096 public:
2097 using HasBits = decltype(std::declval<ChromeCompositorStateMachine_MinorState>()._impl_._has_bits_);
set_has_commit_count(HasBits * has_bits)2098 static void set_has_commit_count(HasBits* has_bits) {
2099 (*has_bits)[0] |= 1u;
2100 }
set_has_current_frame_number(HasBits * has_bits)2101 static void set_has_current_frame_number(HasBits* has_bits) {
2102 (*has_bits)[0] |= 2u;
2103 }
set_has_last_frame_number_submit_performed(HasBits * has_bits)2104 static void set_has_last_frame_number_submit_performed(HasBits* has_bits) {
2105 (*has_bits)[0] |= 4u;
2106 }
set_has_last_frame_number_draw_performed(HasBits * has_bits)2107 static void set_has_last_frame_number_draw_performed(HasBits* has_bits) {
2108 (*has_bits)[0] |= 8u;
2109 }
set_has_last_frame_number_begin_main_frame_sent(HasBits * has_bits)2110 static void set_has_last_frame_number_begin_main_frame_sent(HasBits* has_bits) {
2111 (*has_bits)[0] |= 16u;
2112 }
set_has_did_draw(HasBits * has_bits)2113 static void set_has_did_draw(HasBits* has_bits) {
2114 (*has_bits)[0] |= 32u;
2115 }
set_has_did_send_begin_main_frame_for_current_frame(HasBits * has_bits)2116 static void set_has_did_send_begin_main_frame_for_current_frame(HasBits* has_bits) {
2117 (*has_bits)[0] |= 64u;
2118 }
set_has_did_notify_begin_main_frame_not_expected_until(HasBits * has_bits)2119 static void set_has_did_notify_begin_main_frame_not_expected_until(HasBits* has_bits) {
2120 (*has_bits)[0] |= 128u;
2121 }
set_has_did_notify_begin_main_frame_not_expected_soon(HasBits * has_bits)2122 static void set_has_did_notify_begin_main_frame_not_expected_soon(HasBits* has_bits) {
2123 (*has_bits)[0] |= 256u;
2124 }
set_has_wants_begin_main_frame_not_expected(HasBits * has_bits)2125 static void set_has_wants_begin_main_frame_not_expected(HasBits* has_bits) {
2126 (*has_bits)[0] |= 512u;
2127 }
set_has_did_commit_during_frame(HasBits * has_bits)2128 static void set_has_did_commit_during_frame(HasBits* has_bits) {
2129 (*has_bits)[0] |= 1024u;
2130 }
set_has_did_invalidate_layer_tree_frame_sink(HasBits * has_bits)2131 static void set_has_did_invalidate_layer_tree_frame_sink(HasBits* has_bits) {
2132 (*has_bits)[0] |= 2048u;
2133 }
set_has_did_perform_impl_side_invalidaion(HasBits * has_bits)2134 static void set_has_did_perform_impl_side_invalidaion(HasBits* has_bits) {
2135 (*has_bits)[0] |= 4096u;
2136 }
set_has_did_prepare_tiles(HasBits * has_bits)2137 static void set_has_did_prepare_tiles(HasBits* has_bits) {
2138 (*has_bits)[0] |= 65536u;
2139 }
set_has_consecutive_checkerboard_animations(HasBits * has_bits)2140 static void set_has_consecutive_checkerboard_animations(HasBits* has_bits) {
2141 (*has_bits)[0] |= 8192u;
2142 }
set_has_pending_submit_frames(HasBits * has_bits)2143 static void set_has_pending_submit_frames(HasBits* has_bits) {
2144 (*has_bits)[0] |= 16384u;
2145 }
set_has_submit_frames_with_current_layer_tree_frame_sink(HasBits * has_bits)2146 static void set_has_submit_frames_with_current_layer_tree_frame_sink(HasBits* has_bits) {
2147 (*has_bits)[0] |= 32768u;
2148 }
set_has_needs_redraw(HasBits * has_bits)2149 static void set_has_needs_redraw(HasBits* has_bits) {
2150 (*has_bits)[0] |= 131072u;
2151 }
set_has_needs_prepare_tiles(HasBits * has_bits)2152 static void set_has_needs_prepare_tiles(HasBits* has_bits) {
2153 (*has_bits)[0] |= 262144u;
2154 }
set_has_needs_begin_main_frame(HasBits * has_bits)2155 static void set_has_needs_begin_main_frame(HasBits* has_bits) {
2156 (*has_bits)[0] |= 524288u;
2157 }
set_has_needs_one_begin_impl_frame(HasBits * has_bits)2158 static void set_has_needs_one_begin_impl_frame(HasBits* has_bits) {
2159 (*has_bits)[0] |= 1048576u;
2160 }
set_has_visible(HasBits * has_bits)2161 static void set_has_visible(HasBits* has_bits) {
2162 (*has_bits)[0] |= 2097152u;
2163 }
set_has_begin_frame_source_paused(HasBits * has_bits)2164 static void set_has_begin_frame_source_paused(HasBits* has_bits) {
2165 (*has_bits)[0] |= 4194304u;
2166 }
set_has_can_draw(HasBits * has_bits)2167 static void set_has_can_draw(HasBits* has_bits) {
2168 (*has_bits)[0] |= 8388608u;
2169 }
set_has_resourceless_draw(HasBits * has_bits)2170 static void set_has_resourceless_draw(HasBits* has_bits) {
2171 (*has_bits)[0] |= 16777216u;
2172 }
set_has_has_pending_tree(HasBits * has_bits)2173 static void set_has_has_pending_tree(HasBits* has_bits) {
2174 (*has_bits)[0] |= 33554432u;
2175 }
set_has_pending_tree_is_ready_for_activation(HasBits * has_bits)2176 static void set_has_pending_tree_is_ready_for_activation(HasBits* has_bits) {
2177 (*has_bits)[0] |= 67108864u;
2178 }
set_has_active_tree_needs_first_draw(HasBits * has_bits)2179 static void set_has_active_tree_needs_first_draw(HasBits* has_bits) {
2180 (*has_bits)[0] |= 134217728u;
2181 }
set_has_active_tree_is_ready_to_draw(HasBits * has_bits)2182 static void set_has_active_tree_is_ready_to_draw(HasBits* has_bits) {
2183 (*has_bits)[0] |= 536870912u;
2184 }
set_has_did_create_and_initialize_first_layer_tree_frame_sink(HasBits * has_bits)2185 static void set_has_did_create_and_initialize_first_layer_tree_frame_sink(HasBits* has_bits) {
2186 (*has_bits)[0] |= 1073741824u;
2187 }
set_has_tree_priority(HasBits * has_bits)2188 static void set_has_tree_priority(HasBits* has_bits) {
2189 (*has_bits)[0] |= 268435456u;
2190 }
set_has_scroll_handler_state(HasBits * has_bits)2191 static void set_has_scroll_handler_state(HasBits* has_bits) {
2192 (*has_bits)[1] |= 2u;
2193 }
set_has_critical_begin_main_frame_to_activate_is_fast(HasBits * has_bits)2194 static void set_has_critical_begin_main_frame_to_activate_is_fast(HasBits* has_bits) {
2195 (*has_bits)[0] |= 2147483648u;
2196 }
set_has_main_thread_missed_last_deadline(HasBits * has_bits)2197 static void set_has_main_thread_missed_last_deadline(HasBits* has_bits) {
2198 (*has_bits)[1] |= 1u;
2199 }
set_has_video_needs_begin_frames(HasBits * has_bits)2200 static void set_has_video_needs_begin_frames(HasBits* has_bits) {
2201 (*has_bits)[1] |= 4u;
2202 }
set_has_defer_begin_main_frame(HasBits * has_bits)2203 static void set_has_defer_begin_main_frame(HasBits* has_bits) {
2204 (*has_bits)[1] |= 8u;
2205 }
set_has_last_commit_had_no_updates(HasBits * has_bits)2206 static void set_has_last_commit_had_no_updates(HasBits* has_bits) {
2207 (*has_bits)[1] |= 16u;
2208 }
set_has_did_draw_in_last_frame(HasBits * has_bits)2209 static void set_has_did_draw_in_last_frame(HasBits* has_bits) {
2210 (*has_bits)[1] |= 32u;
2211 }
set_has_did_submit_in_last_frame(HasBits * has_bits)2212 static void set_has_did_submit_in_last_frame(HasBits* has_bits) {
2213 (*has_bits)[1] |= 64u;
2214 }
set_has_needs_impl_side_invalidation(HasBits * has_bits)2215 static void set_has_needs_impl_side_invalidation(HasBits* has_bits) {
2216 (*has_bits)[1] |= 128u;
2217 }
set_has_current_pending_tree_is_impl_side(HasBits * has_bits)2218 static void set_has_current_pending_tree_is_impl_side(HasBits* has_bits) {
2219 (*has_bits)[1] |= 256u;
2220 }
set_has_previous_pending_tree_was_impl_side(HasBits * has_bits)2221 static void set_has_previous_pending_tree_was_impl_side(HasBits* has_bits) {
2222 (*has_bits)[1] |= 512u;
2223 }
set_has_processing_animation_worklets_for_active_tree(HasBits * has_bits)2224 static void set_has_processing_animation_worklets_for_active_tree(HasBits* has_bits) {
2225 (*has_bits)[1] |= 1024u;
2226 }
set_has_processing_animation_worklets_for_pending_tree(HasBits * has_bits)2227 static void set_has_processing_animation_worklets_for_pending_tree(HasBits* has_bits) {
2228 (*has_bits)[1] |= 2048u;
2229 }
set_has_processing_paint_worklets_for_pending_tree(HasBits * has_bits)2230 static void set_has_processing_paint_worklets_for_pending_tree(HasBits* has_bits) {
2231 (*has_bits)[1] |= 4096u;
2232 }
2233 };
2234
ChromeCompositorStateMachine_MinorState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)2235 ChromeCompositorStateMachine_MinorState::ChromeCompositorStateMachine_MinorState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
2236 bool is_message_owned)
2237 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
2238 SharedCtor(arena, is_message_owned);
2239 // @@protoc_insertion_point(arena_constructor:perfetto.protos.ChromeCompositorStateMachine.MinorState)
2240 }
ChromeCompositorStateMachine_MinorState(const ChromeCompositorStateMachine_MinorState & from)2241 ChromeCompositorStateMachine_MinorState::ChromeCompositorStateMachine_MinorState(const ChromeCompositorStateMachine_MinorState& from)
2242 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
2243 ChromeCompositorStateMachine_MinorState* const _this = this; (void)_this;
2244 new (&_impl_) Impl_{
2245 decltype(_impl_._has_bits_){from._impl_._has_bits_}
2246 , /*decltype(_impl_._cached_size_)*/{}
2247 , decltype(_impl_.commit_count_){}
2248 , decltype(_impl_.current_frame_number_){}
2249 , decltype(_impl_.last_frame_number_submit_performed_){}
2250 , decltype(_impl_.last_frame_number_draw_performed_){}
2251 , decltype(_impl_.last_frame_number_begin_main_frame_sent_){}
2252 , decltype(_impl_.did_draw_){}
2253 , decltype(_impl_.did_send_begin_main_frame_for_current_frame_){}
2254 , decltype(_impl_.did_notify_begin_main_frame_not_expected_until_){}
2255 , decltype(_impl_.did_notify_begin_main_frame_not_expected_soon_){}
2256 , decltype(_impl_.wants_begin_main_frame_not_expected_){}
2257 , decltype(_impl_.did_commit_during_frame_){}
2258 , decltype(_impl_.did_invalidate_layer_tree_frame_sink_){}
2259 , decltype(_impl_.did_perform_impl_side_invalidaion_){}
2260 , decltype(_impl_.consecutive_checkerboard_animations_){}
2261 , decltype(_impl_.pending_submit_frames_){}
2262 , decltype(_impl_.submit_frames_with_current_layer_tree_frame_sink_){}
2263 , decltype(_impl_.did_prepare_tiles_){}
2264 , decltype(_impl_.needs_redraw_){}
2265 , decltype(_impl_.needs_prepare_tiles_){}
2266 , decltype(_impl_.needs_begin_main_frame_){}
2267 , decltype(_impl_.needs_one_begin_impl_frame_){}
2268 , decltype(_impl_.visible_){}
2269 , decltype(_impl_.begin_frame_source_paused_){}
2270 , decltype(_impl_.can_draw_){}
2271 , decltype(_impl_.resourceless_draw_){}
2272 , decltype(_impl_.has_pending_tree_){}
2273 , decltype(_impl_.pending_tree_is_ready_for_activation_){}
2274 , decltype(_impl_.active_tree_needs_first_draw_){}
2275 , decltype(_impl_.tree_priority_){}
2276 , decltype(_impl_.active_tree_is_ready_to_draw_){}
2277 , decltype(_impl_.did_create_and_initialize_first_layer_tree_frame_sink_){}
2278 , decltype(_impl_.critical_begin_main_frame_to_activate_is_fast_){}
2279 , decltype(_impl_.main_thread_missed_last_deadline_){}
2280 , decltype(_impl_.scroll_handler_state_){}
2281 , decltype(_impl_.video_needs_begin_frames_){}
2282 , decltype(_impl_.defer_begin_main_frame_){}
2283 , decltype(_impl_.last_commit_had_no_updates_){}
2284 , decltype(_impl_.did_draw_in_last_frame_){}
2285 , decltype(_impl_.did_submit_in_last_frame_){}
2286 , decltype(_impl_.needs_impl_side_invalidation_){}
2287 , decltype(_impl_.current_pending_tree_is_impl_side_){}
2288 , decltype(_impl_.previous_pending_tree_was_impl_side_){}
2289 , decltype(_impl_.processing_animation_worklets_for_active_tree_){}
2290 , decltype(_impl_.processing_animation_worklets_for_pending_tree_){}
2291 , decltype(_impl_.processing_paint_worklets_for_pending_tree_){}};
2292
2293 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2294 ::memcpy(&_impl_.commit_count_, &from._impl_.commit_count_,
2295 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.processing_paint_worklets_for_pending_tree_) -
2296 reinterpret_cast<char*>(&_impl_.commit_count_)) + sizeof(_impl_.processing_paint_worklets_for_pending_tree_));
2297 // @@protoc_insertion_point(copy_constructor:perfetto.protos.ChromeCompositorStateMachine.MinorState)
2298 }
2299
SharedCtor(::_pb::Arena * arena,bool is_message_owned)2300 inline void ChromeCompositorStateMachine_MinorState::SharedCtor(
2301 ::_pb::Arena* arena, bool is_message_owned) {
2302 (void)arena;
2303 (void)is_message_owned;
2304 new (&_impl_) Impl_{
2305 decltype(_impl_._has_bits_){}
2306 , /*decltype(_impl_._cached_size_)*/{}
2307 , decltype(_impl_.commit_count_){0}
2308 , decltype(_impl_.current_frame_number_){0}
2309 , decltype(_impl_.last_frame_number_submit_performed_){0}
2310 , decltype(_impl_.last_frame_number_draw_performed_){0}
2311 , decltype(_impl_.last_frame_number_begin_main_frame_sent_){0}
2312 , decltype(_impl_.did_draw_){false}
2313 , decltype(_impl_.did_send_begin_main_frame_for_current_frame_){false}
2314 , decltype(_impl_.did_notify_begin_main_frame_not_expected_until_){false}
2315 , decltype(_impl_.did_notify_begin_main_frame_not_expected_soon_){false}
2316 , decltype(_impl_.wants_begin_main_frame_not_expected_){false}
2317 , decltype(_impl_.did_commit_during_frame_){false}
2318 , decltype(_impl_.did_invalidate_layer_tree_frame_sink_){false}
2319 , decltype(_impl_.did_perform_impl_side_invalidaion_){false}
2320 , decltype(_impl_.consecutive_checkerboard_animations_){0}
2321 , decltype(_impl_.pending_submit_frames_){0}
2322 , decltype(_impl_.submit_frames_with_current_layer_tree_frame_sink_){0}
2323 , decltype(_impl_.did_prepare_tiles_){false}
2324 , decltype(_impl_.needs_redraw_){false}
2325 , decltype(_impl_.needs_prepare_tiles_){false}
2326 , decltype(_impl_.needs_begin_main_frame_){false}
2327 , decltype(_impl_.needs_one_begin_impl_frame_){false}
2328 , decltype(_impl_.visible_){false}
2329 , decltype(_impl_.begin_frame_source_paused_){false}
2330 , decltype(_impl_.can_draw_){false}
2331 , decltype(_impl_.resourceless_draw_){false}
2332 , decltype(_impl_.has_pending_tree_){false}
2333 , decltype(_impl_.pending_tree_is_ready_for_activation_){false}
2334 , decltype(_impl_.active_tree_needs_first_draw_){false}
2335 , decltype(_impl_.tree_priority_){0}
2336 , decltype(_impl_.active_tree_is_ready_to_draw_){false}
2337 , decltype(_impl_.did_create_and_initialize_first_layer_tree_frame_sink_){false}
2338 , decltype(_impl_.critical_begin_main_frame_to_activate_is_fast_){false}
2339 , decltype(_impl_.main_thread_missed_last_deadline_){false}
2340 , decltype(_impl_.scroll_handler_state_){0}
2341 , decltype(_impl_.video_needs_begin_frames_){false}
2342 , decltype(_impl_.defer_begin_main_frame_){false}
2343 , decltype(_impl_.last_commit_had_no_updates_){false}
2344 , decltype(_impl_.did_draw_in_last_frame_){false}
2345 , decltype(_impl_.did_submit_in_last_frame_){false}
2346 , decltype(_impl_.needs_impl_side_invalidation_){false}
2347 , decltype(_impl_.current_pending_tree_is_impl_side_){false}
2348 , decltype(_impl_.previous_pending_tree_was_impl_side_){false}
2349 , decltype(_impl_.processing_animation_worklets_for_active_tree_){false}
2350 , decltype(_impl_.processing_animation_worklets_for_pending_tree_){false}
2351 , decltype(_impl_.processing_paint_worklets_for_pending_tree_){false}
2352 };
2353 }
2354
~ChromeCompositorStateMachine_MinorState()2355 ChromeCompositorStateMachine_MinorState::~ChromeCompositorStateMachine_MinorState() {
2356 // @@protoc_insertion_point(destructor:perfetto.protos.ChromeCompositorStateMachine.MinorState)
2357 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
2358 (void)arena;
2359 return;
2360 }
2361 SharedDtor();
2362 }
2363
SharedDtor()2364 inline void ChromeCompositorStateMachine_MinorState::SharedDtor() {
2365 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
2366 }
2367
SetCachedSize(int size) const2368 void ChromeCompositorStateMachine_MinorState::SetCachedSize(int size) const {
2369 _impl_._cached_size_.Set(size);
2370 }
2371
Clear()2372 void ChromeCompositorStateMachine_MinorState::Clear() {
2373 // @@protoc_insertion_point(message_clear_start:perfetto.protos.ChromeCompositorStateMachine.MinorState)
2374 ::uint32_t cached_has_bits = 0;
2375 // Prevent compiler warnings about cached_has_bits being unused
2376 (void) cached_has_bits;
2377
2378 cached_has_bits = _impl_._has_bits_[0];
2379 if (cached_has_bits & 0x000000ffu) {
2380 ::memset(&_impl_.commit_count_, 0, static_cast<size_t>(
2381 reinterpret_cast<char*>(&_impl_.did_notify_begin_main_frame_not_expected_until_) -
2382 reinterpret_cast<char*>(&_impl_.commit_count_)) + sizeof(_impl_.did_notify_begin_main_frame_not_expected_until_));
2383 }
2384 if (cached_has_bits & 0x0000ff00u) {
2385 ::memset(&_impl_.did_notify_begin_main_frame_not_expected_soon_, 0, static_cast<size_t>(
2386 reinterpret_cast<char*>(&_impl_.submit_frames_with_current_layer_tree_frame_sink_) -
2387 reinterpret_cast<char*>(&_impl_.did_notify_begin_main_frame_not_expected_soon_)) + sizeof(_impl_.submit_frames_with_current_layer_tree_frame_sink_));
2388 }
2389 if (cached_has_bits & 0x00ff0000u) {
2390 ::memset(&_impl_.did_prepare_tiles_, 0, static_cast<size_t>(
2391 reinterpret_cast<char*>(&_impl_.can_draw_) -
2392 reinterpret_cast<char*>(&_impl_.did_prepare_tiles_)) + sizeof(_impl_.can_draw_));
2393 }
2394 if (cached_has_bits & 0xff000000u) {
2395 ::memset(&_impl_.resourceless_draw_, 0, static_cast<size_t>(
2396 reinterpret_cast<char*>(&_impl_.critical_begin_main_frame_to_activate_is_fast_) -
2397 reinterpret_cast<char*>(&_impl_.resourceless_draw_)) + sizeof(_impl_.critical_begin_main_frame_to_activate_is_fast_));
2398 }
2399 cached_has_bits = _impl_._has_bits_[1];
2400 if (cached_has_bits & 0x000000ffu) {
2401 ::memset(&_impl_.main_thread_missed_last_deadline_, 0, static_cast<size_t>(
2402 reinterpret_cast<char*>(&_impl_.needs_impl_side_invalidation_) -
2403 reinterpret_cast<char*>(&_impl_.main_thread_missed_last_deadline_)) + sizeof(_impl_.needs_impl_side_invalidation_));
2404 }
2405 if (cached_has_bits & 0x00001f00u) {
2406 ::memset(&_impl_.current_pending_tree_is_impl_side_, 0, static_cast<size_t>(
2407 reinterpret_cast<char*>(&_impl_.processing_paint_worklets_for_pending_tree_) -
2408 reinterpret_cast<char*>(&_impl_.current_pending_tree_is_impl_side_)) + sizeof(_impl_.processing_paint_worklets_for_pending_tree_));
2409 }
2410 _impl_._has_bits_.Clear();
2411 _internal_metadata_.Clear<std::string>();
2412 }
2413
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)2414 const char* ChromeCompositorStateMachine_MinorState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
2415 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
2416 while (!ctx->Done(&ptr)) {
2417 ::uint32_t tag;
2418 ptr = ::_pbi::ReadTag(ptr, &tag);
2419 switch (tag >> 3) {
2420 // optional int32 commit_count = 1;
2421 case 1:
2422 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
2423 _Internal::set_has_commit_count(&_impl_._has_bits_);
2424 _impl_.commit_count_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2425 CHK_(ptr);
2426 } else {
2427 goto handle_unusual;
2428 }
2429 continue;
2430 // optional int32 current_frame_number = 2;
2431 case 2:
2432 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
2433 _Internal::set_has_current_frame_number(&_impl_._has_bits_);
2434 _impl_.current_frame_number_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2435 CHK_(ptr);
2436 } else {
2437 goto handle_unusual;
2438 }
2439 continue;
2440 // optional int32 last_frame_number_submit_performed = 3;
2441 case 3:
2442 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
2443 _Internal::set_has_last_frame_number_submit_performed(&_impl_._has_bits_);
2444 _impl_.last_frame_number_submit_performed_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2445 CHK_(ptr);
2446 } else {
2447 goto handle_unusual;
2448 }
2449 continue;
2450 // optional int32 last_frame_number_draw_performed = 4;
2451 case 4:
2452 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
2453 _Internal::set_has_last_frame_number_draw_performed(&_impl_._has_bits_);
2454 _impl_.last_frame_number_draw_performed_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2455 CHK_(ptr);
2456 } else {
2457 goto handle_unusual;
2458 }
2459 continue;
2460 // optional int32 last_frame_number_begin_main_frame_sent = 5;
2461 case 5:
2462 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
2463 _Internal::set_has_last_frame_number_begin_main_frame_sent(&_impl_._has_bits_);
2464 _impl_.last_frame_number_begin_main_frame_sent_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2465 CHK_(ptr);
2466 } else {
2467 goto handle_unusual;
2468 }
2469 continue;
2470 // optional bool did_draw = 6;
2471 case 6:
2472 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
2473 _Internal::set_has_did_draw(&_impl_._has_bits_);
2474 _impl_.did_draw_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2475 CHK_(ptr);
2476 } else {
2477 goto handle_unusual;
2478 }
2479 continue;
2480 // optional bool did_send_begin_main_frame_for_current_frame = 7;
2481 case 7:
2482 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
2483 _Internal::set_has_did_send_begin_main_frame_for_current_frame(&_impl_._has_bits_);
2484 _impl_.did_send_begin_main_frame_for_current_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2485 CHK_(ptr);
2486 } else {
2487 goto handle_unusual;
2488 }
2489 continue;
2490 // optional bool did_notify_begin_main_frame_not_expected_until = 8;
2491 case 8:
2492 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
2493 _Internal::set_has_did_notify_begin_main_frame_not_expected_until(&_impl_._has_bits_);
2494 _impl_.did_notify_begin_main_frame_not_expected_until_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2495 CHK_(ptr);
2496 } else {
2497 goto handle_unusual;
2498 }
2499 continue;
2500 // optional bool did_notify_begin_main_frame_not_expected_soon = 9;
2501 case 9:
2502 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
2503 _Internal::set_has_did_notify_begin_main_frame_not_expected_soon(&_impl_._has_bits_);
2504 _impl_.did_notify_begin_main_frame_not_expected_soon_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2505 CHK_(ptr);
2506 } else {
2507 goto handle_unusual;
2508 }
2509 continue;
2510 // optional bool wants_begin_main_frame_not_expected = 10;
2511 case 10:
2512 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 80)) {
2513 _Internal::set_has_wants_begin_main_frame_not_expected(&_impl_._has_bits_);
2514 _impl_.wants_begin_main_frame_not_expected_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2515 CHK_(ptr);
2516 } else {
2517 goto handle_unusual;
2518 }
2519 continue;
2520 // optional bool did_commit_during_frame = 11;
2521 case 11:
2522 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 88)) {
2523 _Internal::set_has_did_commit_during_frame(&_impl_._has_bits_);
2524 _impl_.did_commit_during_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2525 CHK_(ptr);
2526 } else {
2527 goto handle_unusual;
2528 }
2529 continue;
2530 // optional bool did_invalidate_layer_tree_frame_sink = 12;
2531 case 12:
2532 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 96)) {
2533 _Internal::set_has_did_invalidate_layer_tree_frame_sink(&_impl_._has_bits_);
2534 _impl_.did_invalidate_layer_tree_frame_sink_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2535 CHK_(ptr);
2536 } else {
2537 goto handle_unusual;
2538 }
2539 continue;
2540 // optional bool did_perform_impl_side_invalidaion = 13;
2541 case 13:
2542 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 104)) {
2543 _Internal::set_has_did_perform_impl_side_invalidaion(&_impl_._has_bits_);
2544 _impl_.did_perform_impl_side_invalidaion_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2545 CHK_(ptr);
2546 } else {
2547 goto handle_unusual;
2548 }
2549 continue;
2550 // optional bool did_prepare_tiles = 14;
2551 case 14:
2552 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 112)) {
2553 _Internal::set_has_did_prepare_tiles(&_impl_._has_bits_);
2554 _impl_.did_prepare_tiles_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2555 CHK_(ptr);
2556 } else {
2557 goto handle_unusual;
2558 }
2559 continue;
2560 // optional int32 consecutive_checkerboard_animations = 15;
2561 case 15:
2562 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 120)) {
2563 _Internal::set_has_consecutive_checkerboard_animations(&_impl_._has_bits_);
2564 _impl_.consecutive_checkerboard_animations_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2565 CHK_(ptr);
2566 } else {
2567 goto handle_unusual;
2568 }
2569 continue;
2570 // optional int32 pending_submit_frames = 16;
2571 case 16:
2572 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 128)) {
2573 _Internal::set_has_pending_submit_frames(&_impl_._has_bits_);
2574 _impl_.pending_submit_frames_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2575 CHK_(ptr);
2576 } else {
2577 goto handle_unusual;
2578 }
2579 continue;
2580 // optional int32 submit_frames_with_current_layer_tree_frame_sink = 17;
2581 case 17:
2582 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 136)) {
2583 _Internal::set_has_submit_frames_with_current_layer_tree_frame_sink(&_impl_._has_bits_);
2584 _impl_.submit_frames_with_current_layer_tree_frame_sink_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2585 CHK_(ptr);
2586 } else {
2587 goto handle_unusual;
2588 }
2589 continue;
2590 // optional bool needs_redraw = 18;
2591 case 18:
2592 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 144)) {
2593 _Internal::set_has_needs_redraw(&_impl_._has_bits_);
2594 _impl_.needs_redraw_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2595 CHK_(ptr);
2596 } else {
2597 goto handle_unusual;
2598 }
2599 continue;
2600 // optional bool needs_prepare_tiles = 19;
2601 case 19:
2602 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 152)) {
2603 _Internal::set_has_needs_prepare_tiles(&_impl_._has_bits_);
2604 _impl_.needs_prepare_tiles_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2605 CHK_(ptr);
2606 } else {
2607 goto handle_unusual;
2608 }
2609 continue;
2610 // optional bool needs_begin_main_frame = 20;
2611 case 20:
2612 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 160)) {
2613 _Internal::set_has_needs_begin_main_frame(&_impl_._has_bits_);
2614 _impl_.needs_begin_main_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2615 CHK_(ptr);
2616 } else {
2617 goto handle_unusual;
2618 }
2619 continue;
2620 // optional bool needs_one_begin_impl_frame = 21;
2621 case 21:
2622 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 168)) {
2623 _Internal::set_has_needs_one_begin_impl_frame(&_impl_._has_bits_);
2624 _impl_.needs_one_begin_impl_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2625 CHK_(ptr);
2626 } else {
2627 goto handle_unusual;
2628 }
2629 continue;
2630 // optional bool visible = 22;
2631 case 22:
2632 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 176)) {
2633 _Internal::set_has_visible(&_impl_._has_bits_);
2634 _impl_.visible_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2635 CHK_(ptr);
2636 } else {
2637 goto handle_unusual;
2638 }
2639 continue;
2640 // optional bool begin_frame_source_paused = 23;
2641 case 23:
2642 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 184)) {
2643 _Internal::set_has_begin_frame_source_paused(&_impl_._has_bits_);
2644 _impl_.begin_frame_source_paused_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2645 CHK_(ptr);
2646 } else {
2647 goto handle_unusual;
2648 }
2649 continue;
2650 // optional bool can_draw = 24;
2651 case 24:
2652 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 192)) {
2653 _Internal::set_has_can_draw(&_impl_._has_bits_);
2654 _impl_.can_draw_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2655 CHK_(ptr);
2656 } else {
2657 goto handle_unusual;
2658 }
2659 continue;
2660 // optional bool resourceless_draw = 25;
2661 case 25:
2662 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 200)) {
2663 _Internal::set_has_resourceless_draw(&_impl_._has_bits_);
2664 _impl_.resourceless_draw_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2665 CHK_(ptr);
2666 } else {
2667 goto handle_unusual;
2668 }
2669 continue;
2670 // optional bool has_pending_tree = 26;
2671 case 26:
2672 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 208)) {
2673 _Internal::set_has_has_pending_tree(&_impl_._has_bits_);
2674 _impl_.has_pending_tree_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2675 CHK_(ptr);
2676 } else {
2677 goto handle_unusual;
2678 }
2679 continue;
2680 // optional bool pending_tree_is_ready_for_activation = 27;
2681 case 27:
2682 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 216)) {
2683 _Internal::set_has_pending_tree_is_ready_for_activation(&_impl_._has_bits_);
2684 _impl_.pending_tree_is_ready_for_activation_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2685 CHK_(ptr);
2686 } else {
2687 goto handle_unusual;
2688 }
2689 continue;
2690 // optional bool active_tree_needs_first_draw = 28;
2691 case 28:
2692 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 224)) {
2693 _Internal::set_has_active_tree_needs_first_draw(&_impl_._has_bits_);
2694 _impl_.active_tree_needs_first_draw_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2695 CHK_(ptr);
2696 } else {
2697 goto handle_unusual;
2698 }
2699 continue;
2700 // optional bool active_tree_is_ready_to_draw = 29;
2701 case 29:
2702 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 232)) {
2703 _Internal::set_has_active_tree_is_ready_to_draw(&_impl_._has_bits_);
2704 _impl_.active_tree_is_ready_to_draw_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2705 CHK_(ptr);
2706 } else {
2707 goto handle_unusual;
2708 }
2709 continue;
2710 // optional bool did_create_and_initialize_first_layer_tree_frame_sink = 30;
2711 case 30:
2712 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 240)) {
2713 _Internal::set_has_did_create_and_initialize_first_layer_tree_frame_sink(&_impl_._has_bits_);
2714 _impl_.did_create_and_initialize_first_layer_tree_frame_sink_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2715 CHK_(ptr);
2716 } else {
2717 goto handle_unusual;
2718 }
2719 continue;
2720 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState.TreePriority tree_priority = 31;
2721 case 31:
2722 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 248)) {
2723 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2724 CHK_(ptr);
2725 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorStateMachine_MinorState_TreePriority_IsValid(val))) {
2726 _internal_set_tree_priority(static_cast<::perfetto::protos::ChromeCompositorStateMachine_MinorState_TreePriority>(val));
2727 } else {
2728 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(31, val, mutable_unknown_fields());
2729 }
2730 } else {
2731 goto handle_unusual;
2732 }
2733 continue;
2734 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState.ScrollHandlerState scroll_handler_state = 32;
2735 case 32:
2736 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 0)) {
2737 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2738 CHK_(ptr);
2739 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::ChromeCompositorStateMachine_MinorState_ScrollHandlerState_IsValid(val))) {
2740 _internal_set_scroll_handler_state(static_cast<::perfetto::protos::ChromeCompositorStateMachine_MinorState_ScrollHandlerState>(val));
2741 } else {
2742 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(32, val, mutable_unknown_fields());
2743 }
2744 } else {
2745 goto handle_unusual;
2746 }
2747 continue;
2748 // optional bool critical_begin_main_frame_to_activate_is_fast = 33;
2749 case 33:
2750 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
2751 _Internal::set_has_critical_begin_main_frame_to_activate_is_fast(&_impl_._has_bits_);
2752 _impl_.critical_begin_main_frame_to_activate_is_fast_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2753 CHK_(ptr);
2754 } else {
2755 goto handle_unusual;
2756 }
2757 continue;
2758 // optional bool main_thread_missed_last_deadline = 34;
2759 case 34:
2760 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
2761 _Internal::set_has_main_thread_missed_last_deadline(&_impl_._has_bits_);
2762 _impl_.main_thread_missed_last_deadline_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2763 CHK_(ptr);
2764 } else {
2765 goto handle_unusual;
2766 }
2767 continue;
2768 // optional bool video_needs_begin_frames = 36;
2769 case 36:
2770 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
2771 _Internal::set_has_video_needs_begin_frames(&_impl_._has_bits_);
2772 _impl_.video_needs_begin_frames_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2773 CHK_(ptr);
2774 } else {
2775 goto handle_unusual;
2776 }
2777 continue;
2778 // optional bool defer_begin_main_frame = 37;
2779 case 37:
2780 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
2781 _Internal::set_has_defer_begin_main_frame(&_impl_._has_bits_);
2782 _impl_.defer_begin_main_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2783 CHK_(ptr);
2784 } else {
2785 goto handle_unusual;
2786 }
2787 continue;
2788 // optional bool last_commit_had_no_updates = 38;
2789 case 38:
2790 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
2791 _Internal::set_has_last_commit_had_no_updates(&_impl_._has_bits_);
2792 _impl_.last_commit_had_no_updates_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2793 CHK_(ptr);
2794 } else {
2795 goto handle_unusual;
2796 }
2797 continue;
2798 // optional bool did_draw_in_last_frame = 39;
2799 case 39:
2800 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
2801 _Internal::set_has_did_draw_in_last_frame(&_impl_._has_bits_);
2802 _impl_.did_draw_in_last_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2803 CHK_(ptr);
2804 } else {
2805 goto handle_unusual;
2806 }
2807 continue;
2808 // optional bool did_submit_in_last_frame = 40;
2809 case 40:
2810 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
2811 _Internal::set_has_did_submit_in_last_frame(&_impl_._has_bits_);
2812 _impl_.did_submit_in_last_frame_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2813 CHK_(ptr);
2814 } else {
2815 goto handle_unusual;
2816 }
2817 continue;
2818 // optional bool needs_impl_side_invalidation = 41;
2819 case 41:
2820 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
2821 _Internal::set_has_needs_impl_side_invalidation(&_impl_._has_bits_);
2822 _impl_.needs_impl_side_invalidation_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2823 CHK_(ptr);
2824 } else {
2825 goto handle_unusual;
2826 }
2827 continue;
2828 // optional bool current_pending_tree_is_impl_side = 42;
2829 case 42:
2830 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 80)) {
2831 _Internal::set_has_current_pending_tree_is_impl_side(&_impl_._has_bits_);
2832 _impl_.current_pending_tree_is_impl_side_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2833 CHK_(ptr);
2834 } else {
2835 goto handle_unusual;
2836 }
2837 continue;
2838 // optional bool previous_pending_tree_was_impl_side = 43;
2839 case 43:
2840 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 88)) {
2841 _Internal::set_has_previous_pending_tree_was_impl_side(&_impl_._has_bits_);
2842 _impl_.previous_pending_tree_was_impl_side_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2843 CHK_(ptr);
2844 } else {
2845 goto handle_unusual;
2846 }
2847 continue;
2848 // optional bool processing_animation_worklets_for_active_tree = 44;
2849 case 44:
2850 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 96)) {
2851 _Internal::set_has_processing_animation_worklets_for_active_tree(&_impl_._has_bits_);
2852 _impl_.processing_animation_worklets_for_active_tree_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2853 CHK_(ptr);
2854 } else {
2855 goto handle_unusual;
2856 }
2857 continue;
2858 // optional bool processing_animation_worklets_for_pending_tree = 45;
2859 case 45:
2860 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 104)) {
2861 _Internal::set_has_processing_animation_worklets_for_pending_tree(&_impl_._has_bits_);
2862 _impl_.processing_animation_worklets_for_pending_tree_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2863 CHK_(ptr);
2864 } else {
2865 goto handle_unusual;
2866 }
2867 continue;
2868 // optional bool processing_paint_worklets_for_pending_tree = 46;
2869 case 46:
2870 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 112)) {
2871 _Internal::set_has_processing_paint_worklets_for_pending_tree(&_impl_._has_bits_);
2872 _impl_.processing_paint_worklets_for_pending_tree_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2873 CHK_(ptr);
2874 } else {
2875 goto handle_unusual;
2876 }
2877 continue;
2878 default:
2879 goto handle_unusual;
2880 } // switch
2881 handle_unusual:
2882 if ((tag == 0) || ((tag & 7) == 4)) {
2883 CHK_(ptr);
2884 ctx->SetLastTag(tag);
2885 goto message_done;
2886 }
2887 ptr = UnknownFieldParse(
2888 tag,
2889 _internal_metadata_.mutable_unknown_fields<std::string>(),
2890 ptr, ctx);
2891 CHK_(ptr != nullptr);
2892 } // while
2893 message_done:
2894 return ptr;
2895 failure:
2896 ptr = nullptr;
2897 goto message_done;
2898 #undef CHK_
2899 }
2900
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const2901 ::uint8_t* ChromeCompositorStateMachine_MinorState::_InternalSerialize(
2902 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
2903 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.ChromeCompositorStateMachine.MinorState)
2904 ::uint32_t cached_has_bits = 0;
2905 (void) cached_has_bits;
2906
2907 cached_has_bits = _impl_._has_bits_[0];
2908 // optional int32 commit_count = 1;
2909 if (cached_has_bits & 0x00000001u) {
2910 target = stream->EnsureSpace(target);
2911 target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_commit_count(), target);
2912 }
2913
2914 // optional int32 current_frame_number = 2;
2915 if (cached_has_bits & 0x00000002u) {
2916 target = stream->EnsureSpace(target);
2917 target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_current_frame_number(), target);
2918 }
2919
2920 // optional int32 last_frame_number_submit_performed = 3;
2921 if (cached_has_bits & 0x00000004u) {
2922 target = stream->EnsureSpace(target);
2923 target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_last_frame_number_submit_performed(), target);
2924 }
2925
2926 // optional int32 last_frame_number_draw_performed = 4;
2927 if (cached_has_bits & 0x00000008u) {
2928 target = stream->EnsureSpace(target);
2929 target = ::_pbi::WireFormatLite::WriteInt32ToArray(4, this->_internal_last_frame_number_draw_performed(), target);
2930 }
2931
2932 // optional int32 last_frame_number_begin_main_frame_sent = 5;
2933 if (cached_has_bits & 0x00000010u) {
2934 target = stream->EnsureSpace(target);
2935 target = ::_pbi::WireFormatLite::WriteInt32ToArray(5, this->_internal_last_frame_number_begin_main_frame_sent(), target);
2936 }
2937
2938 // optional bool did_draw = 6;
2939 if (cached_has_bits & 0x00000020u) {
2940 target = stream->EnsureSpace(target);
2941 target = ::_pbi::WireFormatLite::WriteBoolToArray(6, this->_internal_did_draw(), target);
2942 }
2943
2944 // optional bool did_send_begin_main_frame_for_current_frame = 7;
2945 if (cached_has_bits & 0x00000040u) {
2946 target = stream->EnsureSpace(target);
2947 target = ::_pbi::WireFormatLite::WriteBoolToArray(7, this->_internal_did_send_begin_main_frame_for_current_frame(), target);
2948 }
2949
2950 // optional bool did_notify_begin_main_frame_not_expected_until = 8;
2951 if (cached_has_bits & 0x00000080u) {
2952 target = stream->EnsureSpace(target);
2953 target = ::_pbi::WireFormatLite::WriteBoolToArray(8, this->_internal_did_notify_begin_main_frame_not_expected_until(), target);
2954 }
2955
2956 // optional bool did_notify_begin_main_frame_not_expected_soon = 9;
2957 if (cached_has_bits & 0x00000100u) {
2958 target = stream->EnsureSpace(target);
2959 target = ::_pbi::WireFormatLite::WriteBoolToArray(9, this->_internal_did_notify_begin_main_frame_not_expected_soon(), target);
2960 }
2961
2962 // optional bool wants_begin_main_frame_not_expected = 10;
2963 if (cached_has_bits & 0x00000200u) {
2964 target = stream->EnsureSpace(target);
2965 target = ::_pbi::WireFormatLite::WriteBoolToArray(10, this->_internal_wants_begin_main_frame_not_expected(), target);
2966 }
2967
2968 // optional bool did_commit_during_frame = 11;
2969 if (cached_has_bits & 0x00000400u) {
2970 target = stream->EnsureSpace(target);
2971 target = ::_pbi::WireFormatLite::WriteBoolToArray(11, this->_internal_did_commit_during_frame(), target);
2972 }
2973
2974 // optional bool did_invalidate_layer_tree_frame_sink = 12;
2975 if (cached_has_bits & 0x00000800u) {
2976 target = stream->EnsureSpace(target);
2977 target = ::_pbi::WireFormatLite::WriteBoolToArray(12, this->_internal_did_invalidate_layer_tree_frame_sink(), target);
2978 }
2979
2980 // optional bool did_perform_impl_side_invalidaion = 13;
2981 if (cached_has_bits & 0x00001000u) {
2982 target = stream->EnsureSpace(target);
2983 target = ::_pbi::WireFormatLite::WriteBoolToArray(13, this->_internal_did_perform_impl_side_invalidaion(), target);
2984 }
2985
2986 // optional bool did_prepare_tiles = 14;
2987 if (cached_has_bits & 0x00010000u) {
2988 target = stream->EnsureSpace(target);
2989 target = ::_pbi::WireFormatLite::WriteBoolToArray(14, this->_internal_did_prepare_tiles(), target);
2990 }
2991
2992 // optional int32 consecutive_checkerboard_animations = 15;
2993 if (cached_has_bits & 0x00002000u) {
2994 target = stream->EnsureSpace(target);
2995 target = ::_pbi::WireFormatLite::WriteInt32ToArray(15, this->_internal_consecutive_checkerboard_animations(), target);
2996 }
2997
2998 // optional int32 pending_submit_frames = 16;
2999 if (cached_has_bits & 0x00004000u) {
3000 target = stream->EnsureSpace(target);
3001 target = ::_pbi::WireFormatLite::WriteInt32ToArray(16, this->_internal_pending_submit_frames(), target);
3002 }
3003
3004 // optional int32 submit_frames_with_current_layer_tree_frame_sink = 17;
3005 if (cached_has_bits & 0x00008000u) {
3006 target = stream->EnsureSpace(target);
3007 target = ::_pbi::WireFormatLite::WriteInt32ToArray(17, this->_internal_submit_frames_with_current_layer_tree_frame_sink(), target);
3008 }
3009
3010 // optional bool needs_redraw = 18;
3011 if (cached_has_bits & 0x00020000u) {
3012 target = stream->EnsureSpace(target);
3013 target = ::_pbi::WireFormatLite::WriteBoolToArray(18, this->_internal_needs_redraw(), target);
3014 }
3015
3016 // optional bool needs_prepare_tiles = 19;
3017 if (cached_has_bits & 0x00040000u) {
3018 target = stream->EnsureSpace(target);
3019 target = ::_pbi::WireFormatLite::WriteBoolToArray(19, this->_internal_needs_prepare_tiles(), target);
3020 }
3021
3022 // optional bool needs_begin_main_frame = 20;
3023 if (cached_has_bits & 0x00080000u) {
3024 target = stream->EnsureSpace(target);
3025 target = ::_pbi::WireFormatLite::WriteBoolToArray(20, this->_internal_needs_begin_main_frame(), target);
3026 }
3027
3028 // optional bool needs_one_begin_impl_frame = 21;
3029 if (cached_has_bits & 0x00100000u) {
3030 target = stream->EnsureSpace(target);
3031 target = ::_pbi::WireFormatLite::WriteBoolToArray(21, this->_internal_needs_one_begin_impl_frame(), target);
3032 }
3033
3034 // optional bool visible = 22;
3035 if (cached_has_bits & 0x00200000u) {
3036 target = stream->EnsureSpace(target);
3037 target = ::_pbi::WireFormatLite::WriteBoolToArray(22, this->_internal_visible(), target);
3038 }
3039
3040 // optional bool begin_frame_source_paused = 23;
3041 if (cached_has_bits & 0x00400000u) {
3042 target = stream->EnsureSpace(target);
3043 target = ::_pbi::WireFormatLite::WriteBoolToArray(23, this->_internal_begin_frame_source_paused(), target);
3044 }
3045
3046 // optional bool can_draw = 24;
3047 if (cached_has_bits & 0x00800000u) {
3048 target = stream->EnsureSpace(target);
3049 target = ::_pbi::WireFormatLite::WriteBoolToArray(24, this->_internal_can_draw(), target);
3050 }
3051
3052 // optional bool resourceless_draw = 25;
3053 if (cached_has_bits & 0x01000000u) {
3054 target = stream->EnsureSpace(target);
3055 target = ::_pbi::WireFormatLite::WriteBoolToArray(25, this->_internal_resourceless_draw(), target);
3056 }
3057
3058 // optional bool has_pending_tree = 26;
3059 if (cached_has_bits & 0x02000000u) {
3060 target = stream->EnsureSpace(target);
3061 target = ::_pbi::WireFormatLite::WriteBoolToArray(26, this->_internal_has_pending_tree(), target);
3062 }
3063
3064 // optional bool pending_tree_is_ready_for_activation = 27;
3065 if (cached_has_bits & 0x04000000u) {
3066 target = stream->EnsureSpace(target);
3067 target = ::_pbi::WireFormatLite::WriteBoolToArray(27, this->_internal_pending_tree_is_ready_for_activation(), target);
3068 }
3069
3070 // optional bool active_tree_needs_first_draw = 28;
3071 if (cached_has_bits & 0x08000000u) {
3072 target = stream->EnsureSpace(target);
3073 target = ::_pbi::WireFormatLite::WriteBoolToArray(28, this->_internal_active_tree_needs_first_draw(), target);
3074 }
3075
3076 // optional bool active_tree_is_ready_to_draw = 29;
3077 if (cached_has_bits & 0x20000000u) {
3078 target = stream->EnsureSpace(target);
3079 target = ::_pbi::WireFormatLite::WriteBoolToArray(29, this->_internal_active_tree_is_ready_to_draw(), target);
3080 }
3081
3082 // optional bool did_create_and_initialize_first_layer_tree_frame_sink = 30;
3083 if (cached_has_bits & 0x40000000u) {
3084 target = stream->EnsureSpace(target);
3085 target = ::_pbi::WireFormatLite::WriteBoolToArray(30, this->_internal_did_create_and_initialize_first_layer_tree_frame_sink(), target);
3086 }
3087
3088 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState.TreePriority tree_priority = 31;
3089 if (cached_has_bits & 0x10000000u) {
3090 target = stream->EnsureSpace(target);
3091 target = ::_pbi::WireFormatLite::WriteEnumToArray(
3092 31, this->_internal_tree_priority(), target);
3093 }
3094
3095 cached_has_bits = _impl_._has_bits_[1];
3096 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState.ScrollHandlerState scroll_handler_state = 32;
3097 if (cached_has_bits & 0x00000002u) {
3098 target = stream->EnsureSpace(target);
3099 target = ::_pbi::WireFormatLite::WriteEnumToArray(
3100 32, this->_internal_scroll_handler_state(), target);
3101 }
3102
3103 cached_has_bits = _impl_._has_bits_[0];
3104 // optional bool critical_begin_main_frame_to_activate_is_fast = 33;
3105 if (cached_has_bits & 0x80000000u) {
3106 target = stream->EnsureSpace(target);
3107 target = ::_pbi::WireFormatLite::WriteBoolToArray(33, this->_internal_critical_begin_main_frame_to_activate_is_fast(), target);
3108 }
3109
3110 cached_has_bits = _impl_._has_bits_[1];
3111 // optional bool main_thread_missed_last_deadline = 34;
3112 if (cached_has_bits & 0x00000001u) {
3113 target = stream->EnsureSpace(target);
3114 target = ::_pbi::WireFormatLite::WriteBoolToArray(34, this->_internal_main_thread_missed_last_deadline(), target);
3115 }
3116
3117 // optional bool video_needs_begin_frames = 36;
3118 if (cached_has_bits & 0x00000004u) {
3119 target = stream->EnsureSpace(target);
3120 target = ::_pbi::WireFormatLite::WriteBoolToArray(36, this->_internal_video_needs_begin_frames(), target);
3121 }
3122
3123 // optional bool defer_begin_main_frame = 37;
3124 if (cached_has_bits & 0x00000008u) {
3125 target = stream->EnsureSpace(target);
3126 target = ::_pbi::WireFormatLite::WriteBoolToArray(37, this->_internal_defer_begin_main_frame(), target);
3127 }
3128
3129 // optional bool last_commit_had_no_updates = 38;
3130 if (cached_has_bits & 0x00000010u) {
3131 target = stream->EnsureSpace(target);
3132 target = ::_pbi::WireFormatLite::WriteBoolToArray(38, this->_internal_last_commit_had_no_updates(), target);
3133 }
3134
3135 // optional bool did_draw_in_last_frame = 39;
3136 if (cached_has_bits & 0x00000020u) {
3137 target = stream->EnsureSpace(target);
3138 target = ::_pbi::WireFormatLite::WriteBoolToArray(39, this->_internal_did_draw_in_last_frame(), target);
3139 }
3140
3141 // optional bool did_submit_in_last_frame = 40;
3142 if (cached_has_bits & 0x00000040u) {
3143 target = stream->EnsureSpace(target);
3144 target = ::_pbi::WireFormatLite::WriteBoolToArray(40, this->_internal_did_submit_in_last_frame(), target);
3145 }
3146
3147 // optional bool needs_impl_side_invalidation = 41;
3148 if (cached_has_bits & 0x00000080u) {
3149 target = stream->EnsureSpace(target);
3150 target = ::_pbi::WireFormatLite::WriteBoolToArray(41, this->_internal_needs_impl_side_invalidation(), target);
3151 }
3152
3153 // optional bool current_pending_tree_is_impl_side = 42;
3154 if (cached_has_bits & 0x00000100u) {
3155 target = stream->EnsureSpace(target);
3156 target = ::_pbi::WireFormatLite::WriteBoolToArray(42, this->_internal_current_pending_tree_is_impl_side(), target);
3157 }
3158
3159 // optional bool previous_pending_tree_was_impl_side = 43;
3160 if (cached_has_bits & 0x00000200u) {
3161 target = stream->EnsureSpace(target);
3162 target = ::_pbi::WireFormatLite::WriteBoolToArray(43, this->_internal_previous_pending_tree_was_impl_side(), target);
3163 }
3164
3165 // optional bool processing_animation_worklets_for_active_tree = 44;
3166 if (cached_has_bits & 0x00000400u) {
3167 target = stream->EnsureSpace(target);
3168 target = ::_pbi::WireFormatLite::WriteBoolToArray(44, this->_internal_processing_animation_worklets_for_active_tree(), target);
3169 }
3170
3171 // optional bool processing_animation_worklets_for_pending_tree = 45;
3172 if (cached_has_bits & 0x00000800u) {
3173 target = stream->EnsureSpace(target);
3174 target = ::_pbi::WireFormatLite::WriteBoolToArray(45, this->_internal_processing_animation_worklets_for_pending_tree(), target);
3175 }
3176
3177 // optional bool processing_paint_worklets_for_pending_tree = 46;
3178 if (cached_has_bits & 0x00001000u) {
3179 target = stream->EnsureSpace(target);
3180 target = ::_pbi::WireFormatLite::WriteBoolToArray(46, this->_internal_processing_paint_worklets_for_pending_tree(), target);
3181 }
3182
3183 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3184 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
3185 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
3186 }
3187 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.ChromeCompositorStateMachine.MinorState)
3188 return target;
3189 }
3190
ByteSizeLong() const3191 size_t ChromeCompositorStateMachine_MinorState::ByteSizeLong() const {
3192 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.ChromeCompositorStateMachine.MinorState)
3193 size_t total_size = 0;
3194
3195 ::uint32_t cached_has_bits = 0;
3196 // Prevent compiler warnings about cached_has_bits being unused
3197 (void) cached_has_bits;
3198
3199 cached_has_bits = _impl_._has_bits_[0];
3200 if (cached_has_bits & 0x000000ffu) {
3201 // optional int32 commit_count = 1;
3202 if (cached_has_bits & 0x00000001u) {
3203 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_commit_count());
3204 }
3205
3206 // optional int32 current_frame_number = 2;
3207 if (cached_has_bits & 0x00000002u) {
3208 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_current_frame_number());
3209 }
3210
3211 // optional int32 last_frame_number_submit_performed = 3;
3212 if (cached_has_bits & 0x00000004u) {
3213 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_last_frame_number_submit_performed());
3214 }
3215
3216 // optional int32 last_frame_number_draw_performed = 4;
3217 if (cached_has_bits & 0x00000008u) {
3218 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_last_frame_number_draw_performed());
3219 }
3220
3221 // optional int32 last_frame_number_begin_main_frame_sent = 5;
3222 if (cached_has_bits & 0x00000010u) {
3223 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_last_frame_number_begin_main_frame_sent());
3224 }
3225
3226 // optional bool did_draw = 6;
3227 if (cached_has_bits & 0x00000020u) {
3228 total_size += 1 + 1;
3229 }
3230
3231 // optional bool did_send_begin_main_frame_for_current_frame = 7;
3232 if (cached_has_bits & 0x00000040u) {
3233 total_size += 1 + 1;
3234 }
3235
3236 // optional bool did_notify_begin_main_frame_not_expected_until = 8;
3237 if (cached_has_bits & 0x00000080u) {
3238 total_size += 1 + 1;
3239 }
3240
3241 }
3242 if (cached_has_bits & 0x0000ff00u) {
3243 // optional bool did_notify_begin_main_frame_not_expected_soon = 9;
3244 if (cached_has_bits & 0x00000100u) {
3245 total_size += 1 + 1;
3246 }
3247
3248 // optional bool wants_begin_main_frame_not_expected = 10;
3249 if (cached_has_bits & 0x00000200u) {
3250 total_size += 1 + 1;
3251 }
3252
3253 // optional bool did_commit_during_frame = 11;
3254 if (cached_has_bits & 0x00000400u) {
3255 total_size += 1 + 1;
3256 }
3257
3258 // optional bool did_invalidate_layer_tree_frame_sink = 12;
3259 if (cached_has_bits & 0x00000800u) {
3260 total_size += 1 + 1;
3261 }
3262
3263 // optional bool did_perform_impl_side_invalidaion = 13;
3264 if (cached_has_bits & 0x00001000u) {
3265 total_size += 1 + 1;
3266 }
3267
3268 // optional int32 consecutive_checkerboard_animations = 15;
3269 if (cached_has_bits & 0x00002000u) {
3270 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_consecutive_checkerboard_animations());
3271 }
3272
3273 // optional int32 pending_submit_frames = 16;
3274 if (cached_has_bits & 0x00004000u) {
3275 total_size += 2 +
3276 ::_pbi::WireFormatLite::Int32Size(
3277 this->_internal_pending_submit_frames());
3278 }
3279
3280 // optional int32 submit_frames_with_current_layer_tree_frame_sink = 17;
3281 if (cached_has_bits & 0x00008000u) {
3282 total_size += 2 +
3283 ::_pbi::WireFormatLite::Int32Size(
3284 this->_internal_submit_frames_with_current_layer_tree_frame_sink());
3285 }
3286
3287 }
3288 if (cached_has_bits & 0x00ff0000u) {
3289 // optional bool did_prepare_tiles = 14;
3290 if (cached_has_bits & 0x00010000u) {
3291 total_size += 1 + 1;
3292 }
3293
3294 // optional bool needs_redraw = 18;
3295 if (cached_has_bits & 0x00020000u) {
3296 total_size += 2 + 1;
3297 }
3298
3299 // optional bool needs_prepare_tiles = 19;
3300 if (cached_has_bits & 0x00040000u) {
3301 total_size += 2 + 1;
3302 }
3303
3304 // optional bool needs_begin_main_frame = 20;
3305 if (cached_has_bits & 0x00080000u) {
3306 total_size += 2 + 1;
3307 }
3308
3309 // optional bool needs_one_begin_impl_frame = 21;
3310 if (cached_has_bits & 0x00100000u) {
3311 total_size += 2 + 1;
3312 }
3313
3314 // optional bool visible = 22;
3315 if (cached_has_bits & 0x00200000u) {
3316 total_size += 2 + 1;
3317 }
3318
3319 // optional bool begin_frame_source_paused = 23;
3320 if (cached_has_bits & 0x00400000u) {
3321 total_size += 2 + 1;
3322 }
3323
3324 // optional bool can_draw = 24;
3325 if (cached_has_bits & 0x00800000u) {
3326 total_size += 2 + 1;
3327 }
3328
3329 }
3330 if (cached_has_bits & 0xff000000u) {
3331 // optional bool resourceless_draw = 25;
3332 if (cached_has_bits & 0x01000000u) {
3333 total_size += 2 + 1;
3334 }
3335
3336 // optional bool has_pending_tree = 26;
3337 if (cached_has_bits & 0x02000000u) {
3338 total_size += 2 + 1;
3339 }
3340
3341 // optional bool pending_tree_is_ready_for_activation = 27;
3342 if (cached_has_bits & 0x04000000u) {
3343 total_size += 2 + 1;
3344 }
3345
3346 // optional bool active_tree_needs_first_draw = 28;
3347 if (cached_has_bits & 0x08000000u) {
3348 total_size += 2 + 1;
3349 }
3350
3351 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState.TreePriority tree_priority = 31;
3352 if (cached_has_bits & 0x10000000u) {
3353 total_size += 2 +
3354 ::_pbi::WireFormatLite::EnumSize(this->_internal_tree_priority());
3355 }
3356
3357 // optional bool active_tree_is_ready_to_draw = 29;
3358 if (cached_has_bits & 0x20000000u) {
3359 total_size += 2 + 1;
3360 }
3361
3362 // optional bool did_create_and_initialize_first_layer_tree_frame_sink = 30;
3363 if (cached_has_bits & 0x40000000u) {
3364 total_size += 2 + 1;
3365 }
3366
3367 // optional bool critical_begin_main_frame_to_activate_is_fast = 33;
3368 if (cached_has_bits & 0x80000000u) {
3369 total_size += 2 + 1;
3370 }
3371
3372 }
3373 cached_has_bits = _impl_._has_bits_[1];
3374 if (cached_has_bits & 0x000000ffu) {
3375 // optional bool main_thread_missed_last_deadline = 34;
3376 if (cached_has_bits & 0x00000001u) {
3377 total_size += 2 + 1;
3378 }
3379
3380 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState.ScrollHandlerState scroll_handler_state = 32;
3381 if (cached_has_bits & 0x00000002u) {
3382 total_size += 2 +
3383 ::_pbi::WireFormatLite::EnumSize(this->_internal_scroll_handler_state());
3384 }
3385
3386 // optional bool video_needs_begin_frames = 36;
3387 if (cached_has_bits & 0x00000004u) {
3388 total_size += 2 + 1;
3389 }
3390
3391 // optional bool defer_begin_main_frame = 37;
3392 if (cached_has_bits & 0x00000008u) {
3393 total_size += 2 + 1;
3394 }
3395
3396 // optional bool last_commit_had_no_updates = 38;
3397 if (cached_has_bits & 0x00000010u) {
3398 total_size += 2 + 1;
3399 }
3400
3401 // optional bool did_draw_in_last_frame = 39;
3402 if (cached_has_bits & 0x00000020u) {
3403 total_size += 2 + 1;
3404 }
3405
3406 // optional bool did_submit_in_last_frame = 40;
3407 if (cached_has_bits & 0x00000040u) {
3408 total_size += 2 + 1;
3409 }
3410
3411 // optional bool needs_impl_side_invalidation = 41;
3412 if (cached_has_bits & 0x00000080u) {
3413 total_size += 2 + 1;
3414 }
3415
3416 }
3417 if (cached_has_bits & 0x00001f00u) {
3418 // optional bool current_pending_tree_is_impl_side = 42;
3419 if (cached_has_bits & 0x00000100u) {
3420 total_size += 2 + 1;
3421 }
3422
3423 // optional bool previous_pending_tree_was_impl_side = 43;
3424 if (cached_has_bits & 0x00000200u) {
3425 total_size += 2 + 1;
3426 }
3427
3428 // optional bool processing_animation_worklets_for_active_tree = 44;
3429 if (cached_has_bits & 0x00000400u) {
3430 total_size += 2 + 1;
3431 }
3432
3433 // optional bool processing_animation_worklets_for_pending_tree = 45;
3434 if (cached_has_bits & 0x00000800u) {
3435 total_size += 2 + 1;
3436 }
3437
3438 // optional bool processing_paint_worklets_for_pending_tree = 46;
3439 if (cached_has_bits & 0x00001000u) {
3440 total_size += 2 + 1;
3441 }
3442
3443 }
3444 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3445 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
3446 }
3447 int cached_size = ::_pbi::ToCachedSize(total_size);
3448 SetCachedSize(cached_size);
3449 return total_size;
3450 }
3451
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)3452 void ChromeCompositorStateMachine_MinorState::CheckTypeAndMergeFrom(
3453 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
3454 MergeFrom(*::_pbi::DownCast<const ChromeCompositorStateMachine_MinorState*>(
3455 &from));
3456 }
3457
MergeFrom(const ChromeCompositorStateMachine_MinorState & from)3458 void ChromeCompositorStateMachine_MinorState::MergeFrom(const ChromeCompositorStateMachine_MinorState& from) {
3459 ChromeCompositorStateMachine_MinorState* const _this = this;
3460 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.ChromeCompositorStateMachine.MinorState)
3461 GOOGLE_DCHECK_NE(&from, _this);
3462 ::uint32_t cached_has_bits = 0;
3463 (void) cached_has_bits;
3464
3465 cached_has_bits = from._impl_._has_bits_[0];
3466 if (cached_has_bits & 0x000000ffu) {
3467 if (cached_has_bits & 0x00000001u) {
3468 _this->_impl_.commit_count_ = from._impl_.commit_count_;
3469 }
3470 if (cached_has_bits & 0x00000002u) {
3471 _this->_impl_.current_frame_number_ = from._impl_.current_frame_number_;
3472 }
3473 if (cached_has_bits & 0x00000004u) {
3474 _this->_impl_.last_frame_number_submit_performed_ = from._impl_.last_frame_number_submit_performed_;
3475 }
3476 if (cached_has_bits & 0x00000008u) {
3477 _this->_impl_.last_frame_number_draw_performed_ = from._impl_.last_frame_number_draw_performed_;
3478 }
3479 if (cached_has_bits & 0x00000010u) {
3480 _this->_impl_.last_frame_number_begin_main_frame_sent_ = from._impl_.last_frame_number_begin_main_frame_sent_;
3481 }
3482 if (cached_has_bits & 0x00000020u) {
3483 _this->_impl_.did_draw_ = from._impl_.did_draw_;
3484 }
3485 if (cached_has_bits & 0x00000040u) {
3486 _this->_impl_.did_send_begin_main_frame_for_current_frame_ = from._impl_.did_send_begin_main_frame_for_current_frame_;
3487 }
3488 if (cached_has_bits & 0x00000080u) {
3489 _this->_impl_.did_notify_begin_main_frame_not_expected_until_ = from._impl_.did_notify_begin_main_frame_not_expected_until_;
3490 }
3491 _this->_impl_._has_bits_[0] |= cached_has_bits;
3492 }
3493 if (cached_has_bits & 0x0000ff00u) {
3494 if (cached_has_bits & 0x00000100u) {
3495 _this->_impl_.did_notify_begin_main_frame_not_expected_soon_ = from._impl_.did_notify_begin_main_frame_not_expected_soon_;
3496 }
3497 if (cached_has_bits & 0x00000200u) {
3498 _this->_impl_.wants_begin_main_frame_not_expected_ = from._impl_.wants_begin_main_frame_not_expected_;
3499 }
3500 if (cached_has_bits & 0x00000400u) {
3501 _this->_impl_.did_commit_during_frame_ = from._impl_.did_commit_during_frame_;
3502 }
3503 if (cached_has_bits & 0x00000800u) {
3504 _this->_impl_.did_invalidate_layer_tree_frame_sink_ = from._impl_.did_invalidate_layer_tree_frame_sink_;
3505 }
3506 if (cached_has_bits & 0x00001000u) {
3507 _this->_impl_.did_perform_impl_side_invalidaion_ = from._impl_.did_perform_impl_side_invalidaion_;
3508 }
3509 if (cached_has_bits & 0x00002000u) {
3510 _this->_impl_.consecutive_checkerboard_animations_ = from._impl_.consecutive_checkerboard_animations_;
3511 }
3512 if (cached_has_bits & 0x00004000u) {
3513 _this->_impl_.pending_submit_frames_ = from._impl_.pending_submit_frames_;
3514 }
3515 if (cached_has_bits & 0x00008000u) {
3516 _this->_impl_.submit_frames_with_current_layer_tree_frame_sink_ = from._impl_.submit_frames_with_current_layer_tree_frame_sink_;
3517 }
3518 _this->_impl_._has_bits_[0] |= cached_has_bits;
3519 }
3520 if (cached_has_bits & 0x00ff0000u) {
3521 if (cached_has_bits & 0x00010000u) {
3522 _this->_impl_.did_prepare_tiles_ = from._impl_.did_prepare_tiles_;
3523 }
3524 if (cached_has_bits & 0x00020000u) {
3525 _this->_impl_.needs_redraw_ = from._impl_.needs_redraw_;
3526 }
3527 if (cached_has_bits & 0x00040000u) {
3528 _this->_impl_.needs_prepare_tiles_ = from._impl_.needs_prepare_tiles_;
3529 }
3530 if (cached_has_bits & 0x00080000u) {
3531 _this->_impl_.needs_begin_main_frame_ = from._impl_.needs_begin_main_frame_;
3532 }
3533 if (cached_has_bits & 0x00100000u) {
3534 _this->_impl_.needs_one_begin_impl_frame_ = from._impl_.needs_one_begin_impl_frame_;
3535 }
3536 if (cached_has_bits & 0x00200000u) {
3537 _this->_impl_.visible_ = from._impl_.visible_;
3538 }
3539 if (cached_has_bits & 0x00400000u) {
3540 _this->_impl_.begin_frame_source_paused_ = from._impl_.begin_frame_source_paused_;
3541 }
3542 if (cached_has_bits & 0x00800000u) {
3543 _this->_impl_.can_draw_ = from._impl_.can_draw_;
3544 }
3545 _this->_impl_._has_bits_[0] |= cached_has_bits;
3546 }
3547 if (cached_has_bits & 0xff000000u) {
3548 if (cached_has_bits & 0x01000000u) {
3549 _this->_impl_.resourceless_draw_ = from._impl_.resourceless_draw_;
3550 }
3551 if (cached_has_bits & 0x02000000u) {
3552 _this->_impl_.has_pending_tree_ = from._impl_.has_pending_tree_;
3553 }
3554 if (cached_has_bits & 0x04000000u) {
3555 _this->_impl_.pending_tree_is_ready_for_activation_ = from._impl_.pending_tree_is_ready_for_activation_;
3556 }
3557 if (cached_has_bits & 0x08000000u) {
3558 _this->_impl_.active_tree_needs_first_draw_ = from._impl_.active_tree_needs_first_draw_;
3559 }
3560 if (cached_has_bits & 0x10000000u) {
3561 _this->_impl_.tree_priority_ = from._impl_.tree_priority_;
3562 }
3563 if (cached_has_bits & 0x20000000u) {
3564 _this->_impl_.active_tree_is_ready_to_draw_ = from._impl_.active_tree_is_ready_to_draw_;
3565 }
3566 if (cached_has_bits & 0x40000000u) {
3567 _this->_impl_.did_create_and_initialize_first_layer_tree_frame_sink_ = from._impl_.did_create_and_initialize_first_layer_tree_frame_sink_;
3568 }
3569 if (cached_has_bits & 0x80000000u) {
3570 _this->_impl_.critical_begin_main_frame_to_activate_is_fast_ = from._impl_.critical_begin_main_frame_to_activate_is_fast_;
3571 }
3572 _this->_impl_._has_bits_[0] |= cached_has_bits;
3573 }
3574 cached_has_bits = from._impl_._has_bits_[1];
3575 if (cached_has_bits & 0x000000ffu) {
3576 if (cached_has_bits & 0x00000001u) {
3577 _this->_impl_.main_thread_missed_last_deadline_ = from._impl_.main_thread_missed_last_deadline_;
3578 }
3579 if (cached_has_bits & 0x00000002u) {
3580 _this->_impl_.scroll_handler_state_ = from._impl_.scroll_handler_state_;
3581 }
3582 if (cached_has_bits & 0x00000004u) {
3583 _this->_impl_.video_needs_begin_frames_ = from._impl_.video_needs_begin_frames_;
3584 }
3585 if (cached_has_bits & 0x00000008u) {
3586 _this->_impl_.defer_begin_main_frame_ = from._impl_.defer_begin_main_frame_;
3587 }
3588 if (cached_has_bits & 0x00000010u) {
3589 _this->_impl_.last_commit_had_no_updates_ = from._impl_.last_commit_had_no_updates_;
3590 }
3591 if (cached_has_bits & 0x00000020u) {
3592 _this->_impl_.did_draw_in_last_frame_ = from._impl_.did_draw_in_last_frame_;
3593 }
3594 if (cached_has_bits & 0x00000040u) {
3595 _this->_impl_.did_submit_in_last_frame_ = from._impl_.did_submit_in_last_frame_;
3596 }
3597 if (cached_has_bits & 0x00000080u) {
3598 _this->_impl_.needs_impl_side_invalidation_ = from._impl_.needs_impl_side_invalidation_;
3599 }
3600 _this->_impl_._has_bits_[1] |= cached_has_bits;
3601 }
3602 if (cached_has_bits & 0x00001f00u) {
3603 if (cached_has_bits & 0x00000100u) {
3604 _this->_impl_.current_pending_tree_is_impl_side_ = from._impl_.current_pending_tree_is_impl_side_;
3605 }
3606 if (cached_has_bits & 0x00000200u) {
3607 _this->_impl_.previous_pending_tree_was_impl_side_ = from._impl_.previous_pending_tree_was_impl_side_;
3608 }
3609 if (cached_has_bits & 0x00000400u) {
3610 _this->_impl_.processing_animation_worklets_for_active_tree_ = from._impl_.processing_animation_worklets_for_active_tree_;
3611 }
3612 if (cached_has_bits & 0x00000800u) {
3613 _this->_impl_.processing_animation_worklets_for_pending_tree_ = from._impl_.processing_animation_worklets_for_pending_tree_;
3614 }
3615 if (cached_has_bits & 0x00001000u) {
3616 _this->_impl_.processing_paint_worklets_for_pending_tree_ = from._impl_.processing_paint_worklets_for_pending_tree_;
3617 }
3618 _this->_impl_._has_bits_[1] |= cached_has_bits;
3619 }
3620 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3621 }
3622
CopyFrom(const ChromeCompositorStateMachine_MinorState & from)3623 void ChromeCompositorStateMachine_MinorState::CopyFrom(const ChromeCompositorStateMachine_MinorState& from) {
3624 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.ChromeCompositorStateMachine.MinorState)
3625 if (&from == this) return;
3626 Clear();
3627 MergeFrom(from);
3628 }
3629
IsInitialized() const3630 bool ChromeCompositorStateMachine_MinorState::IsInitialized() const {
3631 return true;
3632 }
3633
InternalSwap(ChromeCompositorStateMachine_MinorState * other)3634 void ChromeCompositorStateMachine_MinorState::InternalSwap(ChromeCompositorStateMachine_MinorState* other) {
3635 using std::swap;
3636 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
3637 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
3638 swap(_impl_._has_bits_[1], other->_impl_._has_bits_[1]);
3639 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
3640 PROTOBUF_FIELD_OFFSET(ChromeCompositorStateMachine_MinorState, _impl_.processing_paint_worklets_for_pending_tree_)
3641 + sizeof(ChromeCompositorStateMachine_MinorState::_impl_.processing_paint_worklets_for_pending_tree_) // NOLINT
3642 - PROTOBUF_FIELD_OFFSET(ChromeCompositorStateMachine_MinorState, _impl_.commit_count_)>(
3643 reinterpret_cast<char*>(&_impl_.commit_count_),
3644 reinterpret_cast<char*>(&other->_impl_.commit_count_));
3645 }
3646
GetTypeName() const3647 std::string ChromeCompositorStateMachine_MinorState::GetTypeName() const {
3648 return "perfetto.protos.ChromeCompositorStateMachine.MinorState";
3649 }
3650
3651
3652 // ===================================================================
3653
3654 class ChromeCompositorStateMachine::_Internal {
3655 public:
3656 using HasBits = decltype(std::declval<ChromeCompositorStateMachine>()._impl_._has_bits_);
3657 static const ::perfetto::protos::ChromeCompositorStateMachine_MajorState& major_state(const ChromeCompositorStateMachine* msg);
set_has_major_state(HasBits * has_bits)3658 static void set_has_major_state(HasBits* has_bits) {
3659 (*has_bits)[0] |= 1u;
3660 }
3661 static const ::perfetto::protos::ChromeCompositorStateMachine_MinorState& minor_state(const ChromeCompositorStateMachine* msg);
set_has_minor_state(HasBits * has_bits)3662 static void set_has_minor_state(HasBits* has_bits) {
3663 (*has_bits)[0] |= 2u;
3664 }
3665 };
3666
3667 const ::perfetto::protos::ChromeCompositorStateMachine_MajorState&
major_state(const ChromeCompositorStateMachine * msg)3668 ChromeCompositorStateMachine::_Internal::major_state(const ChromeCompositorStateMachine* msg) {
3669 return *msg->_impl_.major_state_;
3670 }
3671 const ::perfetto::protos::ChromeCompositorStateMachine_MinorState&
minor_state(const ChromeCompositorStateMachine * msg)3672 ChromeCompositorStateMachine::_Internal::minor_state(const ChromeCompositorStateMachine* msg) {
3673 return *msg->_impl_.minor_state_;
3674 }
ChromeCompositorStateMachine(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)3675 ChromeCompositorStateMachine::ChromeCompositorStateMachine(::PROTOBUF_NAMESPACE_ID::Arena* arena,
3676 bool is_message_owned)
3677 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
3678 SharedCtor(arena, is_message_owned);
3679 // @@protoc_insertion_point(arena_constructor:perfetto.protos.ChromeCompositorStateMachine)
3680 }
ChromeCompositorStateMachine(const ChromeCompositorStateMachine & from)3681 ChromeCompositorStateMachine::ChromeCompositorStateMachine(const ChromeCompositorStateMachine& from)
3682 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
3683 ChromeCompositorStateMachine* const _this = this; (void)_this;
3684 new (&_impl_) Impl_{
3685 decltype(_impl_._has_bits_){from._impl_._has_bits_}
3686 , /*decltype(_impl_._cached_size_)*/{}
3687 , decltype(_impl_.major_state_){nullptr}
3688 , decltype(_impl_.minor_state_){nullptr}};
3689
3690 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3691 if (from._internal_has_major_state()) {
3692 _this->_impl_.major_state_ = new ::perfetto::protos::ChromeCompositorStateMachine_MajorState(*from._impl_.major_state_);
3693 }
3694 if (from._internal_has_minor_state()) {
3695 _this->_impl_.minor_state_ = new ::perfetto::protos::ChromeCompositorStateMachine_MinorState(*from._impl_.minor_state_);
3696 }
3697 // @@protoc_insertion_point(copy_constructor:perfetto.protos.ChromeCompositorStateMachine)
3698 }
3699
SharedCtor(::_pb::Arena * arena,bool is_message_owned)3700 inline void ChromeCompositorStateMachine::SharedCtor(
3701 ::_pb::Arena* arena, bool is_message_owned) {
3702 (void)arena;
3703 (void)is_message_owned;
3704 new (&_impl_) Impl_{
3705 decltype(_impl_._has_bits_){}
3706 , /*decltype(_impl_._cached_size_)*/{}
3707 , decltype(_impl_.major_state_){nullptr}
3708 , decltype(_impl_.minor_state_){nullptr}
3709 };
3710 }
3711
~ChromeCompositorStateMachine()3712 ChromeCompositorStateMachine::~ChromeCompositorStateMachine() {
3713 // @@protoc_insertion_point(destructor:perfetto.protos.ChromeCompositorStateMachine)
3714 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
3715 (void)arena;
3716 return;
3717 }
3718 SharedDtor();
3719 }
3720
SharedDtor()3721 inline void ChromeCompositorStateMachine::SharedDtor() {
3722 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
3723 if (this != internal_default_instance()) delete _impl_.major_state_;
3724 if (this != internal_default_instance()) delete _impl_.minor_state_;
3725 }
3726
SetCachedSize(int size) const3727 void ChromeCompositorStateMachine::SetCachedSize(int size) const {
3728 _impl_._cached_size_.Set(size);
3729 }
3730
Clear()3731 void ChromeCompositorStateMachine::Clear() {
3732 // @@protoc_insertion_point(message_clear_start:perfetto.protos.ChromeCompositorStateMachine)
3733 ::uint32_t cached_has_bits = 0;
3734 // Prevent compiler warnings about cached_has_bits being unused
3735 (void) cached_has_bits;
3736
3737 cached_has_bits = _impl_._has_bits_[0];
3738 if (cached_has_bits & 0x00000003u) {
3739 if (cached_has_bits & 0x00000001u) {
3740 GOOGLE_DCHECK(_impl_.major_state_ != nullptr);
3741 _impl_.major_state_->Clear();
3742 }
3743 if (cached_has_bits & 0x00000002u) {
3744 GOOGLE_DCHECK(_impl_.minor_state_ != nullptr);
3745 _impl_.minor_state_->Clear();
3746 }
3747 }
3748 _impl_._has_bits_.Clear();
3749 _internal_metadata_.Clear<std::string>();
3750 }
3751
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)3752 const char* ChromeCompositorStateMachine::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
3753 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
3754 _Internal::HasBits has_bits{};
3755 while (!ctx->Done(&ptr)) {
3756 ::uint32_t tag;
3757 ptr = ::_pbi::ReadTag(ptr, &tag);
3758 switch (tag >> 3) {
3759 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState major_state = 1;
3760 case 1:
3761 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 10)) {
3762 ptr = ctx->ParseMessage(_internal_mutable_major_state(), ptr);
3763 CHK_(ptr);
3764 } else {
3765 goto handle_unusual;
3766 }
3767 continue;
3768 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState minor_state = 2;
3769 case 2:
3770 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
3771 ptr = ctx->ParseMessage(_internal_mutable_minor_state(), ptr);
3772 CHK_(ptr);
3773 } else {
3774 goto handle_unusual;
3775 }
3776 continue;
3777 default:
3778 goto handle_unusual;
3779 } // switch
3780 handle_unusual:
3781 if ((tag == 0) || ((tag & 7) == 4)) {
3782 CHK_(ptr);
3783 ctx->SetLastTag(tag);
3784 goto message_done;
3785 }
3786 ptr = UnknownFieldParse(
3787 tag,
3788 _internal_metadata_.mutable_unknown_fields<std::string>(),
3789 ptr, ctx);
3790 CHK_(ptr != nullptr);
3791 } // while
3792 message_done:
3793 _impl_._has_bits_.Or(has_bits);
3794 return ptr;
3795 failure:
3796 ptr = nullptr;
3797 goto message_done;
3798 #undef CHK_
3799 }
3800
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const3801 ::uint8_t* ChromeCompositorStateMachine::_InternalSerialize(
3802 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
3803 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.ChromeCompositorStateMachine)
3804 ::uint32_t cached_has_bits = 0;
3805 (void) cached_has_bits;
3806
3807 cached_has_bits = _impl_._has_bits_[0];
3808 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState major_state = 1;
3809 if (cached_has_bits & 0x00000001u) {
3810 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
3811 InternalWriteMessage(1, _Internal::major_state(this),
3812 _Internal::major_state(this).GetCachedSize(), target, stream);
3813 }
3814
3815 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState minor_state = 2;
3816 if (cached_has_bits & 0x00000002u) {
3817 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
3818 InternalWriteMessage(2, _Internal::minor_state(this),
3819 _Internal::minor_state(this).GetCachedSize(), target, stream);
3820 }
3821
3822 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3823 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
3824 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
3825 }
3826 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.ChromeCompositorStateMachine)
3827 return target;
3828 }
3829
ByteSizeLong() const3830 size_t ChromeCompositorStateMachine::ByteSizeLong() const {
3831 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.ChromeCompositorStateMachine)
3832 size_t total_size = 0;
3833
3834 ::uint32_t cached_has_bits = 0;
3835 // Prevent compiler warnings about cached_has_bits being unused
3836 (void) cached_has_bits;
3837
3838 cached_has_bits = _impl_._has_bits_[0];
3839 if (cached_has_bits & 0x00000003u) {
3840 // optional .perfetto.protos.ChromeCompositorStateMachine.MajorState major_state = 1;
3841 if (cached_has_bits & 0x00000001u) {
3842 total_size += 1 +
3843 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
3844 *_impl_.major_state_);
3845 }
3846
3847 // optional .perfetto.protos.ChromeCompositorStateMachine.MinorState minor_state = 2;
3848 if (cached_has_bits & 0x00000002u) {
3849 total_size += 1 +
3850 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
3851 *_impl_.minor_state_);
3852 }
3853
3854 }
3855 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3856 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
3857 }
3858 int cached_size = ::_pbi::ToCachedSize(total_size);
3859 SetCachedSize(cached_size);
3860 return total_size;
3861 }
3862
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)3863 void ChromeCompositorStateMachine::CheckTypeAndMergeFrom(
3864 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
3865 MergeFrom(*::_pbi::DownCast<const ChromeCompositorStateMachine*>(
3866 &from));
3867 }
3868
MergeFrom(const ChromeCompositorStateMachine & from)3869 void ChromeCompositorStateMachine::MergeFrom(const ChromeCompositorStateMachine& from) {
3870 ChromeCompositorStateMachine* const _this = this;
3871 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.ChromeCompositorStateMachine)
3872 GOOGLE_DCHECK_NE(&from, _this);
3873 ::uint32_t cached_has_bits = 0;
3874 (void) cached_has_bits;
3875
3876 cached_has_bits = from._impl_._has_bits_[0];
3877 if (cached_has_bits & 0x00000003u) {
3878 if (cached_has_bits & 0x00000001u) {
3879 _this->_internal_mutable_major_state()->::perfetto::protos::ChromeCompositorStateMachine_MajorState::MergeFrom(
3880 from._internal_major_state());
3881 }
3882 if (cached_has_bits & 0x00000002u) {
3883 _this->_internal_mutable_minor_state()->::perfetto::protos::ChromeCompositorStateMachine_MinorState::MergeFrom(
3884 from._internal_minor_state());
3885 }
3886 }
3887 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3888 }
3889
CopyFrom(const ChromeCompositorStateMachine & from)3890 void ChromeCompositorStateMachine::CopyFrom(const ChromeCompositorStateMachine& from) {
3891 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.ChromeCompositorStateMachine)
3892 if (&from == this) return;
3893 Clear();
3894 MergeFrom(from);
3895 }
3896
IsInitialized() const3897 bool ChromeCompositorStateMachine::IsInitialized() const {
3898 return true;
3899 }
3900
InternalSwap(ChromeCompositorStateMachine * other)3901 void ChromeCompositorStateMachine::InternalSwap(ChromeCompositorStateMachine* other) {
3902 using std::swap;
3903 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
3904 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
3905 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
3906 PROTOBUF_FIELD_OFFSET(ChromeCompositorStateMachine, _impl_.minor_state_)
3907 + sizeof(ChromeCompositorStateMachine::_impl_.minor_state_) // NOLINT
3908 - PROTOBUF_FIELD_OFFSET(ChromeCompositorStateMachine, _impl_.major_state_)>(
3909 reinterpret_cast<char*>(&_impl_.major_state_),
3910 reinterpret_cast<char*>(&other->_impl_.major_state_));
3911 }
3912
GetTypeName() const3913 std::string ChromeCompositorStateMachine::GetTypeName() const {
3914 return "perfetto.protos.ChromeCompositorStateMachine";
3915 }
3916
3917
3918 // ===================================================================
3919
3920 class BeginFrameArgs::_Internal {
3921 public:
3922 using HasBits = decltype(std::declval<BeginFrameArgs>()._impl_._has_bits_);
set_has_type(HasBits * has_bits)3923 static void set_has_type(HasBits* has_bits) {
3924 (*has_bits)[0] |= 16u;
3925 }
set_has_source_id(HasBits * has_bits)3926 static void set_has_source_id(HasBits* has_bits) {
3927 (*has_bits)[0] |= 1u;
3928 }
set_has_sequence_number(HasBits * has_bits)3929 static void set_has_sequence_number(HasBits* has_bits) {
3930 (*has_bits)[0] |= 2u;
3931 }
set_has_frame_time_us(HasBits * has_bits)3932 static void set_has_frame_time_us(HasBits* has_bits) {
3933 (*has_bits)[0] |= 4u;
3934 }
set_has_deadline_us(HasBits * has_bits)3935 static void set_has_deadline_us(HasBits* has_bits) {
3936 (*has_bits)[0] |= 8u;
3937 }
set_has_interval_delta_us(HasBits * has_bits)3938 static void set_has_interval_delta_us(HasBits* has_bits) {
3939 (*has_bits)[0] |= 128u;
3940 }
set_has_on_critical_path(HasBits * has_bits)3941 static void set_has_on_critical_path(HasBits* has_bits) {
3942 (*has_bits)[0] |= 32u;
3943 }
set_has_animate_only(HasBits * has_bits)3944 static void set_has_animate_only(HasBits* has_bits) {
3945 (*has_bits)[0] |= 64u;
3946 }
3947 static const ::perfetto::protos::SourceLocation& source_location(const BeginFrameArgs* msg);
set_has_frames_throttled_since_last(HasBits * has_bits)3948 static void set_has_frames_throttled_since_last(HasBits* has_bits) {
3949 (*has_bits)[0] |= 256u;
3950 }
3951 };
3952
3953 const ::perfetto::protos::SourceLocation&
source_location(const BeginFrameArgs * msg)3954 BeginFrameArgs::_Internal::source_location(const BeginFrameArgs* msg) {
3955 return *msg->_impl_.created_from_.source_location_;
3956 }
set_allocated_source_location(::perfetto::protos::SourceLocation * source_location)3957 void BeginFrameArgs::set_allocated_source_location(::perfetto::protos::SourceLocation* source_location) {
3958 ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
3959 clear_created_from();
3960 if (source_location) {
3961 ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
3962 ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(
3963 reinterpret_cast<::PROTOBUF_NAMESPACE_ID::MessageLite*>(source_location));
3964 if (message_arena != submessage_arena) {
3965 source_location = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
3966 message_arena, source_location, submessage_arena);
3967 }
3968 set_has_source_location();
3969 _impl_.created_from_.source_location_ = source_location;
3970 }
3971 // @@protoc_insertion_point(field_set_allocated:perfetto.protos.BeginFrameArgs.source_location)
3972 }
clear_source_location()3973 void BeginFrameArgs::clear_source_location() {
3974 if (_internal_has_source_location()) {
3975 if (GetArenaForAllocation() == nullptr) {
3976 delete _impl_.created_from_.source_location_;
3977 }
3978 clear_has_created_from();
3979 }
3980 }
BeginFrameArgs(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)3981 BeginFrameArgs::BeginFrameArgs(::PROTOBUF_NAMESPACE_ID::Arena* arena,
3982 bool is_message_owned)
3983 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
3984 SharedCtor(arena, is_message_owned);
3985 // @@protoc_insertion_point(arena_constructor:perfetto.protos.BeginFrameArgs)
3986 }
BeginFrameArgs(const BeginFrameArgs & from)3987 BeginFrameArgs::BeginFrameArgs(const BeginFrameArgs& from)
3988 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
3989 BeginFrameArgs* const _this = this; (void)_this;
3990 new (&_impl_) Impl_{
3991 decltype(_impl_._has_bits_){from._impl_._has_bits_}
3992 , /*decltype(_impl_._cached_size_)*/{}
3993 , decltype(_impl_.source_id_){}
3994 , decltype(_impl_.sequence_number_){}
3995 , decltype(_impl_.frame_time_us_){}
3996 , decltype(_impl_.deadline_us_){}
3997 , decltype(_impl_.type_){}
3998 , decltype(_impl_.on_critical_path_){}
3999 , decltype(_impl_.animate_only_){}
4000 , decltype(_impl_.interval_delta_us_){}
4001 , decltype(_impl_.frames_throttled_since_last_){}
4002 , decltype(_impl_.created_from_){}
4003 , /*decltype(_impl_._oneof_case_)*/{}};
4004
4005 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4006 ::memcpy(&_impl_.source_id_, &from._impl_.source_id_,
4007 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.frames_throttled_since_last_) -
4008 reinterpret_cast<char*>(&_impl_.source_id_)) + sizeof(_impl_.frames_throttled_since_last_));
4009 clear_has_created_from();
4010 switch (from.created_from_case()) {
4011 case kSourceLocationIid: {
4012 _this->_internal_set_source_location_iid(from._internal_source_location_iid());
4013 break;
4014 }
4015 case kSourceLocation: {
4016 _this->_internal_mutable_source_location()->::perfetto::protos::SourceLocation::MergeFrom(
4017 from._internal_source_location());
4018 break;
4019 }
4020 case CREATED_FROM_NOT_SET: {
4021 break;
4022 }
4023 }
4024 // @@protoc_insertion_point(copy_constructor:perfetto.protos.BeginFrameArgs)
4025 }
4026
SharedCtor(::_pb::Arena * arena,bool is_message_owned)4027 inline void BeginFrameArgs::SharedCtor(
4028 ::_pb::Arena* arena, bool is_message_owned) {
4029 (void)arena;
4030 (void)is_message_owned;
4031 new (&_impl_) Impl_{
4032 decltype(_impl_._has_bits_){}
4033 , /*decltype(_impl_._cached_size_)*/{}
4034 , decltype(_impl_.source_id_){::uint64_t{0u}}
4035 , decltype(_impl_.sequence_number_){::uint64_t{0u}}
4036 , decltype(_impl_.frame_time_us_){::int64_t{0}}
4037 , decltype(_impl_.deadline_us_){::int64_t{0}}
4038 , decltype(_impl_.type_){0}
4039 , decltype(_impl_.on_critical_path_){false}
4040 , decltype(_impl_.animate_only_){false}
4041 , decltype(_impl_.interval_delta_us_){::int64_t{0}}
4042 , decltype(_impl_.frames_throttled_since_last_){::int64_t{0}}
4043 , decltype(_impl_.created_from_){}
4044 , /*decltype(_impl_._oneof_case_)*/{}
4045 };
4046 clear_has_created_from();
4047 }
4048
~BeginFrameArgs()4049 BeginFrameArgs::~BeginFrameArgs() {
4050 // @@protoc_insertion_point(destructor:perfetto.protos.BeginFrameArgs)
4051 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
4052 (void)arena;
4053 return;
4054 }
4055 SharedDtor();
4056 }
4057
SharedDtor()4058 inline void BeginFrameArgs::SharedDtor() {
4059 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
4060 if (has_created_from()) {
4061 clear_created_from();
4062 }
4063 }
4064
SetCachedSize(int size) const4065 void BeginFrameArgs::SetCachedSize(int size) const {
4066 _impl_._cached_size_.Set(size);
4067 }
4068
clear_created_from()4069 void BeginFrameArgs::clear_created_from() {
4070 // @@protoc_insertion_point(one_of_clear_start:perfetto.protos.BeginFrameArgs)
4071 switch (created_from_case()) {
4072 case kSourceLocationIid: {
4073 // No need to clear
4074 break;
4075 }
4076 case kSourceLocation: {
4077 if (GetArenaForAllocation() == nullptr) {
4078 delete _impl_.created_from_.source_location_;
4079 }
4080 break;
4081 }
4082 case CREATED_FROM_NOT_SET: {
4083 break;
4084 }
4085 }
4086 _impl_._oneof_case_[0] = CREATED_FROM_NOT_SET;
4087 }
4088
4089
Clear()4090 void BeginFrameArgs::Clear() {
4091 // @@protoc_insertion_point(message_clear_start:perfetto.protos.BeginFrameArgs)
4092 ::uint32_t cached_has_bits = 0;
4093 // Prevent compiler warnings about cached_has_bits being unused
4094 (void) cached_has_bits;
4095
4096 cached_has_bits = _impl_._has_bits_[0];
4097 if (cached_has_bits & 0x000000ffu) {
4098 ::memset(&_impl_.source_id_, 0, static_cast<size_t>(
4099 reinterpret_cast<char*>(&_impl_.interval_delta_us_) -
4100 reinterpret_cast<char*>(&_impl_.source_id_)) + sizeof(_impl_.interval_delta_us_));
4101 }
4102 _impl_.frames_throttled_since_last_ = ::int64_t{0};
4103 clear_created_from();
4104 _impl_._has_bits_.Clear();
4105 _internal_metadata_.Clear<std::string>();
4106 }
4107
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)4108 const char* BeginFrameArgs::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
4109 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
4110 _Internal::HasBits has_bits{};
4111 while (!ctx->Done(&ptr)) {
4112 ::uint32_t tag;
4113 ptr = ::_pbi::ReadTag(ptr, &tag);
4114 switch (tag >> 3) {
4115 // optional .perfetto.protos.BeginFrameArgs.BeginFrameArgsType type = 1;
4116 case 1:
4117 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
4118 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4119 CHK_(ptr);
4120 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::BeginFrameArgs_BeginFrameArgsType_IsValid(val))) {
4121 _internal_set_type(static_cast<::perfetto::protos::BeginFrameArgs_BeginFrameArgsType>(val));
4122 } else {
4123 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(1, val, mutable_unknown_fields());
4124 }
4125 } else {
4126 goto handle_unusual;
4127 }
4128 continue;
4129 // optional uint64 source_id = 2;
4130 case 2:
4131 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
4132 _Internal::set_has_source_id(&has_bits);
4133 _impl_.source_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4134 CHK_(ptr);
4135 } else {
4136 goto handle_unusual;
4137 }
4138 continue;
4139 // optional uint64 sequence_number = 3;
4140 case 3:
4141 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
4142 _Internal::set_has_sequence_number(&has_bits);
4143 _impl_.sequence_number_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4144 CHK_(ptr);
4145 } else {
4146 goto handle_unusual;
4147 }
4148 continue;
4149 // optional int64 frame_time_us = 4;
4150 case 4:
4151 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
4152 _Internal::set_has_frame_time_us(&has_bits);
4153 _impl_.frame_time_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4154 CHK_(ptr);
4155 } else {
4156 goto handle_unusual;
4157 }
4158 continue;
4159 // optional int64 deadline_us = 5;
4160 case 5:
4161 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
4162 _Internal::set_has_deadline_us(&has_bits);
4163 _impl_.deadline_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4164 CHK_(ptr);
4165 } else {
4166 goto handle_unusual;
4167 }
4168 continue;
4169 // optional int64 interval_delta_us = 6;
4170 case 6:
4171 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
4172 _Internal::set_has_interval_delta_us(&has_bits);
4173 _impl_.interval_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4174 CHK_(ptr);
4175 } else {
4176 goto handle_unusual;
4177 }
4178 continue;
4179 // optional bool on_critical_path = 7;
4180 case 7:
4181 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
4182 _Internal::set_has_on_critical_path(&has_bits);
4183 _impl_.on_critical_path_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4184 CHK_(ptr);
4185 } else {
4186 goto handle_unusual;
4187 }
4188 continue;
4189 // optional bool animate_only = 8;
4190 case 8:
4191 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
4192 _Internal::set_has_animate_only(&has_bits);
4193 _impl_.animate_only_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4194 CHK_(ptr);
4195 } else {
4196 goto handle_unusual;
4197 }
4198 continue;
4199 // uint64 source_location_iid = 9;
4200 case 9:
4201 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
4202 _internal_set_source_location_iid(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr));
4203 CHK_(ptr);
4204 } else {
4205 goto handle_unusual;
4206 }
4207 continue;
4208 // .perfetto.protos.SourceLocation source_location = 10;
4209 case 10:
4210 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 82)) {
4211 ptr = ctx->ParseMessage(_internal_mutable_source_location(), ptr);
4212 CHK_(ptr);
4213 } else {
4214 goto handle_unusual;
4215 }
4216 continue;
4217 // optional int64 frames_throttled_since_last = 12;
4218 case 12:
4219 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 96)) {
4220 _Internal::set_has_frames_throttled_since_last(&has_bits);
4221 _impl_.frames_throttled_since_last_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4222 CHK_(ptr);
4223 } else {
4224 goto handle_unusual;
4225 }
4226 continue;
4227 default:
4228 goto handle_unusual;
4229 } // switch
4230 handle_unusual:
4231 if ((tag == 0) || ((tag & 7) == 4)) {
4232 CHK_(ptr);
4233 ctx->SetLastTag(tag);
4234 goto message_done;
4235 }
4236 ptr = UnknownFieldParse(
4237 tag,
4238 _internal_metadata_.mutable_unknown_fields<std::string>(),
4239 ptr, ctx);
4240 CHK_(ptr != nullptr);
4241 } // while
4242 message_done:
4243 _impl_._has_bits_.Or(has_bits);
4244 return ptr;
4245 failure:
4246 ptr = nullptr;
4247 goto message_done;
4248 #undef CHK_
4249 }
4250
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const4251 ::uint8_t* BeginFrameArgs::_InternalSerialize(
4252 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
4253 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.BeginFrameArgs)
4254 ::uint32_t cached_has_bits = 0;
4255 (void) cached_has_bits;
4256
4257 cached_has_bits = _impl_._has_bits_[0];
4258 // optional .perfetto.protos.BeginFrameArgs.BeginFrameArgsType type = 1;
4259 if (cached_has_bits & 0x00000010u) {
4260 target = stream->EnsureSpace(target);
4261 target = ::_pbi::WireFormatLite::WriteEnumToArray(
4262 1, this->_internal_type(), target);
4263 }
4264
4265 // optional uint64 source_id = 2;
4266 if (cached_has_bits & 0x00000001u) {
4267 target = stream->EnsureSpace(target);
4268 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(2, this->_internal_source_id(), target);
4269 }
4270
4271 // optional uint64 sequence_number = 3;
4272 if (cached_has_bits & 0x00000002u) {
4273 target = stream->EnsureSpace(target);
4274 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(3, this->_internal_sequence_number(), target);
4275 }
4276
4277 // optional int64 frame_time_us = 4;
4278 if (cached_has_bits & 0x00000004u) {
4279 target = stream->EnsureSpace(target);
4280 target = ::_pbi::WireFormatLite::WriteInt64ToArray(4, this->_internal_frame_time_us(), target);
4281 }
4282
4283 // optional int64 deadline_us = 5;
4284 if (cached_has_bits & 0x00000008u) {
4285 target = stream->EnsureSpace(target);
4286 target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_deadline_us(), target);
4287 }
4288
4289 // optional int64 interval_delta_us = 6;
4290 if (cached_has_bits & 0x00000080u) {
4291 target = stream->EnsureSpace(target);
4292 target = ::_pbi::WireFormatLite::WriteInt64ToArray(6, this->_internal_interval_delta_us(), target);
4293 }
4294
4295 // optional bool on_critical_path = 7;
4296 if (cached_has_bits & 0x00000020u) {
4297 target = stream->EnsureSpace(target);
4298 target = ::_pbi::WireFormatLite::WriteBoolToArray(7, this->_internal_on_critical_path(), target);
4299 }
4300
4301 // optional bool animate_only = 8;
4302 if (cached_has_bits & 0x00000040u) {
4303 target = stream->EnsureSpace(target);
4304 target = ::_pbi::WireFormatLite::WriteBoolToArray(8, this->_internal_animate_only(), target);
4305 }
4306
4307 switch (created_from_case()) {
4308 case kSourceLocationIid: {
4309 target = stream->EnsureSpace(target);
4310 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(9, this->_internal_source_location_iid(), target);
4311 break;
4312 }
4313 case kSourceLocation: {
4314 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
4315 InternalWriteMessage(10, _Internal::source_location(this),
4316 _Internal::source_location(this).GetCachedSize(), target, stream);
4317 break;
4318 }
4319 default: ;
4320 }
4321 // optional int64 frames_throttled_since_last = 12;
4322 if (cached_has_bits & 0x00000100u) {
4323 target = stream->EnsureSpace(target);
4324 target = ::_pbi::WireFormatLite::WriteInt64ToArray(12, this->_internal_frames_throttled_since_last(), target);
4325 }
4326
4327 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4328 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
4329 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
4330 }
4331 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.BeginFrameArgs)
4332 return target;
4333 }
4334
ByteSizeLong() const4335 size_t BeginFrameArgs::ByteSizeLong() const {
4336 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.BeginFrameArgs)
4337 size_t total_size = 0;
4338
4339 ::uint32_t cached_has_bits = 0;
4340 // Prevent compiler warnings about cached_has_bits being unused
4341 (void) cached_has_bits;
4342
4343 cached_has_bits = _impl_._has_bits_[0];
4344 if (cached_has_bits & 0x000000ffu) {
4345 // optional uint64 source_id = 2;
4346 if (cached_has_bits & 0x00000001u) {
4347 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_source_id());
4348 }
4349
4350 // optional uint64 sequence_number = 3;
4351 if (cached_has_bits & 0x00000002u) {
4352 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_sequence_number());
4353 }
4354
4355 // optional int64 frame_time_us = 4;
4356 if (cached_has_bits & 0x00000004u) {
4357 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_frame_time_us());
4358 }
4359
4360 // optional int64 deadline_us = 5;
4361 if (cached_has_bits & 0x00000008u) {
4362 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_deadline_us());
4363 }
4364
4365 // optional .perfetto.protos.BeginFrameArgs.BeginFrameArgsType type = 1;
4366 if (cached_has_bits & 0x00000010u) {
4367 total_size += 1 +
4368 ::_pbi::WireFormatLite::EnumSize(this->_internal_type());
4369 }
4370
4371 // optional bool on_critical_path = 7;
4372 if (cached_has_bits & 0x00000020u) {
4373 total_size += 1 + 1;
4374 }
4375
4376 // optional bool animate_only = 8;
4377 if (cached_has_bits & 0x00000040u) {
4378 total_size += 1 + 1;
4379 }
4380
4381 // optional int64 interval_delta_us = 6;
4382 if (cached_has_bits & 0x00000080u) {
4383 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_interval_delta_us());
4384 }
4385
4386 }
4387 // optional int64 frames_throttled_since_last = 12;
4388 if (cached_has_bits & 0x00000100u) {
4389 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_frames_throttled_since_last());
4390 }
4391
4392 switch (created_from_case()) {
4393 // uint64 source_location_iid = 9;
4394 case kSourceLocationIid: {
4395 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_source_location_iid());
4396 break;
4397 }
4398 // .perfetto.protos.SourceLocation source_location = 10;
4399 case kSourceLocation: {
4400 total_size += 1 +
4401 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
4402 *_impl_.created_from_.source_location_);
4403 break;
4404 }
4405 case CREATED_FROM_NOT_SET: {
4406 break;
4407 }
4408 }
4409 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4410 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
4411 }
4412 int cached_size = ::_pbi::ToCachedSize(total_size);
4413 SetCachedSize(cached_size);
4414 return total_size;
4415 }
4416
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)4417 void BeginFrameArgs::CheckTypeAndMergeFrom(
4418 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
4419 MergeFrom(*::_pbi::DownCast<const BeginFrameArgs*>(
4420 &from));
4421 }
4422
MergeFrom(const BeginFrameArgs & from)4423 void BeginFrameArgs::MergeFrom(const BeginFrameArgs& from) {
4424 BeginFrameArgs* const _this = this;
4425 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.BeginFrameArgs)
4426 GOOGLE_DCHECK_NE(&from, _this);
4427 ::uint32_t cached_has_bits = 0;
4428 (void) cached_has_bits;
4429
4430 cached_has_bits = from._impl_._has_bits_[0];
4431 if (cached_has_bits & 0x000000ffu) {
4432 if (cached_has_bits & 0x00000001u) {
4433 _this->_impl_.source_id_ = from._impl_.source_id_;
4434 }
4435 if (cached_has_bits & 0x00000002u) {
4436 _this->_impl_.sequence_number_ = from._impl_.sequence_number_;
4437 }
4438 if (cached_has_bits & 0x00000004u) {
4439 _this->_impl_.frame_time_us_ = from._impl_.frame_time_us_;
4440 }
4441 if (cached_has_bits & 0x00000008u) {
4442 _this->_impl_.deadline_us_ = from._impl_.deadline_us_;
4443 }
4444 if (cached_has_bits & 0x00000010u) {
4445 _this->_impl_.type_ = from._impl_.type_;
4446 }
4447 if (cached_has_bits & 0x00000020u) {
4448 _this->_impl_.on_critical_path_ = from._impl_.on_critical_path_;
4449 }
4450 if (cached_has_bits & 0x00000040u) {
4451 _this->_impl_.animate_only_ = from._impl_.animate_only_;
4452 }
4453 if (cached_has_bits & 0x00000080u) {
4454 _this->_impl_.interval_delta_us_ = from._impl_.interval_delta_us_;
4455 }
4456 _this->_impl_._has_bits_[0] |= cached_has_bits;
4457 }
4458 if (cached_has_bits & 0x00000100u) {
4459 _this->_internal_set_frames_throttled_since_last(from._internal_frames_throttled_since_last());
4460 }
4461 switch (from.created_from_case()) {
4462 case kSourceLocationIid: {
4463 _this->_internal_set_source_location_iid(from._internal_source_location_iid());
4464 break;
4465 }
4466 case kSourceLocation: {
4467 _this->_internal_mutable_source_location()->::perfetto::protos::SourceLocation::MergeFrom(
4468 from._internal_source_location());
4469 break;
4470 }
4471 case CREATED_FROM_NOT_SET: {
4472 break;
4473 }
4474 }
4475 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4476 }
4477
CopyFrom(const BeginFrameArgs & from)4478 void BeginFrameArgs::CopyFrom(const BeginFrameArgs& from) {
4479 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.BeginFrameArgs)
4480 if (&from == this) return;
4481 Clear();
4482 MergeFrom(from);
4483 }
4484
IsInitialized() const4485 bool BeginFrameArgs::IsInitialized() const {
4486 return true;
4487 }
4488
InternalSwap(BeginFrameArgs * other)4489 void BeginFrameArgs::InternalSwap(BeginFrameArgs* other) {
4490 using std::swap;
4491 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
4492 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
4493 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
4494 PROTOBUF_FIELD_OFFSET(BeginFrameArgs, _impl_.frames_throttled_since_last_)
4495 + sizeof(BeginFrameArgs::_impl_.frames_throttled_since_last_) // NOLINT
4496 - PROTOBUF_FIELD_OFFSET(BeginFrameArgs, _impl_.source_id_)>(
4497 reinterpret_cast<char*>(&_impl_.source_id_),
4498 reinterpret_cast<char*>(&other->_impl_.source_id_));
4499 swap(_impl_.created_from_, other->_impl_.created_from_);
4500 swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
4501 }
4502
GetTypeName() const4503 std::string BeginFrameArgs::GetTypeName() const {
4504 return "perfetto.protos.BeginFrameArgs";
4505 }
4506
4507
4508 // ===================================================================
4509
4510 class BeginImplFrameArgs_TimestampsInUs::_Internal {
4511 public:
4512 using HasBits = decltype(std::declval<BeginImplFrameArgs_TimestampsInUs>()._impl_._has_bits_);
set_has_interval_delta(HasBits * has_bits)4513 static void set_has_interval_delta(HasBits* has_bits) {
4514 (*has_bits)[0] |= 1u;
4515 }
set_has_now_to_deadline_delta(HasBits * has_bits)4516 static void set_has_now_to_deadline_delta(HasBits* has_bits) {
4517 (*has_bits)[0] |= 2u;
4518 }
set_has_frame_time_to_now_delta(HasBits * has_bits)4519 static void set_has_frame_time_to_now_delta(HasBits* has_bits) {
4520 (*has_bits)[0] |= 4u;
4521 }
set_has_frame_time_to_deadline_delta(HasBits * has_bits)4522 static void set_has_frame_time_to_deadline_delta(HasBits* has_bits) {
4523 (*has_bits)[0] |= 8u;
4524 }
set_has_now(HasBits * has_bits)4525 static void set_has_now(HasBits* has_bits) {
4526 (*has_bits)[0] |= 16u;
4527 }
set_has_frame_time(HasBits * has_bits)4528 static void set_has_frame_time(HasBits* has_bits) {
4529 (*has_bits)[0] |= 32u;
4530 }
set_has_deadline(HasBits * has_bits)4531 static void set_has_deadline(HasBits* has_bits) {
4532 (*has_bits)[0] |= 64u;
4533 }
4534 };
4535
BeginImplFrameArgs_TimestampsInUs(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)4536 BeginImplFrameArgs_TimestampsInUs::BeginImplFrameArgs_TimestampsInUs(::PROTOBUF_NAMESPACE_ID::Arena* arena,
4537 bool is_message_owned)
4538 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
4539 SharedCtor(arena, is_message_owned);
4540 // @@protoc_insertion_point(arena_constructor:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4541 }
BeginImplFrameArgs_TimestampsInUs(const BeginImplFrameArgs_TimestampsInUs & from)4542 BeginImplFrameArgs_TimestampsInUs::BeginImplFrameArgs_TimestampsInUs(const BeginImplFrameArgs_TimestampsInUs& from)
4543 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
4544 BeginImplFrameArgs_TimestampsInUs* const _this = this; (void)_this;
4545 new (&_impl_) Impl_{
4546 decltype(_impl_._has_bits_){from._impl_._has_bits_}
4547 , /*decltype(_impl_._cached_size_)*/{}
4548 , decltype(_impl_.interval_delta_){}
4549 , decltype(_impl_.now_to_deadline_delta_){}
4550 , decltype(_impl_.frame_time_to_now_delta_){}
4551 , decltype(_impl_.frame_time_to_deadline_delta_){}
4552 , decltype(_impl_.now_){}
4553 , decltype(_impl_.frame_time_){}
4554 , decltype(_impl_.deadline_){}};
4555
4556 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4557 ::memcpy(&_impl_.interval_delta_, &from._impl_.interval_delta_,
4558 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.deadline_) -
4559 reinterpret_cast<char*>(&_impl_.interval_delta_)) + sizeof(_impl_.deadline_));
4560 // @@protoc_insertion_point(copy_constructor:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4561 }
4562
SharedCtor(::_pb::Arena * arena,bool is_message_owned)4563 inline void BeginImplFrameArgs_TimestampsInUs::SharedCtor(
4564 ::_pb::Arena* arena, bool is_message_owned) {
4565 (void)arena;
4566 (void)is_message_owned;
4567 new (&_impl_) Impl_{
4568 decltype(_impl_._has_bits_){}
4569 , /*decltype(_impl_._cached_size_)*/{}
4570 , decltype(_impl_.interval_delta_){::int64_t{0}}
4571 , decltype(_impl_.now_to_deadline_delta_){::int64_t{0}}
4572 , decltype(_impl_.frame_time_to_now_delta_){::int64_t{0}}
4573 , decltype(_impl_.frame_time_to_deadline_delta_){::int64_t{0}}
4574 , decltype(_impl_.now_){::int64_t{0}}
4575 , decltype(_impl_.frame_time_){::int64_t{0}}
4576 , decltype(_impl_.deadline_){::int64_t{0}}
4577 };
4578 }
4579
~BeginImplFrameArgs_TimestampsInUs()4580 BeginImplFrameArgs_TimestampsInUs::~BeginImplFrameArgs_TimestampsInUs() {
4581 // @@protoc_insertion_point(destructor:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4582 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
4583 (void)arena;
4584 return;
4585 }
4586 SharedDtor();
4587 }
4588
SharedDtor()4589 inline void BeginImplFrameArgs_TimestampsInUs::SharedDtor() {
4590 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
4591 }
4592
SetCachedSize(int size) const4593 void BeginImplFrameArgs_TimestampsInUs::SetCachedSize(int size) const {
4594 _impl_._cached_size_.Set(size);
4595 }
4596
Clear()4597 void BeginImplFrameArgs_TimestampsInUs::Clear() {
4598 // @@protoc_insertion_point(message_clear_start:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4599 ::uint32_t cached_has_bits = 0;
4600 // Prevent compiler warnings about cached_has_bits being unused
4601 (void) cached_has_bits;
4602
4603 cached_has_bits = _impl_._has_bits_[0];
4604 if (cached_has_bits & 0x0000007fu) {
4605 ::memset(&_impl_.interval_delta_, 0, static_cast<size_t>(
4606 reinterpret_cast<char*>(&_impl_.deadline_) -
4607 reinterpret_cast<char*>(&_impl_.interval_delta_)) + sizeof(_impl_.deadline_));
4608 }
4609 _impl_._has_bits_.Clear();
4610 _internal_metadata_.Clear<std::string>();
4611 }
4612
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)4613 const char* BeginImplFrameArgs_TimestampsInUs::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
4614 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
4615 _Internal::HasBits has_bits{};
4616 while (!ctx->Done(&ptr)) {
4617 ::uint32_t tag;
4618 ptr = ::_pbi::ReadTag(ptr, &tag);
4619 switch (tag >> 3) {
4620 // optional int64 interval_delta = 1;
4621 case 1:
4622 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
4623 _Internal::set_has_interval_delta(&has_bits);
4624 _impl_.interval_delta_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4625 CHK_(ptr);
4626 } else {
4627 goto handle_unusual;
4628 }
4629 continue;
4630 // optional int64 now_to_deadline_delta = 2;
4631 case 2:
4632 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
4633 _Internal::set_has_now_to_deadline_delta(&has_bits);
4634 _impl_.now_to_deadline_delta_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4635 CHK_(ptr);
4636 } else {
4637 goto handle_unusual;
4638 }
4639 continue;
4640 // optional int64 frame_time_to_now_delta = 3;
4641 case 3:
4642 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
4643 _Internal::set_has_frame_time_to_now_delta(&has_bits);
4644 _impl_.frame_time_to_now_delta_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4645 CHK_(ptr);
4646 } else {
4647 goto handle_unusual;
4648 }
4649 continue;
4650 // optional int64 frame_time_to_deadline_delta = 4;
4651 case 4:
4652 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
4653 _Internal::set_has_frame_time_to_deadline_delta(&has_bits);
4654 _impl_.frame_time_to_deadline_delta_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4655 CHK_(ptr);
4656 } else {
4657 goto handle_unusual;
4658 }
4659 continue;
4660 // optional int64 now = 5;
4661 case 5:
4662 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
4663 _Internal::set_has_now(&has_bits);
4664 _impl_.now_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4665 CHK_(ptr);
4666 } else {
4667 goto handle_unusual;
4668 }
4669 continue;
4670 // optional int64 frame_time = 6;
4671 case 6:
4672 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
4673 _Internal::set_has_frame_time(&has_bits);
4674 _impl_.frame_time_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4675 CHK_(ptr);
4676 } else {
4677 goto handle_unusual;
4678 }
4679 continue;
4680 // optional int64 deadline = 7;
4681 case 7:
4682 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
4683 _Internal::set_has_deadline(&has_bits);
4684 _impl_.deadline_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4685 CHK_(ptr);
4686 } else {
4687 goto handle_unusual;
4688 }
4689 continue;
4690 default:
4691 goto handle_unusual;
4692 } // switch
4693 handle_unusual:
4694 if ((tag == 0) || ((tag & 7) == 4)) {
4695 CHK_(ptr);
4696 ctx->SetLastTag(tag);
4697 goto message_done;
4698 }
4699 ptr = UnknownFieldParse(
4700 tag,
4701 _internal_metadata_.mutable_unknown_fields<std::string>(),
4702 ptr, ctx);
4703 CHK_(ptr != nullptr);
4704 } // while
4705 message_done:
4706 _impl_._has_bits_.Or(has_bits);
4707 return ptr;
4708 failure:
4709 ptr = nullptr;
4710 goto message_done;
4711 #undef CHK_
4712 }
4713
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const4714 ::uint8_t* BeginImplFrameArgs_TimestampsInUs::_InternalSerialize(
4715 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
4716 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4717 ::uint32_t cached_has_bits = 0;
4718 (void) cached_has_bits;
4719
4720 cached_has_bits = _impl_._has_bits_[0];
4721 // optional int64 interval_delta = 1;
4722 if (cached_has_bits & 0x00000001u) {
4723 target = stream->EnsureSpace(target);
4724 target = ::_pbi::WireFormatLite::WriteInt64ToArray(1, this->_internal_interval_delta(), target);
4725 }
4726
4727 // optional int64 now_to_deadline_delta = 2;
4728 if (cached_has_bits & 0x00000002u) {
4729 target = stream->EnsureSpace(target);
4730 target = ::_pbi::WireFormatLite::WriteInt64ToArray(2, this->_internal_now_to_deadline_delta(), target);
4731 }
4732
4733 // optional int64 frame_time_to_now_delta = 3;
4734 if (cached_has_bits & 0x00000004u) {
4735 target = stream->EnsureSpace(target);
4736 target = ::_pbi::WireFormatLite::WriteInt64ToArray(3, this->_internal_frame_time_to_now_delta(), target);
4737 }
4738
4739 // optional int64 frame_time_to_deadline_delta = 4;
4740 if (cached_has_bits & 0x00000008u) {
4741 target = stream->EnsureSpace(target);
4742 target = ::_pbi::WireFormatLite::WriteInt64ToArray(4, this->_internal_frame_time_to_deadline_delta(), target);
4743 }
4744
4745 // optional int64 now = 5;
4746 if (cached_has_bits & 0x00000010u) {
4747 target = stream->EnsureSpace(target);
4748 target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_now(), target);
4749 }
4750
4751 // optional int64 frame_time = 6;
4752 if (cached_has_bits & 0x00000020u) {
4753 target = stream->EnsureSpace(target);
4754 target = ::_pbi::WireFormatLite::WriteInt64ToArray(6, this->_internal_frame_time(), target);
4755 }
4756
4757 // optional int64 deadline = 7;
4758 if (cached_has_bits & 0x00000040u) {
4759 target = stream->EnsureSpace(target);
4760 target = ::_pbi::WireFormatLite::WriteInt64ToArray(7, this->_internal_deadline(), target);
4761 }
4762
4763 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4764 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
4765 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
4766 }
4767 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4768 return target;
4769 }
4770
ByteSizeLong() const4771 size_t BeginImplFrameArgs_TimestampsInUs::ByteSizeLong() const {
4772 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4773 size_t total_size = 0;
4774
4775 ::uint32_t cached_has_bits = 0;
4776 // Prevent compiler warnings about cached_has_bits being unused
4777 (void) cached_has_bits;
4778
4779 cached_has_bits = _impl_._has_bits_[0];
4780 if (cached_has_bits & 0x0000007fu) {
4781 // optional int64 interval_delta = 1;
4782 if (cached_has_bits & 0x00000001u) {
4783 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_interval_delta());
4784 }
4785
4786 // optional int64 now_to_deadline_delta = 2;
4787 if (cached_has_bits & 0x00000002u) {
4788 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_now_to_deadline_delta());
4789 }
4790
4791 // optional int64 frame_time_to_now_delta = 3;
4792 if (cached_has_bits & 0x00000004u) {
4793 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_frame_time_to_now_delta());
4794 }
4795
4796 // optional int64 frame_time_to_deadline_delta = 4;
4797 if (cached_has_bits & 0x00000008u) {
4798 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_frame_time_to_deadline_delta());
4799 }
4800
4801 // optional int64 now = 5;
4802 if (cached_has_bits & 0x00000010u) {
4803 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_now());
4804 }
4805
4806 // optional int64 frame_time = 6;
4807 if (cached_has_bits & 0x00000020u) {
4808 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_frame_time());
4809 }
4810
4811 // optional int64 deadline = 7;
4812 if (cached_has_bits & 0x00000040u) {
4813 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_deadline());
4814 }
4815
4816 }
4817 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4818 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
4819 }
4820 int cached_size = ::_pbi::ToCachedSize(total_size);
4821 SetCachedSize(cached_size);
4822 return total_size;
4823 }
4824
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)4825 void BeginImplFrameArgs_TimestampsInUs::CheckTypeAndMergeFrom(
4826 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
4827 MergeFrom(*::_pbi::DownCast<const BeginImplFrameArgs_TimestampsInUs*>(
4828 &from));
4829 }
4830
MergeFrom(const BeginImplFrameArgs_TimestampsInUs & from)4831 void BeginImplFrameArgs_TimestampsInUs::MergeFrom(const BeginImplFrameArgs_TimestampsInUs& from) {
4832 BeginImplFrameArgs_TimestampsInUs* const _this = this;
4833 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4834 GOOGLE_DCHECK_NE(&from, _this);
4835 ::uint32_t cached_has_bits = 0;
4836 (void) cached_has_bits;
4837
4838 cached_has_bits = from._impl_._has_bits_[0];
4839 if (cached_has_bits & 0x0000007fu) {
4840 if (cached_has_bits & 0x00000001u) {
4841 _this->_impl_.interval_delta_ = from._impl_.interval_delta_;
4842 }
4843 if (cached_has_bits & 0x00000002u) {
4844 _this->_impl_.now_to_deadline_delta_ = from._impl_.now_to_deadline_delta_;
4845 }
4846 if (cached_has_bits & 0x00000004u) {
4847 _this->_impl_.frame_time_to_now_delta_ = from._impl_.frame_time_to_now_delta_;
4848 }
4849 if (cached_has_bits & 0x00000008u) {
4850 _this->_impl_.frame_time_to_deadline_delta_ = from._impl_.frame_time_to_deadline_delta_;
4851 }
4852 if (cached_has_bits & 0x00000010u) {
4853 _this->_impl_.now_ = from._impl_.now_;
4854 }
4855 if (cached_has_bits & 0x00000020u) {
4856 _this->_impl_.frame_time_ = from._impl_.frame_time_;
4857 }
4858 if (cached_has_bits & 0x00000040u) {
4859 _this->_impl_.deadline_ = from._impl_.deadline_;
4860 }
4861 _this->_impl_._has_bits_[0] |= cached_has_bits;
4862 }
4863 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4864 }
4865
CopyFrom(const BeginImplFrameArgs_TimestampsInUs & from)4866 void BeginImplFrameArgs_TimestampsInUs::CopyFrom(const BeginImplFrameArgs_TimestampsInUs& from) {
4867 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.BeginImplFrameArgs.TimestampsInUs)
4868 if (&from == this) return;
4869 Clear();
4870 MergeFrom(from);
4871 }
4872
IsInitialized() const4873 bool BeginImplFrameArgs_TimestampsInUs::IsInitialized() const {
4874 return true;
4875 }
4876
InternalSwap(BeginImplFrameArgs_TimestampsInUs * other)4877 void BeginImplFrameArgs_TimestampsInUs::InternalSwap(BeginImplFrameArgs_TimestampsInUs* other) {
4878 using std::swap;
4879 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
4880 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
4881 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
4882 PROTOBUF_FIELD_OFFSET(BeginImplFrameArgs_TimestampsInUs, _impl_.deadline_)
4883 + sizeof(BeginImplFrameArgs_TimestampsInUs::_impl_.deadline_) // NOLINT
4884 - PROTOBUF_FIELD_OFFSET(BeginImplFrameArgs_TimestampsInUs, _impl_.interval_delta_)>(
4885 reinterpret_cast<char*>(&_impl_.interval_delta_),
4886 reinterpret_cast<char*>(&other->_impl_.interval_delta_));
4887 }
4888
GetTypeName() const4889 std::string BeginImplFrameArgs_TimestampsInUs::GetTypeName() const {
4890 return "perfetto.protos.BeginImplFrameArgs.TimestampsInUs";
4891 }
4892
4893
4894 // ===================================================================
4895
4896 class BeginImplFrameArgs::_Internal {
4897 public:
4898 using HasBits = decltype(std::declval<BeginImplFrameArgs>()._impl_._has_bits_);
set_has_updated_at_us(HasBits * has_bits)4899 static void set_has_updated_at_us(HasBits* has_bits) {
4900 (*has_bits)[0] |= 2u;
4901 }
set_has_finished_at_us(HasBits * has_bits)4902 static void set_has_finished_at_us(HasBits* has_bits) {
4903 (*has_bits)[0] |= 4u;
4904 }
set_has_state(HasBits * has_bits)4905 static void set_has_state(HasBits* has_bits) {
4906 (*has_bits)[0] |= 8u;
4907 }
4908 static const ::perfetto::protos::BeginFrameArgs& current_args(const BeginImplFrameArgs* msg);
4909 static const ::perfetto::protos::BeginFrameArgs& last_args(const BeginImplFrameArgs* msg);
4910 static const ::perfetto::protos::BeginImplFrameArgs_TimestampsInUs& timestamps_in_us(const BeginImplFrameArgs* msg);
set_has_timestamps_in_us(HasBits * has_bits)4911 static void set_has_timestamps_in_us(HasBits* has_bits) {
4912 (*has_bits)[0] |= 1u;
4913 }
4914 };
4915
4916 const ::perfetto::protos::BeginFrameArgs&
current_args(const BeginImplFrameArgs * msg)4917 BeginImplFrameArgs::_Internal::current_args(const BeginImplFrameArgs* msg) {
4918 return *msg->_impl_.args_.current_args_;
4919 }
4920 const ::perfetto::protos::BeginFrameArgs&
last_args(const BeginImplFrameArgs * msg)4921 BeginImplFrameArgs::_Internal::last_args(const BeginImplFrameArgs* msg) {
4922 return *msg->_impl_.args_.last_args_;
4923 }
4924 const ::perfetto::protos::BeginImplFrameArgs_TimestampsInUs&
timestamps_in_us(const BeginImplFrameArgs * msg)4925 BeginImplFrameArgs::_Internal::timestamps_in_us(const BeginImplFrameArgs* msg) {
4926 return *msg->_impl_.timestamps_in_us_;
4927 }
set_allocated_current_args(::perfetto::protos::BeginFrameArgs * current_args)4928 void BeginImplFrameArgs::set_allocated_current_args(::perfetto::protos::BeginFrameArgs* current_args) {
4929 ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
4930 clear_args();
4931 if (current_args) {
4932 ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
4933 ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(current_args);
4934 if (message_arena != submessage_arena) {
4935 current_args = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
4936 message_arena, current_args, submessage_arena);
4937 }
4938 set_has_current_args();
4939 _impl_.args_.current_args_ = current_args;
4940 }
4941 // @@protoc_insertion_point(field_set_allocated:perfetto.protos.BeginImplFrameArgs.current_args)
4942 }
set_allocated_last_args(::perfetto::protos::BeginFrameArgs * last_args)4943 void BeginImplFrameArgs::set_allocated_last_args(::perfetto::protos::BeginFrameArgs* last_args) {
4944 ::PROTOBUF_NAMESPACE_ID::Arena* message_arena = GetArenaForAllocation();
4945 clear_args();
4946 if (last_args) {
4947 ::PROTOBUF_NAMESPACE_ID::Arena* submessage_arena =
4948 ::PROTOBUF_NAMESPACE_ID::Arena::InternalGetOwningArena(last_args);
4949 if (message_arena != submessage_arena) {
4950 last_args = ::PROTOBUF_NAMESPACE_ID::internal::GetOwnedMessage(
4951 message_arena, last_args, submessage_arena);
4952 }
4953 set_has_last_args();
4954 _impl_.args_.last_args_ = last_args;
4955 }
4956 // @@protoc_insertion_point(field_set_allocated:perfetto.protos.BeginImplFrameArgs.last_args)
4957 }
BeginImplFrameArgs(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)4958 BeginImplFrameArgs::BeginImplFrameArgs(::PROTOBUF_NAMESPACE_ID::Arena* arena,
4959 bool is_message_owned)
4960 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
4961 SharedCtor(arena, is_message_owned);
4962 // @@protoc_insertion_point(arena_constructor:perfetto.protos.BeginImplFrameArgs)
4963 }
BeginImplFrameArgs(const BeginImplFrameArgs & from)4964 BeginImplFrameArgs::BeginImplFrameArgs(const BeginImplFrameArgs& from)
4965 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
4966 BeginImplFrameArgs* const _this = this; (void)_this;
4967 new (&_impl_) Impl_{
4968 decltype(_impl_._has_bits_){from._impl_._has_bits_}
4969 , /*decltype(_impl_._cached_size_)*/{}
4970 , decltype(_impl_.timestamps_in_us_){nullptr}
4971 , decltype(_impl_.updated_at_us_){}
4972 , decltype(_impl_.finished_at_us_){}
4973 , decltype(_impl_.state_){}
4974 , decltype(_impl_.args_){}
4975 , /*decltype(_impl_._oneof_case_)*/{}};
4976
4977 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4978 if (from._internal_has_timestamps_in_us()) {
4979 _this->_impl_.timestamps_in_us_ = new ::perfetto::protos::BeginImplFrameArgs_TimestampsInUs(*from._impl_.timestamps_in_us_);
4980 }
4981 ::memcpy(&_impl_.updated_at_us_, &from._impl_.updated_at_us_,
4982 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.state_) -
4983 reinterpret_cast<char*>(&_impl_.updated_at_us_)) + sizeof(_impl_.state_));
4984 clear_has_args();
4985 switch (from.args_case()) {
4986 case kCurrentArgs: {
4987 _this->_internal_mutable_current_args()->::perfetto::protos::BeginFrameArgs::MergeFrom(
4988 from._internal_current_args());
4989 break;
4990 }
4991 case kLastArgs: {
4992 _this->_internal_mutable_last_args()->::perfetto::protos::BeginFrameArgs::MergeFrom(
4993 from._internal_last_args());
4994 break;
4995 }
4996 case ARGS_NOT_SET: {
4997 break;
4998 }
4999 }
5000 // @@protoc_insertion_point(copy_constructor:perfetto.protos.BeginImplFrameArgs)
5001 }
5002
SharedCtor(::_pb::Arena * arena,bool is_message_owned)5003 inline void BeginImplFrameArgs::SharedCtor(
5004 ::_pb::Arena* arena, bool is_message_owned) {
5005 (void)arena;
5006 (void)is_message_owned;
5007 new (&_impl_) Impl_{
5008 decltype(_impl_._has_bits_){}
5009 , /*decltype(_impl_._cached_size_)*/{}
5010 , decltype(_impl_.timestamps_in_us_){nullptr}
5011 , decltype(_impl_.updated_at_us_){::int64_t{0}}
5012 , decltype(_impl_.finished_at_us_){::int64_t{0}}
5013 , decltype(_impl_.state_){0}
5014 , decltype(_impl_.args_){}
5015 , /*decltype(_impl_._oneof_case_)*/{}
5016 };
5017 clear_has_args();
5018 }
5019
~BeginImplFrameArgs()5020 BeginImplFrameArgs::~BeginImplFrameArgs() {
5021 // @@protoc_insertion_point(destructor:perfetto.protos.BeginImplFrameArgs)
5022 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
5023 (void)arena;
5024 return;
5025 }
5026 SharedDtor();
5027 }
5028
SharedDtor()5029 inline void BeginImplFrameArgs::SharedDtor() {
5030 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
5031 if (this != internal_default_instance()) delete _impl_.timestamps_in_us_;
5032 if (has_args()) {
5033 clear_args();
5034 }
5035 }
5036
SetCachedSize(int size) const5037 void BeginImplFrameArgs::SetCachedSize(int size) const {
5038 _impl_._cached_size_.Set(size);
5039 }
5040
clear_args()5041 void BeginImplFrameArgs::clear_args() {
5042 // @@protoc_insertion_point(one_of_clear_start:perfetto.protos.BeginImplFrameArgs)
5043 switch (args_case()) {
5044 case kCurrentArgs: {
5045 if (GetArenaForAllocation() == nullptr) {
5046 delete _impl_.args_.current_args_;
5047 }
5048 break;
5049 }
5050 case kLastArgs: {
5051 if (GetArenaForAllocation() == nullptr) {
5052 delete _impl_.args_.last_args_;
5053 }
5054 break;
5055 }
5056 case ARGS_NOT_SET: {
5057 break;
5058 }
5059 }
5060 _impl_._oneof_case_[0] = ARGS_NOT_SET;
5061 }
5062
5063
Clear()5064 void BeginImplFrameArgs::Clear() {
5065 // @@protoc_insertion_point(message_clear_start:perfetto.protos.BeginImplFrameArgs)
5066 ::uint32_t cached_has_bits = 0;
5067 // Prevent compiler warnings about cached_has_bits being unused
5068 (void) cached_has_bits;
5069
5070 cached_has_bits = _impl_._has_bits_[0];
5071 if (cached_has_bits & 0x00000001u) {
5072 GOOGLE_DCHECK(_impl_.timestamps_in_us_ != nullptr);
5073 _impl_.timestamps_in_us_->Clear();
5074 }
5075 if (cached_has_bits & 0x0000000eu) {
5076 ::memset(&_impl_.updated_at_us_, 0, static_cast<size_t>(
5077 reinterpret_cast<char*>(&_impl_.state_) -
5078 reinterpret_cast<char*>(&_impl_.updated_at_us_)) + sizeof(_impl_.state_));
5079 }
5080 clear_args();
5081 _impl_._has_bits_.Clear();
5082 _internal_metadata_.Clear<std::string>();
5083 }
5084
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)5085 const char* BeginImplFrameArgs::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
5086 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
5087 _Internal::HasBits has_bits{};
5088 while (!ctx->Done(&ptr)) {
5089 ::uint32_t tag;
5090 ptr = ::_pbi::ReadTag(ptr, &tag);
5091 switch (tag >> 3) {
5092 // optional int64 updated_at_us = 1;
5093 case 1:
5094 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
5095 _Internal::set_has_updated_at_us(&has_bits);
5096 _impl_.updated_at_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5097 CHK_(ptr);
5098 } else {
5099 goto handle_unusual;
5100 }
5101 continue;
5102 // optional int64 finished_at_us = 2;
5103 case 2:
5104 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
5105 _Internal::set_has_finished_at_us(&has_bits);
5106 _impl_.finished_at_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5107 CHK_(ptr);
5108 } else {
5109 goto handle_unusual;
5110 }
5111 continue;
5112 // optional .perfetto.protos.BeginImplFrameArgs.State state = 3;
5113 case 3:
5114 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
5115 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5116 CHK_(ptr);
5117 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::BeginImplFrameArgs_State_IsValid(val))) {
5118 _internal_set_state(static_cast<::perfetto::protos::BeginImplFrameArgs_State>(val));
5119 } else {
5120 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(3, val, mutable_unknown_fields());
5121 }
5122 } else {
5123 goto handle_unusual;
5124 }
5125 continue;
5126 // .perfetto.protos.BeginFrameArgs current_args = 4;
5127 case 4:
5128 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 34)) {
5129 ptr = ctx->ParseMessage(_internal_mutable_current_args(), ptr);
5130 CHK_(ptr);
5131 } else {
5132 goto handle_unusual;
5133 }
5134 continue;
5135 // .perfetto.protos.BeginFrameArgs last_args = 5;
5136 case 5:
5137 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 42)) {
5138 ptr = ctx->ParseMessage(_internal_mutable_last_args(), ptr);
5139 CHK_(ptr);
5140 } else {
5141 goto handle_unusual;
5142 }
5143 continue;
5144 // optional .perfetto.protos.BeginImplFrameArgs.TimestampsInUs timestamps_in_us = 6;
5145 case 6:
5146 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 50)) {
5147 ptr = ctx->ParseMessage(_internal_mutable_timestamps_in_us(), ptr);
5148 CHK_(ptr);
5149 } else {
5150 goto handle_unusual;
5151 }
5152 continue;
5153 default:
5154 goto handle_unusual;
5155 } // switch
5156 handle_unusual:
5157 if ((tag == 0) || ((tag & 7) == 4)) {
5158 CHK_(ptr);
5159 ctx->SetLastTag(tag);
5160 goto message_done;
5161 }
5162 ptr = UnknownFieldParse(
5163 tag,
5164 _internal_metadata_.mutable_unknown_fields<std::string>(),
5165 ptr, ctx);
5166 CHK_(ptr != nullptr);
5167 } // while
5168 message_done:
5169 _impl_._has_bits_.Or(has_bits);
5170 return ptr;
5171 failure:
5172 ptr = nullptr;
5173 goto message_done;
5174 #undef CHK_
5175 }
5176
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const5177 ::uint8_t* BeginImplFrameArgs::_InternalSerialize(
5178 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
5179 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.BeginImplFrameArgs)
5180 ::uint32_t cached_has_bits = 0;
5181 (void) cached_has_bits;
5182
5183 cached_has_bits = _impl_._has_bits_[0];
5184 // optional int64 updated_at_us = 1;
5185 if (cached_has_bits & 0x00000002u) {
5186 target = stream->EnsureSpace(target);
5187 target = ::_pbi::WireFormatLite::WriteInt64ToArray(1, this->_internal_updated_at_us(), target);
5188 }
5189
5190 // optional int64 finished_at_us = 2;
5191 if (cached_has_bits & 0x00000004u) {
5192 target = stream->EnsureSpace(target);
5193 target = ::_pbi::WireFormatLite::WriteInt64ToArray(2, this->_internal_finished_at_us(), target);
5194 }
5195
5196 // optional .perfetto.protos.BeginImplFrameArgs.State state = 3;
5197 if (cached_has_bits & 0x00000008u) {
5198 target = stream->EnsureSpace(target);
5199 target = ::_pbi::WireFormatLite::WriteEnumToArray(
5200 3, this->_internal_state(), target);
5201 }
5202
5203 switch (args_case()) {
5204 case kCurrentArgs: {
5205 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5206 InternalWriteMessage(4, _Internal::current_args(this),
5207 _Internal::current_args(this).GetCachedSize(), target, stream);
5208 break;
5209 }
5210 case kLastArgs: {
5211 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5212 InternalWriteMessage(5, _Internal::last_args(this),
5213 _Internal::last_args(this).GetCachedSize(), target, stream);
5214 break;
5215 }
5216 default: ;
5217 }
5218 // optional .perfetto.protos.BeginImplFrameArgs.TimestampsInUs timestamps_in_us = 6;
5219 if (cached_has_bits & 0x00000001u) {
5220 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5221 InternalWriteMessage(6, _Internal::timestamps_in_us(this),
5222 _Internal::timestamps_in_us(this).GetCachedSize(), target, stream);
5223 }
5224
5225 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5226 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
5227 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
5228 }
5229 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.BeginImplFrameArgs)
5230 return target;
5231 }
5232
ByteSizeLong() const5233 size_t BeginImplFrameArgs::ByteSizeLong() const {
5234 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.BeginImplFrameArgs)
5235 size_t total_size = 0;
5236
5237 ::uint32_t cached_has_bits = 0;
5238 // Prevent compiler warnings about cached_has_bits being unused
5239 (void) cached_has_bits;
5240
5241 cached_has_bits = _impl_._has_bits_[0];
5242 if (cached_has_bits & 0x0000000fu) {
5243 // optional .perfetto.protos.BeginImplFrameArgs.TimestampsInUs timestamps_in_us = 6;
5244 if (cached_has_bits & 0x00000001u) {
5245 total_size += 1 +
5246 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5247 *_impl_.timestamps_in_us_);
5248 }
5249
5250 // optional int64 updated_at_us = 1;
5251 if (cached_has_bits & 0x00000002u) {
5252 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_updated_at_us());
5253 }
5254
5255 // optional int64 finished_at_us = 2;
5256 if (cached_has_bits & 0x00000004u) {
5257 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_finished_at_us());
5258 }
5259
5260 // optional .perfetto.protos.BeginImplFrameArgs.State state = 3;
5261 if (cached_has_bits & 0x00000008u) {
5262 total_size += 1 +
5263 ::_pbi::WireFormatLite::EnumSize(this->_internal_state());
5264 }
5265
5266 }
5267 switch (args_case()) {
5268 // .perfetto.protos.BeginFrameArgs current_args = 4;
5269 case kCurrentArgs: {
5270 total_size += 1 +
5271 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5272 *_impl_.args_.current_args_);
5273 break;
5274 }
5275 // .perfetto.protos.BeginFrameArgs last_args = 5;
5276 case kLastArgs: {
5277 total_size += 1 +
5278 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5279 *_impl_.args_.last_args_);
5280 break;
5281 }
5282 case ARGS_NOT_SET: {
5283 break;
5284 }
5285 }
5286 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5287 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
5288 }
5289 int cached_size = ::_pbi::ToCachedSize(total_size);
5290 SetCachedSize(cached_size);
5291 return total_size;
5292 }
5293
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)5294 void BeginImplFrameArgs::CheckTypeAndMergeFrom(
5295 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
5296 MergeFrom(*::_pbi::DownCast<const BeginImplFrameArgs*>(
5297 &from));
5298 }
5299
MergeFrom(const BeginImplFrameArgs & from)5300 void BeginImplFrameArgs::MergeFrom(const BeginImplFrameArgs& from) {
5301 BeginImplFrameArgs* const _this = this;
5302 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.BeginImplFrameArgs)
5303 GOOGLE_DCHECK_NE(&from, _this);
5304 ::uint32_t cached_has_bits = 0;
5305 (void) cached_has_bits;
5306
5307 cached_has_bits = from._impl_._has_bits_[0];
5308 if (cached_has_bits & 0x0000000fu) {
5309 if (cached_has_bits & 0x00000001u) {
5310 _this->_internal_mutable_timestamps_in_us()->::perfetto::protos::BeginImplFrameArgs_TimestampsInUs::MergeFrom(
5311 from._internal_timestamps_in_us());
5312 }
5313 if (cached_has_bits & 0x00000002u) {
5314 _this->_impl_.updated_at_us_ = from._impl_.updated_at_us_;
5315 }
5316 if (cached_has_bits & 0x00000004u) {
5317 _this->_impl_.finished_at_us_ = from._impl_.finished_at_us_;
5318 }
5319 if (cached_has_bits & 0x00000008u) {
5320 _this->_impl_.state_ = from._impl_.state_;
5321 }
5322 _this->_impl_._has_bits_[0] |= cached_has_bits;
5323 }
5324 switch (from.args_case()) {
5325 case kCurrentArgs: {
5326 _this->_internal_mutable_current_args()->::perfetto::protos::BeginFrameArgs::MergeFrom(
5327 from._internal_current_args());
5328 break;
5329 }
5330 case kLastArgs: {
5331 _this->_internal_mutable_last_args()->::perfetto::protos::BeginFrameArgs::MergeFrom(
5332 from._internal_last_args());
5333 break;
5334 }
5335 case ARGS_NOT_SET: {
5336 break;
5337 }
5338 }
5339 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5340 }
5341
CopyFrom(const BeginImplFrameArgs & from)5342 void BeginImplFrameArgs::CopyFrom(const BeginImplFrameArgs& from) {
5343 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.BeginImplFrameArgs)
5344 if (&from == this) return;
5345 Clear();
5346 MergeFrom(from);
5347 }
5348
IsInitialized() const5349 bool BeginImplFrameArgs::IsInitialized() const {
5350 return true;
5351 }
5352
InternalSwap(BeginImplFrameArgs * other)5353 void BeginImplFrameArgs::InternalSwap(BeginImplFrameArgs* other) {
5354 using std::swap;
5355 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
5356 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
5357 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
5358 PROTOBUF_FIELD_OFFSET(BeginImplFrameArgs, _impl_.state_)
5359 + sizeof(BeginImplFrameArgs::_impl_.state_) // NOLINT
5360 - PROTOBUF_FIELD_OFFSET(BeginImplFrameArgs, _impl_.timestamps_in_us_)>(
5361 reinterpret_cast<char*>(&_impl_.timestamps_in_us_),
5362 reinterpret_cast<char*>(&other->_impl_.timestamps_in_us_));
5363 swap(_impl_.args_, other->_impl_.args_);
5364 swap(_impl_._oneof_case_[0], other->_impl_._oneof_case_[0]);
5365 }
5366
GetTypeName() const5367 std::string BeginImplFrameArgs::GetTypeName() const {
5368 return "perfetto.protos.BeginImplFrameArgs";
5369 }
5370
5371
5372 // ===================================================================
5373
5374 class BeginFrameObserverState::_Internal {
5375 public:
5376 using HasBits = decltype(std::declval<BeginFrameObserverState>()._impl_._has_bits_);
set_has_dropped_begin_frame_args(HasBits * has_bits)5377 static void set_has_dropped_begin_frame_args(HasBits* has_bits) {
5378 (*has_bits)[0] |= 2u;
5379 }
5380 static const ::perfetto::protos::BeginFrameArgs& last_begin_frame_args(const BeginFrameObserverState* msg);
set_has_last_begin_frame_args(HasBits * has_bits)5381 static void set_has_last_begin_frame_args(HasBits* has_bits) {
5382 (*has_bits)[0] |= 1u;
5383 }
5384 };
5385
5386 const ::perfetto::protos::BeginFrameArgs&
last_begin_frame_args(const BeginFrameObserverState * msg)5387 BeginFrameObserverState::_Internal::last_begin_frame_args(const BeginFrameObserverState* msg) {
5388 return *msg->_impl_.last_begin_frame_args_;
5389 }
BeginFrameObserverState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)5390 BeginFrameObserverState::BeginFrameObserverState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
5391 bool is_message_owned)
5392 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
5393 SharedCtor(arena, is_message_owned);
5394 // @@protoc_insertion_point(arena_constructor:perfetto.protos.BeginFrameObserverState)
5395 }
BeginFrameObserverState(const BeginFrameObserverState & from)5396 BeginFrameObserverState::BeginFrameObserverState(const BeginFrameObserverState& from)
5397 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
5398 BeginFrameObserverState* const _this = this; (void)_this;
5399 new (&_impl_) Impl_{
5400 decltype(_impl_._has_bits_){from._impl_._has_bits_}
5401 , /*decltype(_impl_._cached_size_)*/{}
5402 , decltype(_impl_.last_begin_frame_args_){nullptr}
5403 , decltype(_impl_.dropped_begin_frame_args_){}};
5404
5405 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5406 if (from._internal_has_last_begin_frame_args()) {
5407 _this->_impl_.last_begin_frame_args_ = new ::perfetto::protos::BeginFrameArgs(*from._impl_.last_begin_frame_args_);
5408 }
5409 _this->_impl_.dropped_begin_frame_args_ = from._impl_.dropped_begin_frame_args_;
5410 // @@protoc_insertion_point(copy_constructor:perfetto.protos.BeginFrameObserverState)
5411 }
5412
SharedCtor(::_pb::Arena * arena,bool is_message_owned)5413 inline void BeginFrameObserverState::SharedCtor(
5414 ::_pb::Arena* arena, bool is_message_owned) {
5415 (void)arena;
5416 (void)is_message_owned;
5417 new (&_impl_) Impl_{
5418 decltype(_impl_._has_bits_){}
5419 , /*decltype(_impl_._cached_size_)*/{}
5420 , decltype(_impl_.last_begin_frame_args_){nullptr}
5421 , decltype(_impl_.dropped_begin_frame_args_){::int64_t{0}}
5422 };
5423 }
5424
~BeginFrameObserverState()5425 BeginFrameObserverState::~BeginFrameObserverState() {
5426 // @@protoc_insertion_point(destructor:perfetto.protos.BeginFrameObserverState)
5427 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
5428 (void)arena;
5429 return;
5430 }
5431 SharedDtor();
5432 }
5433
SharedDtor()5434 inline void BeginFrameObserverState::SharedDtor() {
5435 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
5436 if (this != internal_default_instance()) delete _impl_.last_begin_frame_args_;
5437 }
5438
SetCachedSize(int size) const5439 void BeginFrameObserverState::SetCachedSize(int size) const {
5440 _impl_._cached_size_.Set(size);
5441 }
5442
Clear()5443 void BeginFrameObserverState::Clear() {
5444 // @@protoc_insertion_point(message_clear_start:perfetto.protos.BeginFrameObserverState)
5445 ::uint32_t cached_has_bits = 0;
5446 // Prevent compiler warnings about cached_has_bits being unused
5447 (void) cached_has_bits;
5448
5449 cached_has_bits = _impl_._has_bits_[0];
5450 if (cached_has_bits & 0x00000001u) {
5451 GOOGLE_DCHECK(_impl_.last_begin_frame_args_ != nullptr);
5452 _impl_.last_begin_frame_args_->Clear();
5453 }
5454 _impl_.dropped_begin_frame_args_ = ::int64_t{0};
5455 _impl_._has_bits_.Clear();
5456 _internal_metadata_.Clear<std::string>();
5457 }
5458
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)5459 const char* BeginFrameObserverState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
5460 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
5461 _Internal::HasBits has_bits{};
5462 while (!ctx->Done(&ptr)) {
5463 ::uint32_t tag;
5464 ptr = ::_pbi::ReadTag(ptr, &tag);
5465 switch (tag >> 3) {
5466 // optional int64 dropped_begin_frame_args = 1;
5467 case 1:
5468 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
5469 _Internal::set_has_dropped_begin_frame_args(&has_bits);
5470 _impl_.dropped_begin_frame_args_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5471 CHK_(ptr);
5472 } else {
5473 goto handle_unusual;
5474 }
5475 continue;
5476 // optional .perfetto.protos.BeginFrameArgs last_begin_frame_args = 2;
5477 case 2:
5478 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
5479 ptr = ctx->ParseMessage(_internal_mutable_last_begin_frame_args(), ptr);
5480 CHK_(ptr);
5481 } else {
5482 goto handle_unusual;
5483 }
5484 continue;
5485 default:
5486 goto handle_unusual;
5487 } // switch
5488 handle_unusual:
5489 if ((tag == 0) || ((tag & 7) == 4)) {
5490 CHK_(ptr);
5491 ctx->SetLastTag(tag);
5492 goto message_done;
5493 }
5494 ptr = UnknownFieldParse(
5495 tag,
5496 _internal_metadata_.mutable_unknown_fields<std::string>(),
5497 ptr, ctx);
5498 CHK_(ptr != nullptr);
5499 } // while
5500 message_done:
5501 _impl_._has_bits_.Or(has_bits);
5502 return ptr;
5503 failure:
5504 ptr = nullptr;
5505 goto message_done;
5506 #undef CHK_
5507 }
5508
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const5509 ::uint8_t* BeginFrameObserverState::_InternalSerialize(
5510 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
5511 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.BeginFrameObserverState)
5512 ::uint32_t cached_has_bits = 0;
5513 (void) cached_has_bits;
5514
5515 cached_has_bits = _impl_._has_bits_[0];
5516 // optional int64 dropped_begin_frame_args = 1;
5517 if (cached_has_bits & 0x00000002u) {
5518 target = stream->EnsureSpace(target);
5519 target = ::_pbi::WireFormatLite::WriteInt64ToArray(1, this->_internal_dropped_begin_frame_args(), target);
5520 }
5521
5522 // optional .perfetto.protos.BeginFrameArgs last_begin_frame_args = 2;
5523 if (cached_has_bits & 0x00000001u) {
5524 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5525 InternalWriteMessage(2, _Internal::last_begin_frame_args(this),
5526 _Internal::last_begin_frame_args(this).GetCachedSize(), target, stream);
5527 }
5528
5529 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5530 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
5531 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
5532 }
5533 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.BeginFrameObserverState)
5534 return target;
5535 }
5536
ByteSizeLong() const5537 size_t BeginFrameObserverState::ByteSizeLong() const {
5538 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.BeginFrameObserverState)
5539 size_t total_size = 0;
5540
5541 ::uint32_t cached_has_bits = 0;
5542 // Prevent compiler warnings about cached_has_bits being unused
5543 (void) cached_has_bits;
5544
5545 cached_has_bits = _impl_._has_bits_[0];
5546 if (cached_has_bits & 0x00000003u) {
5547 // optional .perfetto.protos.BeginFrameArgs last_begin_frame_args = 2;
5548 if (cached_has_bits & 0x00000001u) {
5549 total_size += 1 +
5550 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5551 *_impl_.last_begin_frame_args_);
5552 }
5553
5554 // optional int64 dropped_begin_frame_args = 1;
5555 if (cached_has_bits & 0x00000002u) {
5556 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_dropped_begin_frame_args());
5557 }
5558
5559 }
5560 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5561 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
5562 }
5563 int cached_size = ::_pbi::ToCachedSize(total_size);
5564 SetCachedSize(cached_size);
5565 return total_size;
5566 }
5567
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)5568 void BeginFrameObserverState::CheckTypeAndMergeFrom(
5569 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
5570 MergeFrom(*::_pbi::DownCast<const BeginFrameObserverState*>(
5571 &from));
5572 }
5573
MergeFrom(const BeginFrameObserverState & from)5574 void BeginFrameObserverState::MergeFrom(const BeginFrameObserverState& from) {
5575 BeginFrameObserverState* const _this = this;
5576 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.BeginFrameObserverState)
5577 GOOGLE_DCHECK_NE(&from, _this);
5578 ::uint32_t cached_has_bits = 0;
5579 (void) cached_has_bits;
5580
5581 cached_has_bits = from._impl_._has_bits_[0];
5582 if (cached_has_bits & 0x00000003u) {
5583 if (cached_has_bits & 0x00000001u) {
5584 _this->_internal_mutable_last_begin_frame_args()->::perfetto::protos::BeginFrameArgs::MergeFrom(
5585 from._internal_last_begin_frame_args());
5586 }
5587 if (cached_has_bits & 0x00000002u) {
5588 _this->_impl_.dropped_begin_frame_args_ = from._impl_.dropped_begin_frame_args_;
5589 }
5590 _this->_impl_._has_bits_[0] |= cached_has_bits;
5591 }
5592 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5593 }
5594
CopyFrom(const BeginFrameObserverState & from)5595 void BeginFrameObserverState::CopyFrom(const BeginFrameObserverState& from) {
5596 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.BeginFrameObserverState)
5597 if (&from == this) return;
5598 Clear();
5599 MergeFrom(from);
5600 }
5601
IsInitialized() const5602 bool BeginFrameObserverState::IsInitialized() const {
5603 return true;
5604 }
5605
InternalSwap(BeginFrameObserverState * other)5606 void BeginFrameObserverState::InternalSwap(BeginFrameObserverState* other) {
5607 using std::swap;
5608 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
5609 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
5610 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
5611 PROTOBUF_FIELD_OFFSET(BeginFrameObserverState, _impl_.dropped_begin_frame_args_)
5612 + sizeof(BeginFrameObserverState::_impl_.dropped_begin_frame_args_) // NOLINT
5613 - PROTOBUF_FIELD_OFFSET(BeginFrameObserverState, _impl_.last_begin_frame_args_)>(
5614 reinterpret_cast<char*>(&_impl_.last_begin_frame_args_),
5615 reinterpret_cast<char*>(&other->_impl_.last_begin_frame_args_));
5616 }
5617
GetTypeName() const5618 std::string BeginFrameObserverState::GetTypeName() const {
5619 return "perfetto.protos.BeginFrameObserverState";
5620 }
5621
5622
5623 // ===================================================================
5624
5625 class BeginFrameSourceState::_Internal {
5626 public:
5627 using HasBits = decltype(std::declval<BeginFrameSourceState>()._impl_._has_bits_);
set_has_source_id(HasBits * has_bits)5628 static void set_has_source_id(HasBits* has_bits) {
5629 (*has_bits)[0] |= 2u;
5630 }
set_has_paused(HasBits * has_bits)5631 static void set_has_paused(HasBits* has_bits) {
5632 (*has_bits)[0] |= 4u;
5633 }
set_has_num_observers(HasBits * has_bits)5634 static void set_has_num_observers(HasBits* has_bits) {
5635 (*has_bits)[0] |= 8u;
5636 }
5637 static const ::perfetto::protos::BeginFrameArgs& last_begin_frame_args(const BeginFrameSourceState* msg);
set_has_last_begin_frame_args(HasBits * has_bits)5638 static void set_has_last_begin_frame_args(HasBits* has_bits) {
5639 (*has_bits)[0] |= 1u;
5640 }
5641 };
5642
5643 const ::perfetto::protos::BeginFrameArgs&
last_begin_frame_args(const BeginFrameSourceState * msg)5644 BeginFrameSourceState::_Internal::last_begin_frame_args(const BeginFrameSourceState* msg) {
5645 return *msg->_impl_.last_begin_frame_args_;
5646 }
BeginFrameSourceState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)5647 BeginFrameSourceState::BeginFrameSourceState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
5648 bool is_message_owned)
5649 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
5650 SharedCtor(arena, is_message_owned);
5651 // @@protoc_insertion_point(arena_constructor:perfetto.protos.BeginFrameSourceState)
5652 }
BeginFrameSourceState(const BeginFrameSourceState & from)5653 BeginFrameSourceState::BeginFrameSourceState(const BeginFrameSourceState& from)
5654 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
5655 BeginFrameSourceState* const _this = this; (void)_this;
5656 new (&_impl_) Impl_{
5657 decltype(_impl_._has_bits_){from._impl_._has_bits_}
5658 , /*decltype(_impl_._cached_size_)*/{}
5659 , decltype(_impl_.last_begin_frame_args_){nullptr}
5660 , decltype(_impl_.source_id_){}
5661 , decltype(_impl_.paused_){}
5662 , decltype(_impl_.num_observers_){}};
5663
5664 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5665 if (from._internal_has_last_begin_frame_args()) {
5666 _this->_impl_.last_begin_frame_args_ = new ::perfetto::protos::BeginFrameArgs(*from._impl_.last_begin_frame_args_);
5667 }
5668 ::memcpy(&_impl_.source_id_, &from._impl_.source_id_,
5669 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.num_observers_) -
5670 reinterpret_cast<char*>(&_impl_.source_id_)) + sizeof(_impl_.num_observers_));
5671 // @@protoc_insertion_point(copy_constructor:perfetto.protos.BeginFrameSourceState)
5672 }
5673
SharedCtor(::_pb::Arena * arena,bool is_message_owned)5674 inline void BeginFrameSourceState::SharedCtor(
5675 ::_pb::Arena* arena, bool is_message_owned) {
5676 (void)arena;
5677 (void)is_message_owned;
5678 new (&_impl_) Impl_{
5679 decltype(_impl_._has_bits_){}
5680 , /*decltype(_impl_._cached_size_)*/{}
5681 , decltype(_impl_.last_begin_frame_args_){nullptr}
5682 , decltype(_impl_.source_id_){0u}
5683 , decltype(_impl_.paused_){false}
5684 , decltype(_impl_.num_observers_){0u}
5685 };
5686 }
5687
~BeginFrameSourceState()5688 BeginFrameSourceState::~BeginFrameSourceState() {
5689 // @@protoc_insertion_point(destructor:perfetto.protos.BeginFrameSourceState)
5690 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
5691 (void)arena;
5692 return;
5693 }
5694 SharedDtor();
5695 }
5696
SharedDtor()5697 inline void BeginFrameSourceState::SharedDtor() {
5698 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
5699 if (this != internal_default_instance()) delete _impl_.last_begin_frame_args_;
5700 }
5701
SetCachedSize(int size) const5702 void BeginFrameSourceState::SetCachedSize(int size) const {
5703 _impl_._cached_size_.Set(size);
5704 }
5705
Clear()5706 void BeginFrameSourceState::Clear() {
5707 // @@protoc_insertion_point(message_clear_start:perfetto.protos.BeginFrameSourceState)
5708 ::uint32_t cached_has_bits = 0;
5709 // Prevent compiler warnings about cached_has_bits being unused
5710 (void) cached_has_bits;
5711
5712 cached_has_bits = _impl_._has_bits_[0];
5713 if (cached_has_bits & 0x00000001u) {
5714 GOOGLE_DCHECK(_impl_.last_begin_frame_args_ != nullptr);
5715 _impl_.last_begin_frame_args_->Clear();
5716 }
5717 if (cached_has_bits & 0x0000000eu) {
5718 ::memset(&_impl_.source_id_, 0, static_cast<size_t>(
5719 reinterpret_cast<char*>(&_impl_.num_observers_) -
5720 reinterpret_cast<char*>(&_impl_.source_id_)) + sizeof(_impl_.num_observers_));
5721 }
5722 _impl_._has_bits_.Clear();
5723 _internal_metadata_.Clear<std::string>();
5724 }
5725
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)5726 const char* BeginFrameSourceState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
5727 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
5728 _Internal::HasBits has_bits{};
5729 while (!ctx->Done(&ptr)) {
5730 ::uint32_t tag;
5731 ptr = ::_pbi::ReadTag(ptr, &tag);
5732 switch (tag >> 3) {
5733 // optional uint32 source_id = 1;
5734 case 1:
5735 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
5736 _Internal::set_has_source_id(&has_bits);
5737 _impl_.source_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5738 CHK_(ptr);
5739 } else {
5740 goto handle_unusual;
5741 }
5742 continue;
5743 // optional bool paused = 2;
5744 case 2:
5745 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
5746 _Internal::set_has_paused(&has_bits);
5747 _impl_.paused_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5748 CHK_(ptr);
5749 } else {
5750 goto handle_unusual;
5751 }
5752 continue;
5753 // optional uint32 num_observers = 3;
5754 case 3:
5755 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
5756 _Internal::set_has_num_observers(&has_bits);
5757 _impl_.num_observers_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5758 CHK_(ptr);
5759 } else {
5760 goto handle_unusual;
5761 }
5762 continue;
5763 // optional .perfetto.protos.BeginFrameArgs last_begin_frame_args = 4;
5764 case 4:
5765 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 34)) {
5766 ptr = ctx->ParseMessage(_internal_mutable_last_begin_frame_args(), ptr);
5767 CHK_(ptr);
5768 } else {
5769 goto handle_unusual;
5770 }
5771 continue;
5772 default:
5773 goto handle_unusual;
5774 } // switch
5775 handle_unusual:
5776 if ((tag == 0) || ((tag & 7) == 4)) {
5777 CHK_(ptr);
5778 ctx->SetLastTag(tag);
5779 goto message_done;
5780 }
5781 ptr = UnknownFieldParse(
5782 tag,
5783 _internal_metadata_.mutable_unknown_fields<std::string>(),
5784 ptr, ctx);
5785 CHK_(ptr != nullptr);
5786 } // while
5787 message_done:
5788 _impl_._has_bits_.Or(has_bits);
5789 return ptr;
5790 failure:
5791 ptr = nullptr;
5792 goto message_done;
5793 #undef CHK_
5794 }
5795
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const5796 ::uint8_t* BeginFrameSourceState::_InternalSerialize(
5797 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
5798 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.BeginFrameSourceState)
5799 ::uint32_t cached_has_bits = 0;
5800 (void) cached_has_bits;
5801
5802 cached_has_bits = _impl_._has_bits_[0];
5803 // optional uint32 source_id = 1;
5804 if (cached_has_bits & 0x00000002u) {
5805 target = stream->EnsureSpace(target);
5806 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(1, this->_internal_source_id(), target);
5807 }
5808
5809 // optional bool paused = 2;
5810 if (cached_has_bits & 0x00000004u) {
5811 target = stream->EnsureSpace(target);
5812 target = ::_pbi::WireFormatLite::WriteBoolToArray(2, this->_internal_paused(), target);
5813 }
5814
5815 // optional uint32 num_observers = 3;
5816 if (cached_has_bits & 0x00000008u) {
5817 target = stream->EnsureSpace(target);
5818 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(3, this->_internal_num_observers(), target);
5819 }
5820
5821 // optional .perfetto.protos.BeginFrameArgs last_begin_frame_args = 4;
5822 if (cached_has_bits & 0x00000001u) {
5823 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5824 InternalWriteMessage(4, _Internal::last_begin_frame_args(this),
5825 _Internal::last_begin_frame_args(this).GetCachedSize(), target, stream);
5826 }
5827
5828 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5829 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
5830 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
5831 }
5832 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.BeginFrameSourceState)
5833 return target;
5834 }
5835
ByteSizeLong() const5836 size_t BeginFrameSourceState::ByteSizeLong() const {
5837 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.BeginFrameSourceState)
5838 size_t total_size = 0;
5839
5840 ::uint32_t cached_has_bits = 0;
5841 // Prevent compiler warnings about cached_has_bits being unused
5842 (void) cached_has_bits;
5843
5844 cached_has_bits = _impl_._has_bits_[0];
5845 if (cached_has_bits & 0x0000000fu) {
5846 // optional .perfetto.protos.BeginFrameArgs last_begin_frame_args = 4;
5847 if (cached_has_bits & 0x00000001u) {
5848 total_size += 1 +
5849 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5850 *_impl_.last_begin_frame_args_);
5851 }
5852
5853 // optional uint32 source_id = 1;
5854 if (cached_has_bits & 0x00000002u) {
5855 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_source_id());
5856 }
5857
5858 // optional bool paused = 2;
5859 if (cached_has_bits & 0x00000004u) {
5860 total_size += 1 + 1;
5861 }
5862
5863 // optional uint32 num_observers = 3;
5864 if (cached_has_bits & 0x00000008u) {
5865 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_num_observers());
5866 }
5867
5868 }
5869 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5870 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
5871 }
5872 int cached_size = ::_pbi::ToCachedSize(total_size);
5873 SetCachedSize(cached_size);
5874 return total_size;
5875 }
5876
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)5877 void BeginFrameSourceState::CheckTypeAndMergeFrom(
5878 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
5879 MergeFrom(*::_pbi::DownCast<const BeginFrameSourceState*>(
5880 &from));
5881 }
5882
MergeFrom(const BeginFrameSourceState & from)5883 void BeginFrameSourceState::MergeFrom(const BeginFrameSourceState& from) {
5884 BeginFrameSourceState* const _this = this;
5885 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.BeginFrameSourceState)
5886 GOOGLE_DCHECK_NE(&from, _this);
5887 ::uint32_t cached_has_bits = 0;
5888 (void) cached_has_bits;
5889
5890 cached_has_bits = from._impl_._has_bits_[0];
5891 if (cached_has_bits & 0x0000000fu) {
5892 if (cached_has_bits & 0x00000001u) {
5893 _this->_internal_mutable_last_begin_frame_args()->::perfetto::protos::BeginFrameArgs::MergeFrom(
5894 from._internal_last_begin_frame_args());
5895 }
5896 if (cached_has_bits & 0x00000002u) {
5897 _this->_impl_.source_id_ = from._impl_.source_id_;
5898 }
5899 if (cached_has_bits & 0x00000004u) {
5900 _this->_impl_.paused_ = from._impl_.paused_;
5901 }
5902 if (cached_has_bits & 0x00000008u) {
5903 _this->_impl_.num_observers_ = from._impl_.num_observers_;
5904 }
5905 _this->_impl_._has_bits_[0] |= cached_has_bits;
5906 }
5907 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5908 }
5909
CopyFrom(const BeginFrameSourceState & from)5910 void BeginFrameSourceState::CopyFrom(const BeginFrameSourceState& from) {
5911 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.BeginFrameSourceState)
5912 if (&from == this) return;
5913 Clear();
5914 MergeFrom(from);
5915 }
5916
IsInitialized() const5917 bool BeginFrameSourceState::IsInitialized() const {
5918 return true;
5919 }
5920
InternalSwap(BeginFrameSourceState * other)5921 void BeginFrameSourceState::InternalSwap(BeginFrameSourceState* other) {
5922 using std::swap;
5923 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
5924 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
5925 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
5926 PROTOBUF_FIELD_OFFSET(BeginFrameSourceState, _impl_.num_observers_)
5927 + sizeof(BeginFrameSourceState::_impl_.num_observers_) // NOLINT
5928 - PROTOBUF_FIELD_OFFSET(BeginFrameSourceState, _impl_.last_begin_frame_args_)>(
5929 reinterpret_cast<char*>(&_impl_.last_begin_frame_args_),
5930 reinterpret_cast<char*>(&other->_impl_.last_begin_frame_args_));
5931 }
5932
GetTypeName() const5933 std::string BeginFrameSourceState::GetTypeName() const {
5934 return "perfetto.protos.BeginFrameSourceState";
5935 }
5936
5937
5938 // ===================================================================
5939
5940 class CompositorTimingHistory::_Internal {
5941 public:
5942 using HasBits = decltype(std::declval<CompositorTimingHistory>()._impl_._has_bits_);
set_has_begin_main_frame_queue_critical_estimate_delta_us(HasBits * has_bits)5943 static void set_has_begin_main_frame_queue_critical_estimate_delta_us(HasBits* has_bits) {
5944 (*has_bits)[0] |= 1u;
5945 }
set_has_begin_main_frame_queue_not_critical_estimate_delta_us(HasBits * has_bits)5946 static void set_has_begin_main_frame_queue_not_critical_estimate_delta_us(HasBits* has_bits) {
5947 (*has_bits)[0] |= 2u;
5948 }
set_has_begin_main_frame_start_to_ready_to_commit_estimate_delta_us(HasBits * has_bits)5949 static void set_has_begin_main_frame_start_to_ready_to_commit_estimate_delta_us(HasBits* has_bits) {
5950 (*has_bits)[0] |= 4u;
5951 }
set_has_commit_to_ready_to_activate_estimate_delta_us(HasBits * has_bits)5952 static void set_has_commit_to_ready_to_activate_estimate_delta_us(HasBits* has_bits) {
5953 (*has_bits)[0] |= 8u;
5954 }
set_has_prepare_tiles_estimate_delta_us(HasBits * has_bits)5955 static void set_has_prepare_tiles_estimate_delta_us(HasBits* has_bits) {
5956 (*has_bits)[0] |= 16u;
5957 }
set_has_activate_estimate_delta_us(HasBits * has_bits)5958 static void set_has_activate_estimate_delta_us(HasBits* has_bits) {
5959 (*has_bits)[0] |= 32u;
5960 }
set_has_draw_estimate_delta_us(HasBits * has_bits)5961 static void set_has_draw_estimate_delta_us(HasBits* has_bits) {
5962 (*has_bits)[0] |= 64u;
5963 }
5964 };
5965
CompositorTimingHistory(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)5966 CompositorTimingHistory::CompositorTimingHistory(::PROTOBUF_NAMESPACE_ID::Arena* arena,
5967 bool is_message_owned)
5968 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
5969 SharedCtor(arena, is_message_owned);
5970 // @@protoc_insertion_point(arena_constructor:perfetto.protos.CompositorTimingHistory)
5971 }
CompositorTimingHistory(const CompositorTimingHistory & from)5972 CompositorTimingHistory::CompositorTimingHistory(const CompositorTimingHistory& from)
5973 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
5974 CompositorTimingHistory* const _this = this; (void)_this;
5975 new (&_impl_) Impl_{
5976 decltype(_impl_._has_bits_){from._impl_._has_bits_}
5977 , /*decltype(_impl_._cached_size_)*/{}
5978 , decltype(_impl_.begin_main_frame_queue_critical_estimate_delta_us_){}
5979 , decltype(_impl_.begin_main_frame_queue_not_critical_estimate_delta_us_){}
5980 , decltype(_impl_.begin_main_frame_start_to_ready_to_commit_estimate_delta_us_){}
5981 , decltype(_impl_.commit_to_ready_to_activate_estimate_delta_us_){}
5982 , decltype(_impl_.prepare_tiles_estimate_delta_us_){}
5983 , decltype(_impl_.activate_estimate_delta_us_){}
5984 , decltype(_impl_.draw_estimate_delta_us_){}};
5985
5986 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5987 ::memcpy(&_impl_.begin_main_frame_queue_critical_estimate_delta_us_, &from._impl_.begin_main_frame_queue_critical_estimate_delta_us_,
5988 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.draw_estimate_delta_us_) -
5989 reinterpret_cast<char*>(&_impl_.begin_main_frame_queue_critical_estimate_delta_us_)) + sizeof(_impl_.draw_estimate_delta_us_));
5990 // @@protoc_insertion_point(copy_constructor:perfetto.protos.CompositorTimingHistory)
5991 }
5992
SharedCtor(::_pb::Arena * arena,bool is_message_owned)5993 inline void CompositorTimingHistory::SharedCtor(
5994 ::_pb::Arena* arena, bool is_message_owned) {
5995 (void)arena;
5996 (void)is_message_owned;
5997 new (&_impl_) Impl_{
5998 decltype(_impl_._has_bits_){}
5999 , /*decltype(_impl_._cached_size_)*/{}
6000 , decltype(_impl_.begin_main_frame_queue_critical_estimate_delta_us_){::int64_t{0}}
6001 , decltype(_impl_.begin_main_frame_queue_not_critical_estimate_delta_us_){::int64_t{0}}
6002 , decltype(_impl_.begin_main_frame_start_to_ready_to_commit_estimate_delta_us_){::int64_t{0}}
6003 , decltype(_impl_.commit_to_ready_to_activate_estimate_delta_us_){::int64_t{0}}
6004 , decltype(_impl_.prepare_tiles_estimate_delta_us_){::int64_t{0}}
6005 , decltype(_impl_.activate_estimate_delta_us_){::int64_t{0}}
6006 , decltype(_impl_.draw_estimate_delta_us_){::int64_t{0}}
6007 };
6008 }
6009
~CompositorTimingHistory()6010 CompositorTimingHistory::~CompositorTimingHistory() {
6011 // @@protoc_insertion_point(destructor:perfetto.protos.CompositorTimingHistory)
6012 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
6013 (void)arena;
6014 return;
6015 }
6016 SharedDtor();
6017 }
6018
SharedDtor()6019 inline void CompositorTimingHistory::SharedDtor() {
6020 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
6021 }
6022
SetCachedSize(int size) const6023 void CompositorTimingHistory::SetCachedSize(int size) const {
6024 _impl_._cached_size_.Set(size);
6025 }
6026
Clear()6027 void CompositorTimingHistory::Clear() {
6028 // @@protoc_insertion_point(message_clear_start:perfetto.protos.CompositorTimingHistory)
6029 ::uint32_t cached_has_bits = 0;
6030 // Prevent compiler warnings about cached_has_bits being unused
6031 (void) cached_has_bits;
6032
6033 cached_has_bits = _impl_._has_bits_[0];
6034 if (cached_has_bits & 0x0000007fu) {
6035 ::memset(&_impl_.begin_main_frame_queue_critical_estimate_delta_us_, 0, static_cast<size_t>(
6036 reinterpret_cast<char*>(&_impl_.draw_estimate_delta_us_) -
6037 reinterpret_cast<char*>(&_impl_.begin_main_frame_queue_critical_estimate_delta_us_)) + sizeof(_impl_.draw_estimate_delta_us_));
6038 }
6039 _impl_._has_bits_.Clear();
6040 _internal_metadata_.Clear<std::string>();
6041 }
6042
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)6043 const char* CompositorTimingHistory::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
6044 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
6045 _Internal::HasBits has_bits{};
6046 while (!ctx->Done(&ptr)) {
6047 ::uint32_t tag;
6048 ptr = ::_pbi::ReadTag(ptr, &tag);
6049 switch (tag >> 3) {
6050 // optional int64 begin_main_frame_queue_critical_estimate_delta_us = 1;
6051 case 1:
6052 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
6053 _Internal::set_has_begin_main_frame_queue_critical_estimate_delta_us(&has_bits);
6054 _impl_.begin_main_frame_queue_critical_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6055 CHK_(ptr);
6056 } else {
6057 goto handle_unusual;
6058 }
6059 continue;
6060 // optional int64 begin_main_frame_queue_not_critical_estimate_delta_us = 2;
6061 case 2:
6062 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
6063 _Internal::set_has_begin_main_frame_queue_not_critical_estimate_delta_us(&has_bits);
6064 _impl_.begin_main_frame_queue_not_critical_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6065 CHK_(ptr);
6066 } else {
6067 goto handle_unusual;
6068 }
6069 continue;
6070 // optional int64 begin_main_frame_start_to_ready_to_commit_estimate_delta_us = 3;
6071 case 3:
6072 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
6073 _Internal::set_has_begin_main_frame_start_to_ready_to_commit_estimate_delta_us(&has_bits);
6074 _impl_.begin_main_frame_start_to_ready_to_commit_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6075 CHK_(ptr);
6076 } else {
6077 goto handle_unusual;
6078 }
6079 continue;
6080 // optional int64 commit_to_ready_to_activate_estimate_delta_us = 4;
6081 case 4:
6082 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
6083 _Internal::set_has_commit_to_ready_to_activate_estimate_delta_us(&has_bits);
6084 _impl_.commit_to_ready_to_activate_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6085 CHK_(ptr);
6086 } else {
6087 goto handle_unusual;
6088 }
6089 continue;
6090 // optional int64 prepare_tiles_estimate_delta_us = 5;
6091 case 5:
6092 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
6093 _Internal::set_has_prepare_tiles_estimate_delta_us(&has_bits);
6094 _impl_.prepare_tiles_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6095 CHK_(ptr);
6096 } else {
6097 goto handle_unusual;
6098 }
6099 continue;
6100 // optional int64 activate_estimate_delta_us = 6;
6101 case 6:
6102 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
6103 _Internal::set_has_activate_estimate_delta_us(&has_bits);
6104 _impl_.activate_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6105 CHK_(ptr);
6106 } else {
6107 goto handle_unusual;
6108 }
6109 continue;
6110 // optional int64 draw_estimate_delta_us = 7;
6111 case 7:
6112 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
6113 _Internal::set_has_draw_estimate_delta_us(&has_bits);
6114 _impl_.draw_estimate_delta_us_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6115 CHK_(ptr);
6116 } else {
6117 goto handle_unusual;
6118 }
6119 continue;
6120 default:
6121 goto handle_unusual;
6122 } // switch
6123 handle_unusual:
6124 if ((tag == 0) || ((tag & 7) == 4)) {
6125 CHK_(ptr);
6126 ctx->SetLastTag(tag);
6127 goto message_done;
6128 }
6129 ptr = UnknownFieldParse(
6130 tag,
6131 _internal_metadata_.mutable_unknown_fields<std::string>(),
6132 ptr, ctx);
6133 CHK_(ptr != nullptr);
6134 } // while
6135 message_done:
6136 _impl_._has_bits_.Or(has_bits);
6137 return ptr;
6138 failure:
6139 ptr = nullptr;
6140 goto message_done;
6141 #undef CHK_
6142 }
6143
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const6144 ::uint8_t* CompositorTimingHistory::_InternalSerialize(
6145 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
6146 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.CompositorTimingHistory)
6147 ::uint32_t cached_has_bits = 0;
6148 (void) cached_has_bits;
6149
6150 cached_has_bits = _impl_._has_bits_[0];
6151 // optional int64 begin_main_frame_queue_critical_estimate_delta_us = 1;
6152 if (cached_has_bits & 0x00000001u) {
6153 target = stream->EnsureSpace(target);
6154 target = ::_pbi::WireFormatLite::WriteInt64ToArray(1, this->_internal_begin_main_frame_queue_critical_estimate_delta_us(), target);
6155 }
6156
6157 // optional int64 begin_main_frame_queue_not_critical_estimate_delta_us = 2;
6158 if (cached_has_bits & 0x00000002u) {
6159 target = stream->EnsureSpace(target);
6160 target = ::_pbi::WireFormatLite::WriteInt64ToArray(2, this->_internal_begin_main_frame_queue_not_critical_estimate_delta_us(), target);
6161 }
6162
6163 // optional int64 begin_main_frame_start_to_ready_to_commit_estimate_delta_us = 3;
6164 if (cached_has_bits & 0x00000004u) {
6165 target = stream->EnsureSpace(target);
6166 target = ::_pbi::WireFormatLite::WriteInt64ToArray(3, this->_internal_begin_main_frame_start_to_ready_to_commit_estimate_delta_us(), target);
6167 }
6168
6169 // optional int64 commit_to_ready_to_activate_estimate_delta_us = 4;
6170 if (cached_has_bits & 0x00000008u) {
6171 target = stream->EnsureSpace(target);
6172 target = ::_pbi::WireFormatLite::WriteInt64ToArray(4, this->_internal_commit_to_ready_to_activate_estimate_delta_us(), target);
6173 }
6174
6175 // optional int64 prepare_tiles_estimate_delta_us = 5;
6176 if (cached_has_bits & 0x00000010u) {
6177 target = stream->EnsureSpace(target);
6178 target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_prepare_tiles_estimate_delta_us(), target);
6179 }
6180
6181 // optional int64 activate_estimate_delta_us = 6;
6182 if (cached_has_bits & 0x00000020u) {
6183 target = stream->EnsureSpace(target);
6184 target = ::_pbi::WireFormatLite::WriteInt64ToArray(6, this->_internal_activate_estimate_delta_us(), target);
6185 }
6186
6187 // optional int64 draw_estimate_delta_us = 7;
6188 if (cached_has_bits & 0x00000040u) {
6189 target = stream->EnsureSpace(target);
6190 target = ::_pbi::WireFormatLite::WriteInt64ToArray(7, this->_internal_draw_estimate_delta_us(), target);
6191 }
6192
6193 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
6194 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
6195 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
6196 }
6197 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.CompositorTimingHistory)
6198 return target;
6199 }
6200
ByteSizeLong() const6201 size_t CompositorTimingHistory::ByteSizeLong() const {
6202 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.CompositorTimingHistory)
6203 size_t total_size = 0;
6204
6205 ::uint32_t cached_has_bits = 0;
6206 // Prevent compiler warnings about cached_has_bits being unused
6207 (void) cached_has_bits;
6208
6209 cached_has_bits = _impl_._has_bits_[0];
6210 if (cached_has_bits & 0x0000007fu) {
6211 // optional int64 begin_main_frame_queue_critical_estimate_delta_us = 1;
6212 if (cached_has_bits & 0x00000001u) {
6213 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_begin_main_frame_queue_critical_estimate_delta_us());
6214 }
6215
6216 // optional int64 begin_main_frame_queue_not_critical_estimate_delta_us = 2;
6217 if (cached_has_bits & 0x00000002u) {
6218 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_begin_main_frame_queue_not_critical_estimate_delta_us());
6219 }
6220
6221 // optional int64 begin_main_frame_start_to_ready_to_commit_estimate_delta_us = 3;
6222 if (cached_has_bits & 0x00000004u) {
6223 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_begin_main_frame_start_to_ready_to_commit_estimate_delta_us());
6224 }
6225
6226 // optional int64 commit_to_ready_to_activate_estimate_delta_us = 4;
6227 if (cached_has_bits & 0x00000008u) {
6228 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_commit_to_ready_to_activate_estimate_delta_us());
6229 }
6230
6231 // optional int64 prepare_tiles_estimate_delta_us = 5;
6232 if (cached_has_bits & 0x00000010u) {
6233 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_prepare_tiles_estimate_delta_us());
6234 }
6235
6236 // optional int64 activate_estimate_delta_us = 6;
6237 if (cached_has_bits & 0x00000020u) {
6238 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_activate_estimate_delta_us());
6239 }
6240
6241 // optional int64 draw_estimate_delta_us = 7;
6242 if (cached_has_bits & 0x00000040u) {
6243 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_draw_estimate_delta_us());
6244 }
6245
6246 }
6247 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
6248 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
6249 }
6250 int cached_size = ::_pbi::ToCachedSize(total_size);
6251 SetCachedSize(cached_size);
6252 return total_size;
6253 }
6254
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)6255 void CompositorTimingHistory::CheckTypeAndMergeFrom(
6256 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
6257 MergeFrom(*::_pbi::DownCast<const CompositorTimingHistory*>(
6258 &from));
6259 }
6260
MergeFrom(const CompositorTimingHistory & from)6261 void CompositorTimingHistory::MergeFrom(const CompositorTimingHistory& from) {
6262 CompositorTimingHistory* const _this = this;
6263 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.CompositorTimingHistory)
6264 GOOGLE_DCHECK_NE(&from, _this);
6265 ::uint32_t cached_has_bits = 0;
6266 (void) cached_has_bits;
6267
6268 cached_has_bits = from._impl_._has_bits_[0];
6269 if (cached_has_bits & 0x0000007fu) {
6270 if (cached_has_bits & 0x00000001u) {
6271 _this->_impl_.begin_main_frame_queue_critical_estimate_delta_us_ = from._impl_.begin_main_frame_queue_critical_estimate_delta_us_;
6272 }
6273 if (cached_has_bits & 0x00000002u) {
6274 _this->_impl_.begin_main_frame_queue_not_critical_estimate_delta_us_ = from._impl_.begin_main_frame_queue_not_critical_estimate_delta_us_;
6275 }
6276 if (cached_has_bits & 0x00000004u) {
6277 _this->_impl_.begin_main_frame_start_to_ready_to_commit_estimate_delta_us_ = from._impl_.begin_main_frame_start_to_ready_to_commit_estimate_delta_us_;
6278 }
6279 if (cached_has_bits & 0x00000008u) {
6280 _this->_impl_.commit_to_ready_to_activate_estimate_delta_us_ = from._impl_.commit_to_ready_to_activate_estimate_delta_us_;
6281 }
6282 if (cached_has_bits & 0x00000010u) {
6283 _this->_impl_.prepare_tiles_estimate_delta_us_ = from._impl_.prepare_tiles_estimate_delta_us_;
6284 }
6285 if (cached_has_bits & 0x00000020u) {
6286 _this->_impl_.activate_estimate_delta_us_ = from._impl_.activate_estimate_delta_us_;
6287 }
6288 if (cached_has_bits & 0x00000040u) {
6289 _this->_impl_.draw_estimate_delta_us_ = from._impl_.draw_estimate_delta_us_;
6290 }
6291 _this->_impl_._has_bits_[0] |= cached_has_bits;
6292 }
6293 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
6294 }
6295
CopyFrom(const CompositorTimingHistory & from)6296 void CompositorTimingHistory::CopyFrom(const CompositorTimingHistory& from) {
6297 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.CompositorTimingHistory)
6298 if (&from == this) return;
6299 Clear();
6300 MergeFrom(from);
6301 }
6302
IsInitialized() const6303 bool CompositorTimingHistory::IsInitialized() const {
6304 return true;
6305 }
6306
InternalSwap(CompositorTimingHistory * other)6307 void CompositorTimingHistory::InternalSwap(CompositorTimingHistory* other) {
6308 using std::swap;
6309 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
6310 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
6311 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
6312 PROTOBUF_FIELD_OFFSET(CompositorTimingHistory, _impl_.draw_estimate_delta_us_)
6313 + sizeof(CompositorTimingHistory::_impl_.draw_estimate_delta_us_) // NOLINT
6314 - PROTOBUF_FIELD_OFFSET(CompositorTimingHistory, _impl_.begin_main_frame_queue_critical_estimate_delta_us_)>(
6315 reinterpret_cast<char*>(&_impl_.begin_main_frame_queue_critical_estimate_delta_us_),
6316 reinterpret_cast<char*>(&other->_impl_.begin_main_frame_queue_critical_estimate_delta_us_));
6317 }
6318
GetTypeName() const6319 std::string CompositorTimingHistory::GetTypeName() const {
6320 return "perfetto.protos.CompositorTimingHistory";
6321 }
6322
6323
6324 // @@protoc_insertion_point(namespace_scope)
6325 } // namespace protos
6326 } // namespace perfetto
6327 PROTOBUF_NAMESPACE_OPEN
6328 template<> PROTOBUF_NOINLINE ::perfetto::protos::ChromeCompositorSchedulerState*
CreateMaybeMessage(Arena * arena)6329 Arena::CreateMaybeMessage< ::perfetto::protos::ChromeCompositorSchedulerState >(Arena* arena) {
6330 return Arena::CreateMessageInternal< ::perfetto::protos::ChromeCompositorSchedulerState >(arena);
6331 }
6332 template<> PROTOBUF_NOINLINE ::perfetto::protos::ChromeCompositorStateMachine_MajorState*
CreateMaybeMessage(Arena * arena)6333 Arena::CreateMaybeMessage< ::perfetto::protos::ChromeCompositorStateMachine_MajorState >(Arena* arena) {
6334 return Arena::CreateMessageInternal< ::perfetto::protos::ChromeCompositorStateMachine_MajorState >(arena);
6335 }
6336 template<> PROTOBUF_NOINLINE ::perfetto::protos::ChromeCompositorStateMachine_MinorState*
CreateMaybeMessage(Arena * arena)6337 Arena::CreateMaybeMessage< ::perfetto::protos::ChromeCompositorStateMachine_MinorState >(Arena* arena) {
6338 return Arena::CreateMessageInternal< ::perfetto::protos::ChromeCompositorStateMachine_MinorState >(arena);
6339 }
6340 template<> PROTOBUF_NOINLINE ::perfetto::protos::ChromeCompositorStateMachine*
CreateMaybeMessage(Arena * arena)6341 Arena::CreateMaybeMessage< ::perfetto::protos::ChromeCompositorStateMachine >(Arena* arena) {
6342 return Arena::CreateMessageInternal< ::perfetto::protos::ChromeCompositorStateMachine >(arena);
6343 }
6344 template<> PROTOBUF_NOINLINE ::perfetto::protos::BeginFrameArgs*
CreateMaybeMessage(Arena * arena)6345 Arena::CreateMaybeMessage< ::perfetto::protos::BeginFrameArgs >(Arena* arena) {
6346 return Arena::CreateMessageInternal< ::perfetto::protos::BeginFrameArgs >(arena);
6347 }
6348 template<> PROTOBUF_NOINLINE ::perfetto::protos::BeginImplFrameArgs_TimestampsInUs*
CreateMaybeMessage(Arena * arena)6349 Arena::CreateMaybeMessage< ::perfetto::protos::BeginImplFrameArgs_TimestampsInUs >(Arena* arena) {
6350 return Arena::CreateMessageInternal< ::perfetto::protos::BeginImplFrameArgs_TimestampsInUs >(arena);
6351 }
6352 template<> PROTOBUF_NOINLINE ::perfetto::protos::BeginImplFrameArgs*
CreateMaybeMessage(Arena * arena)6353 Arena::CreateMaybeMessage< ::perfetto::protos::BeginImplFrameArgs >(Arena* arena) {
6354 return Arena::CreateMessageInternal< ::perfetto::protos::BeginImplFrameArgs >(arena);
6355 }
6356 template<> PROTOBUF_NOINLINE ::perfetto::protos::BeginFrameObserverState*
CreateMaybeMessage(Arena * arena)6357 Arena::CreateMaybeMessage< ::perfetto::protos::BeginFrameObserverState >(Arena* arena) {
6358 return Arena::CreateMessageInternal< ::perfetto::protos::BeginFrameObserverState >(arena);
6359 }
6360 template<> PROTOBUF_NOINLINE ::perfetto::protos::BeginFrameSourceState*
CreateMaybeMessage(Arena * arena)6361 Arena::CreateMaybeMessage< ::perfetto::protos::BeginFrameSourceState >(Arena* arena) {
6362 return Arena::CreateMessageInternal< ::perfetto::protos::BeginFrameSourceState >(arena);
6363 }
6364 template<> PROTOBUF_NOINLINE ::perfetto::protos::CompositorTimingHistory*
CreateMaybeMessage(Arena * arena)6365 Arena::CreateMaybeMessage< ::perfetto::protos::CompositorTimingHistory >(Arena* arena) {
6366 return Arena::CreateMessageInternal< ::perfetto::protos::CompositorTimingHistory >(arena);
6367 }
6368 PROTOBUF_NAMESPACE_CLOSE
6369
6370 // @@protoc_insertion_point(global_scope)
6371 #include <google/protobuf/port_undef.inc>
6372