##// END OF EJS Templates
dirstate-tree: Add #[timed] attribute to `status` and `DirstateMap::read`...
Simon Sapin -
r47888:c92e6376 default
parent child Browse files
Show More
@@ -1,4 +1,5 b''
1 use bytes_cast::BytesCast;
1 use bytes_cast::BytesCast;
2 use micro_timer::timed;
2 use std::path::PathBuf;
3 use std::path::PathBuf;
3 use std::{collections::BTreeMap, convert::TryInto};
4 use std::{collections::BTreeMap, convert::TryInto};
4
5
@@ -499,6 +500,7 b' impl super::dispatch::DirstateMapMethods'
499 self.dirty_parents = true;
500 self.dirty_parents = true;
500 }
501 }
501
502
503 #[timed]
502 fn read<'a>(
504 fn read<'a>(
503 &mut self,
505 &mut self,
504 file_contents: &'a [u8],
506 file_contents: &'a [u8],
@@ -13,6 +13,7 b' use crate::HgPathBuf;'
13 use crate::PatternFileWarning;
13 use crate::PatternFileWarning;
14 use crate::StatusError;
14 use crate::StatusError;
15 use crate::StatusOptions;
15 use crate::StatusOptions;
16 use micro_timer::timed;
16 use rayon::prelude::*;
17 use rayon::prelude::*;
17 use std::borrow::Cow;
18 use std::borrow::Cow;
18 use std::io;
19 use std::io;
@@ -29,6 +30,7 b' use std::sync::Mutex;'
29 /// and its use of `itertools::merge_join_by`. When reaching a path that only
30 /// and its use of `itertools::merge_join_by`. When reaching a path that only
30 /// exists in one of the two trees, depending on information requested by
31 /// exists in one of the two trees, depending on information requested by
31 /// `options` we may need to traverse the remaining subtree.
32 /// `options` we may need to traverse the remaining subtree.
33 #[timed]
32 pub fn status<'tree>(
34 pub fn status<'tree>(
33 dmap: &'tree mut DirstateMap,
35 dmap: &'tree mut DirstateMap,
34 matcher: &(dyn Matcher + Sync),
36 matcher: &(dyn Matcher + Sync),
General Comments 0
You need to be logged in to leave comments. Login now