]> git.lizzy.rs Git - rust.git/blob - src/librustc_data_structures/profiling.rs
Rollup merge of #68767 - kubo39:patch-macos, r=shepmaster
[rust.git] / src / librustc_data_structures / profiling.rs
1 //! # Rust Compiler Self-Profiling
2 //!
3 //! This module implements the basic framework for the compiler's self-
4 //! profiling support. It provides the `SelfProfiler` type which enables
5 //! recording "events". An event is something that starts and ends at a given
6 //! point in time and has an ID and a kind attached to it. This allows for
7 //! tracing the compiler's activity.
8 //!
9 //! Internally this module uses the custom tailored [measureme][mm] crate for
10 //! efficiently recording events to disk in a compact format that can be
11 //! post-processed and analyzed by the suite of tools in the `measureme`
12 //! project. The highest priority for the tracing framework is on incurring as
13 //! little overhead as possible.
14 //!
15 //!
16 //! ## Event Overview
17 //!
18 //! Events have a few properties:
19 //!
20 //! - The `event_kind` designates the broad category of an event (e.g. does it
21 //!   correspond to the execution of a query provider or to loading something
22 //!   from the incr. comp. on-disk cache, etc).
23 //! - The `event_id` designates the query invocation or function call it
24 //!   corresponds to, possibly including the query key or function arguments.
25 //! - Each event stores the ID of the thread it was recorded on.
26 //! - The timestamp stores beginning and end of the event, or the single point
27 //!   in time it occurred at for "instant" events.
28 //!
29 //!
30 //! ## Event Filtering
31 //!
32 //! Event generation can be filtered by event kind. Recording all possible
33 //! events generates a lot of data, much of which is not needed for most kinds
34 //! of analysis. So, in order to keep overhead as low as possible for a given
35 //! use case, the `SelfProfiler` will only record the kinds of events that
36 //! pass the filter specified as a command line argument to the compiler.
37 //!
38 //!
39 //! ## `event_id` Assignment
40 //!
41 //! As far as `measureme` is concerned, `event_id`s are just strings. However,
42 //! it would incur too much overhead to generate and persist each `event_id`
43 //! string at the point where the event is recorded. In order to make this more
44 //! efficient `measureme` has two features:
45 //!
46 //! - Strings can share their content, so that re-occurring parts don't have to
47 //!   be copied over and over again. One allocates a string in `measureme` and
48 //!   gets back a `StringId`. This `StringId` is then used to refer to that
49 //!   string. `measureme` strings are actually DAGs of string components so that
50 //!   arbitrary sharing of substrings can be done efficiently. This is useful
51 //!   because `event_id`s contain lots of redundant text like query names or
52 //!   def-path components.
53 //!
54 //! - `StringId`s can be "virtual" which means that the client picks a numeric
55 //!   ID according to some application-specific scheme and can later make that
56 //!   ID be mapped to an actual string. This is used to cheaply generate
57 //!   `event_id`s while the events actually occur, causing little timing
58 //!   distortion, and then later map those `StringId`s, in bulk, to actual
59 //!   `event_id` strings. This way the largest part of the tracing overhead is
60 //!   localized to one contiguous chunk of time.
61 //!
62 //! How are these `event_id`s generated in the compiler? For things that occur
63 //! infrequently (e.g. "generic activities"), we just allocate the string the
64 //! first time it is used and then keep the `StringId` in a hash table. This
65 //! is implemented in `SelfProfiler::get_or_alloc_cached_string()`.
66 //!
67 //! For queries it gets more interesting: First we need a unique numeric ID for
68 //! each query invocation (the `QueryInvocationId`). This ID is used as the
69 //! virtual `StringId` we use as `event_id` for a given event. This ID has to
70 //! be available both when the query is executed and later, together with the
71 //! query key, when we allocate the actual `event_id` strings in bulk.
72 //!
73 //! We could make the compiler generate and keep track of such an ID for each
74 //! query invocation but luckily we already have something that fits all the
75 //! the requirements: the query's `DepNodeIndex`. So we use the numeric value
76 //! of the `DepNodeIndex` as `event_id` when recording the event and then,
77 //! just before the query context is dropped, we walk the entire query cache
78 //! (which stores the `DepNodeIndex` along with the query key for each
79 //! invocation) and allocate the corresponding strings together with a mapping
80 //! for `DepNodeIndex as StringId`.
81 //!
82 //! [mm]: https://github.com/rust-lang/measureme/
83
84 use crate::fx::FxHashMap;
85
86 use std::borrow::Borrow;
87 use std::collections::hash_map::Entry;
88 use std::convert::Into;
89 use std::error::Error;
90 use std::fs;
91 use std::path::Path;
92 use std::process;
93 use std::sync::Arc;
94 use std::time::{Duration, Instant};
95 use std::u32;
96
97 use measureme::{EventId, EventIdBuilder, SerializableString, StringId};
98 use parking_lot::RwLock;
99
100 /// MmapSerializatioSink is faster on macOS and Linux
101 /// but FileSerializationSink is faster on Windows
102 #[cfg(not(windows))]
103 type SerializationSink = measureme::MmapSerializationSink;
104 #[cfg(windows)]
105 type SerializationSink = measureme::FileSerializationSink;
106
107 type Profiler = measureme::Profiler<SerializationSink>;
108
109 #[derive(Clone, Copy, Debug, PartialEq, Eq, Ord, PartialOrd)]
110 pub enum ProfileCategory {
111     Parsing,
112     Expansion,
113     TypeChecking,
114     BorrowChecking,
115     Codegen,
116     Linking,
117     Other,
118 }
119
120 bitflags::bitflags! {
121     struct EventFilter: u32 {
122         const GENERIC_ACTIVITIES = 1 << 0;
123         const QUERY_PROVIDERS    = 1 << 1;
124         const QUERY_CACHE_HITS   = 1 << 2;
125         const QUERY_BLOCKED      = 1 << 3;
126         const INCR_CACHE_LOADS   = 1 << 4;
127
128         const QUERY_KEYS         = 1 << 5;
129         const FUNCTION_ARGS      = 1 << 6;
130         const LLVM               = 1 << 7;
131
132         const DEFAULT = Self::GENERIC_ACTIVITIES.bits |
133                         Self::QUERY_PROVIDERS.bits |
134                         Self::QUERY_BLOCKED.bits |
135                         Self::INCR_CACHE_LOADS.bits;
136
137         const ARGS = Self::QUERY_KEYS.bits | Self::FUNCTION_ARGS.bits;
138     }
139 }
140
141 // keep this in sync with the `-Z self-profile-events` help message in librustc_session/options.rs
142 const EVENT_FILTERS_BY_NAME: &[(&str, EventFilter)] = &[
143     ("none", EventFilter::empty()),
144     ("all", EventFilter::all()),
145     ("default", EventFilter::DEFAULT),
146     ("generic-activity", EventFilter::GENERIC_ACTIVITIES),
147     ("query-provider", EventFilter::QUERY_PROVIDERS),
148     ("query-cache-hit", EventFilter::QUERY_CACHE_HITS),
149     ("query-blocked", EventFilter::QUERY_BLOCKED),
150     ("incr-cache-load", EventFilter::INCR_CACHE_LOADS),
151     ("query-keys", EventFilter::QUERY_KEYS),
152     ("function-args", EventFilter::FUNCTION_ARGS),
153     ("args", EventFilter::ARGS),
154     ("llvm", EventFilter::LLVM),
155 ];
156
157 /// Something that uniquely identifies a query invocation.
158 pub struct QueryInvocationId(pub u32);
159
160 /// A reference to the SelfProfiler. It can be cloned and sent across thread
161 /// boundaries at will.
162 #[derive(Clone)]
163 pub struct SelfProfilerRef {
164     // This field is `None` if self-profiling is disabled for the current
165     // compilation session.
166     profiler: Option<Arc<SelfProfiler>>,
167
168     // We store the filter mask directly in the reference because that doesn't
169     // cost anything and allows for filtering with checking if the profiler is
170     // actually enabled.
171     event_filter_mask: EventFilter,
172
173     // Print verbose generic activities to stdout
174     print_verbose_generic_activities: bool,
175
176     // Print extra verbose generic activities to stdout
177     print_extra_verbose_generic_activities: bool,
178 }
179
180 impl SelfProfilerRef {
181     pub fn new(
182         profiler: Option<Arc<SelfProfiler>>,
183         print_verbose_generic_activities: bool,
184         print_extra_verbose_generic_activities: bool,
185     ) -> SelfProfilerRef {
186         // If there is no SelfProfiler then the filter mask is set to NONE,
187         // ensuring that nothing ever tries to actually access it.
188         let event_filter_mask =
189             profiler.as_ref().map(|p| p.event_filter_mask).unwrap_or(EventFilter::empty());
190
191         SelfProfilerRef {
192             profiler,
193             event_filter_mask,
194             print_verbose_generic_activities,
195             print_extra_verbose_generic_activities,
196         }
197     }
198
199     // This shim makes sure that calls only get executed if the filter mask
200     // lets them pass. It also contains some trickery to make sure that
201     // code is optimized for non-profiling compilation sessions, i.e. anything
202     // past the filter check is never inlined so it doesn't clutter the fast
203     // path.
204     #[inline(always)]
205     fn exec<F>(&self, event_filter: EventFilter, f: F) -> TimingGuard<'_>
206     where
207         F: for<'a> FnOnce(&'a SelfProfiler) -> TimingGuard<'a>,
208     {
209         #[inline(never)]
210         fn cold_call<F>(profiler_ref: &SelfProfilerRef, f: F) -> TimingGuard<'_>
211         where
212             F: for<'a> FnOnce(&'a SelfProfiler) -> TimingGuard<'a>,
213         {
214             let profiler = profiler_ref.profiler.as_ref().unwrap();
215             f(&**profiler)
216         }
217
218         if unlikely!(self.event_filter_mask.contains(event_filter)) {
219             cold_call(self, f)
220         } else {
221             TimingGuard::none()
222         }
223     }
224
225     /// Start profiling a verbose generic activity. Profiling continues until the
226     /// VerboseTimingGuard returned from this call is dropped. In addition to recording
227     /// a measureme event, "verbose" generic activities also print a timing entry to
228     /// stdout if the compiler is invoked with -Ztime or -Ztime-passes.
229     pub fn verbose_generic_activity<'a>(
230         &'a self,
231         event_label: &'static str,
232     ) -> VerboseTimingGuard<'a> {
233         let message =
234             if self.print_verbose_generic_activities { Some(event_label.to_owned()) } else { None };
235
236         VerboseTimingGuard::start(message, self.generic_activity(event_label))
237     }
238
239     /// Start profiling a extra verbose generic activity. Profiling continues until the
240     /// VerboseTimingGuard returned from this call is dropped. In addition to recording
241     /// a measureme event, "extra verbose" generic activities also print a timing entry to
242     /// stdout if the compiler is invoked with -Ztime-passes.
243     pub fn extra_verbose_generic_activity<'a, A>(
244         &'a self,
245         event_label: &'static str,
246         event_arg: A,
247     ) -> VerboseTimingGuard<'a>
248     where
249         A: Borrow<str> + Into<String>,
250     {
251         let message = if self.print_extra_verbose_generic_activities {
252             Some(format!("{}({})", event_label, event_arg.borrow()))
253         } else {
254             None
255         };
256
257         VerboseTimingGuard::start(message, self.generic_activity_with_arg(event_label, event_arg))
258     }
259
260     /// Start profiling a generic activity. Profiling continues until the
261     /// TimingGuard returned from this call is dropped.
262     #[inline(always)]
263     pub fn generic_activity(&self, event_label: &'static str) -> TimingGuard<'_> {
264         self.exec(EventFilter::GENERIC_ACTIVITIES, |profiler| {
265             let event_label = profiler.get_or_alloc_cached_string(event_label);
266             let event_id = EventId::from_label(event_label);
267             TimingGuard::start(profiler, profiler.generic_activity_event_kind, event_id)
268         })
269     }
270
271     /// Start profiling a generic activity. Profiling continues until the
272     /// TimingGuard returned from this call is dropped.
273     #[inline(always)]
274     pub fn generic_activity_with_arg<A>(
275         &self,
276         event_label: &'static str,
277         event_arg: A,
278     ) -> TimingGuard<'_>
279     where
280         A: Borrow<str> + Into<String>,
281     {
282         self.exec(EventFilter::GENERIC_ACTIVITIES, |profiler| {
283             let builder = EventIdBuilder::new(&profiler.profiler);
284             let event_label = profiler.get_or_alloc_cached_string(event_label);
285             let event_id = if profiler.event_filter_mask.contains(EventFilter::FUNCTION_ARGS) {
286                 let event_arg = profiler.get_or_alloc_cached_string(event_arg);
287                 builder.from_label_and_arg(event_label, event_arg)
288             } else {
289                 builder.from_label(event_label)
290             };
291             TimingGuard::start(profiler, profiler.generic_activity_event_kind, event_id)
292         })
293     }
294
295     /// Start profiling a query provider. Profiling continues until the
296     /// TimingGuard returned from this call is dropped.
297     #[inline(always)]
298     pub fn query_provider(&self) -> TimingGuard<'_> {
299         self.exec(EventFilter::QUERY_PROVIDERS, |profiler| {
300             TimingGuard::start(profiler, profiler.query_event_kind, EventId::INVALID)
301         })
302     }
303
304     /// Record a query in-memory cache hit.
305     #[inline(always)]
306     pub fn query_cache_hit(&self, query_invocation_id: QueryInvocationId) {
307         self.instant_query_event(
308             |profiler| profiler.query_cache_hit_event_kind,
309             query_invocation_id,
310             EventFilter::QUERY_CACHE_HITS,
311         );
312     }
313
314     /// Start profiling a query being blocked on a concurrent execution.
315     /// Profiling continues until the TimingGuard returned from this call is
316     /// dropped.
317     #[inline(always)]
318     pub fn query_blocked(&self) -> TimingGuard<'_> {
319         self.exec(EventFilter::QUERY_BLOCKED, |profiler| {
320             TimingGuard::start(profiler, profiler.query_blocked_event_kind, EventId::INVALID)
321         })
322     }
323
324     /// Start profiling how long it takes to load a query result from the
325     /// incremental compilation on-disk cache. Profiling continues until the
326     /// TimingGuard returned from this call is dropped.
327     #[inline(always)]
328     pub fn incr_cache_loading(&self) -> TimingGuard<'_> {
329         self.exec(EventFilter::INCR_CACHE_LOADS, |profiler| {
330             TimingGuard::start(
331                 profiler,
332                 profiler.incremental_load_result_event_kind,
333                 EventId::INVALID,
334             )
335         })
336     }
337
338     #[inline(always)]
339     fn instant_query_event(
340         &self,
341         event_kind: fn(&SelfProfiler) -> StringId,
342         query_invocation_id: QueryInvocationId,
343         event_filter: EventFilter,
344     ) {
345         drop(self.exec(event_filter, |profiler| {
346             let event_id = StringId::new_virtual(query_invocation_id.0);
347             let thread_id = std::thread::current().id().as_u64() as u32;
348
349             profiler.profiler.record_instant_event(
350                 event_kind(profiler),
351                 EventId::from_virtual(event_id),
352                 thread_id,
353             );
354
355             TimingGuard::none()
356         }));
357     }
358
359     pub fn with_profiler(&self, f: impl FnOnce(&SelfProfiler)) {
360         if let Some(profiler) = &self.profiler {
361             f(&profiler)
362         }
363     }
364
365     #[inline]
366     pub fn enabled(&self) -> bool {
367         self.profiler.is_some()
368     }
369
370     #[inline]
371     pub fn llvm_recording_enabled(&self) -> bool {
372         self.event_filter_mask.contains(EventFilter::LLVM)
373     }
374     #[inline]
375     pub fn get_self_profiler(&self) -> Option<Arc<SelfProfiler>> {
376         self.profiler.clone()
377     }
378 }
379
380 pub struct SelfProfiler {
381     profiler: Profiler,
382     event_filter_mask: EventFilter,
383
384     string_cache: RwLock<FxHashMap<String, StringId>>,
385
386     query_event_kind: StringId,
387     generic_activity_event_kind: StringId,
388     incremental_load_result_event_kind: StringId,
389     query_blocked_event_kind: StringId,
390     query_cache_hit_event_kind: StringId,
391 }
392
393 impl SelfProfiler {
394     pub fn new(
395         output_directory: &Path,
396         crate_name: Option<&str>,
397         event_filters: &Option<Vec<String>>,
398     ) -> Result<SelfProfiler, Box<dyn Error>> {
399         fs::create_dir_all(output_directory)?;
400
401         let crate_name = crate_name.unwrap_or("unknown-crate");
402         let filename = format!("{}-{}.rustc_profile", crate_name, process::id());
403         let path = output_directory.join(&filename);
404         let profiler = Profiler::new(&path)?;
405
406         let query_event_kind = profiler.alloc_string("Query");
407         let generic_activity_event_kind = profiler.alloc_string("GenericActivity");
408         let incremental_load_result_event_kind = profiler.alloc_string("IncrementalLoadResult");
409         let query_blocked_event_kind = profiler.alloc_string("QueryBlocked");
410         let query_cache_hit_event_kind = profiler.alloc_string("QueryCacheHit");
411
412         let mut event_filter_mask = EventFilter::empty();
413
414         if let Some(ref event_filters) = *event_filters {
415             let mut unknown_events = vec![];
416             for item in event_filters {
417                 if let Some(&(_, mask)) =
418                     EVENT_FILTERS_BY_NAME.iter().find(|&(name, _)| name == item)
419                 {
420                     event_filter_mask |= mask;
421                 } else {
422                     unknown_events.push(item.clone());
423                 }
424             }
425
426             // Warn about any unknown event names
427             if unknown_events.len() > 0 {
428                 unknown_events.sort();
429                 unknown_events.dedup();
430
431                 warn!(
432                     "Unknown self-profiler events specified: {}. Available options are: {}.",
433                     unknown_events.join(", "),
434                     EVENT_FILTERS_BY_NAME
435                         .iter()
436                         .map(|&(name, _)| name.to_string())
437                         .collect::<Vec<_>>()
438                         .join(", ")
439                 );
440             }
441         } else {
442             event_filter_mask = EventFilter::DEFAULT;
443         }
444
445         Ok(SelfProfiler {
446             profiler,
447             event_filter_mask,
448             string_cache: RwLock::new(FxHashMap::default()),
449             query_event_kind,
450             generic_activity_event_kind,
451             incremental_load_result_event_kind,
452             query_blocked_event_kind,
453             query_cache_hit_event_kind,
454         })
455     }
456
457     /// Allocates a new string in the profiling data. Does not do any caching
458     /// or deduplication.
459     pub fn alloc_string<STR: SerializableString + ?Sized>(&self, s: &STR) -> StringId {
460         self.profiler.alloc_string(s)
461     }
462
463     /// Gets a `StringId` for the given string. This method makes sure that
464     /// any strings going through it will only be allocated once in the
465     /// profiling data.
466     pub fn get_or_alloc_cached_string<A>(&self, s: A) -> StringId
467     where
468         A: Borrow<str> + Into<String>,
469     {
470         // Only acquire a read-lock first since we assume that the string is
471         // already present in the common case.
472         {
473             let string_cache = self.string_cache.read();
474
475             if let Some(&id) = string_cache.get(s.borrow()) {
476                 return id;
477             }
478         }
479
480         let mut string_cache = self.string_cache.write();
481         // Check if the string has already been added in the small time window
482         // between dropping the read lock and acquiring the write lock.
483         match string_cache.entry(s.into()) {
484             Entry::Occupied(e) => *e.get(),
485             Entry::Vacant(e) => {
486                 let string_id = self.profiler.alloc_string(&e.key()[..]);
487                 *e.insert(string_id)
488             }
489         }
490     }
491
492     pub fn map_query_invocation_id_to_string(&self, from: QueryInvocationId, to: StringId) {
493         let from = StringId::new_virtual(from.0);
494         self.profiler.map_virtual_to_concrete_string(from, to);
495     }
496
497     pub fn bulk_map_query_invocation_id_to_single_string<I>(&self, from: I, to: StringId)
498     where
499         I: Iterator<Item = QueryInvocationId> + ExactSizeIterator,
500     {
501         let from = from.map(|qid| StringId::new_virtual(qid.0));
502         self.profiler.bulk_map_virtual_to_single_concrete_string(from, to);
503     }
504
505     pub fn query_key_recording_enabled(&self) -> bool {
506         self.event_filter_mask.contains(EventFilter::QUERY_KEYS)
507     }
508
509     pub fn event_id_builder(&self) -> EventIdBuilder<'_, SerializationSink> {
510         EventIdBuilder::new(&self.profiler)
511     }
512 }
513
514 #[must_use]
515 pub struct TimingGuard<'a>(Option<measureme::TimingGuard<'a, SerializationSink>>);
516
517 impl<'a> TimingGuard<'a> {
518     #[inline]
519     pub fn start(
520         profiler: &'a SelfProfiler,
521         event_kind: StringId,
522         event_id: EventId,
523     ) -> TimingGuard<'a> {
524         let thread_id = std::thread::current().id().as_u64() as u32;
525         let raw_profiler = &profiler.profiler;
526         let timing_guard =
527             raw_profiler.start_recording_interval_event(event_kind, event_id, thread_id);
528         TimingGuard(Some(timing_guard))
529     }
530
531     #[inline]
532     pub fn finish_with_query_invocation_id(self, query_invocation_id: QueryInvocationId) {
533         if let Some(guard) = self.0 {
534             let event_id = StringId::new_virtual(query_invocation_id.0);
535             let event_id = EventId::from_virtual(event_id);
536             guard.finish_with_override_event_id(event_id);
537         }
538     }
539
540     #[inline]
541     pub fn none() -> TimingGuard<'a> {
542         TimingGuard(None)
543     }
544
545     #[inline(always)]
546     pub fn run<R>(self, f: impl FnOnce() -> R) -> R {
547         let _timer = self;
548         f()
549     }
550 }
551
552 #[must_use]
553 pub struct VerboseTimingGuard<'a> {
554     start_and_message: Option<(Instant, String)>,
555     _guard: TimingGuard<'a>,
556 }
557
558 impl<'a> VerboseTimingGuard<'a> {
559     pub fn start(message: Option<String>, _guard: TimingGuard<'a>) -> Self {
560         VerboseTimingGuard { _guard, start_and_message: message.map(|msg| (Instant::now(), msg)) }
561     }
562
563     #[inline(always)]
564     pub fn run<R>(self, f: impl FnOnce() -> R) -> R {
565         let _timer = self;
566         f()
567     }
568 }
569
570 impl Drop for VerboseTimingGuard<'_> {
571     fn drop(&mut self) {
572         if let Some((start, ref message)) = self.start_and_message {
573             print_time_passes_entry(true, &message[..], start.elapsed());
574         }
575     }
576 }
577
578 pub fn print_time_passes_entry(do_it: bool, what: &str, dur: Duration) {
579     if !do_it {
580         return;
581     }
582
583     let mem_string = match get_resident() {
584         Some(n) => {
585             let mb = n as f64 / 1_000_000.0;
586             format!("; rss: {}MB", mb.round() as usize)
587         }
588         None => String::new(),
589     };
590     println!("time: {}{}\t{}", duration_to_secs_str(dur), mem_string, what);
591 }
592
593 // Hack up our own formatting for the duration to make it easier for scripts
594 // to parse (always use the same number of decimal places and the same unit).
595 pub fn duration_to_secs_str(dur: std::time::Duration) -> String {
596     const NANOS_PER_SEC: f64 = 1_000_000_000.0;
597     let secs = dur.as_secs() as f64 + dur.subsec_nanos() as f64 / NANOS_PER_SEC;
598
599     format!("{:.3}", secs)
600 }
601
602 // Memory reporting
603 #[cfg(unix)]
604 fn get_resident() -> Option<usize> {
605     let field = 1;
606     let contents = fs::read("/proc/self/statm").ok()?;
607     let contents = String::from_utf8(contents).ok()?;
608     let s = contents.split_whitespace().nth(field)?;
609     let npages = s.parse::<usize>().ok()?;
610     Some(npages * 4096)
611 }
612
613 #[cfg(windows)]
614 fn get_resident() -> Option<usize> {
615     use std::mem::{self, MaybeUninit};
616     use winapi::shared::minwindef::DWORD;
617     use winapi::um::processthreadsapi::GetCurrentProcess;
618     use winapi::um::psapi::{GetProcessMemoryInfo, PROCESS_MEMORY_COUNTERS};
619
620     let mut pmc = MaybeUninit::<PROCESS_MEMORY_COUNTERS>::uninit();
621     match unsafe {
622         GetProcessMemoryInfo(GetCurrentProcess(), pmc.as_mut_ptr(), mem::size_of_val(&pmc) as DWORD)
623     } {
624         0 => None,
625         _ => {
626             let pmc = unsafe { pmc.assume_init() };
627             Some(pmc.WorkingSetSize as usize)
628         }
629     }
630 }