aboutsummaryrefslogtreecommitdiff
path: root/crates
diff options
context:
space:
mode:
authorAleksey Kladov <[email protected]>2020-01-29 15:10:46 +0000
committerAleksey Kladov <[email protected]>2020-01-29 15:10:46 +0000
commitf1720d7983b15a404dd3025c90afde9cc3773222 (patch)
treeb5dbc25ebef05ee32a3beb47259c4a56a6eaba72 /crates
parente3c81b67ffb97f5ac34af54d7c42033f7830bf2f (diff)
Re-sync queries for memory usage measurnment
Diffstat (limited to 'crates')
-rw-r--r--crates/ra_hir/src/db.rs22
-rw-r--r--crates/ra_ide/src/change.rs51
2 files changed, 53 insertions, 20 deletions
diff --git a/crates/ra_hir/src/db.rs b/crates/ra_hir/src/db.rs
index e6079b88d..a77bf6de6 100644
--- a/crates/ra_hir/src/db.rs
+++ b/crates/ra_hir/src/db.rs
@@ -1,20 +1,24 @@
1//! FIXME: write short doc here 1//! FIXME: write short doc here
2 2
3pub use hir_def::db::{ 3pub use hir_def::db::{
4 BodyQuery, BodyWithSourceMapQuery, ComputeCrateDefMapQuery, ConstDataQuery, 4 AttrsQuery, BodyQuery, BodyWithSourceMapQuery, ComputeCrateDefMapQuery, ConstDataQuery,
5 CrateLangItemsQuery, DefDatabase, DefDatabaseStorage, DocumentationQuery, EnumDataQuery, 5 CrateLangItemsQuery, DefDatabase, DefDatabaseStorage, DocumentationQuery, EnumDataQuery,
6 ExprScopesQuery, FunctionDataQuery, GenericParamsQuery, ImplDataQuery, InternDatabase, 6 ExprScopesQuery, FunctionDataQuery, GenericParamsQuery, ImplDataQuery, InternConstQuery,
7 InternDatabaseStorage, LangItemQuery, ModuleLangItemsQuery, RawItemsQuery, StaticDataQuery, 7 InternDatabase, InternDatabaseStorage, InternEnumQuery, InternFunctionQuery, InternImplQuery,
8 StructDataQuery, TraitDataQuery, TypeAliasDataQuery, 8 InternStaticQuery, InternStructQuery, InternTraitQuery, InternTypeAliasQuery, InternUnionQuery,
9 LangItemQuery, ModuleLangItemsQuery, RawItemsQuery, StaticDataQuery, StructDataQuery,
10 TraitDataQuery, TypeAliasDataQuery, UnionDataQuery,
9}; 11};
10pub use hir_expand::db::{ 12pub use hir_expand::db::{
11 AstDatabase, AstDatabaseStorage, AstIdMapQuery, MacroArgQuery, MacroDefQuery, MacroExpandQuery, 13 AstDatabase, AstDatabaseStorage, AstIdMapQuery, InternMacroQuery, MacroArgQuery, MacroDefQuery,
12 ParseMacroQuery, 14 MacroExpandQuery, ParseMacroQuery,
13}; 15};
14pub use hir_ty::db::{ 16pub use hir_ty::db::{
15 AssociatedTyDataQuery, CallableItemSignatureQuery, DoInferQuery, FieldTypesQuery, 17 AssociatedTyDataQuery, AssociatedTyValueQuery, CallableItemSignatureQuery, DoInferQuery,
16 GenericDefaultsQuery, GenericPredicatesQuery, HirDatabase, HirDatabaseStorage, ImplDatumQuery, 18 FieldTypesQuery, GenericDefaultsQuery, GenericPredicatesForParamQuery, GenericPredicatesQuery,
17 ImplsForTraitQuery, ImplsInCrateQuery, StructDatumQuery, TraitDatumQuery, TraitSolveQuery, 19 HirDatabase, HirDatabaseStorage, ImplDatumQuery, ImplSelfTyQuery, ImplTraitQuery,
20 ImplsForTraitQuery, ImplsInCrateQuery, InternAssocTyValueQuery, InternChalkImplQuery,
21 InternTypeCtorQuery, StructDatumQuery, TraitDatumQuery, TraitSolveQuery, TraitSolverQuery,
18 TyQuery, ValueTyQuery, 22 TyQuery, ValueTyQuery,
19}; 23};
20 24
diff --git a/crates/ra_ide/src/change.rs b/crates/ra_ide/src/change.rs
index ce617840c..45a58690b 100644
--- a/crates/ra_ide/src/change.rs
+++ b/crates/ra_ide/src/change.rs
@@ -301,45 +301,74 @@ impl RootDatabase {
301 )*} 301 )*}
302 } 302 }
303 sweep_each_query![ 303 sweep_each_query![
304 // SourceDatabase
304 ra_db::ParseQuery 305 ra_db::ParseQuery
305 ra_db::SourceRootCratesQuery 306 ra_db::SourceRootCratesQuery
307
308 // AstDatabase
306 hir::db::AstIdMapQuery 309 hir::db::AstIdMapQuery
307 hir::db::ParseMacroQuery 310 hir::db::InternMacroQuery
308 hir::db::MacroDefQuery
309 hir::db::MacroArgQuery 311 hir::db::MacroArgQuery
312 hir::db::MacroDefQuery
313 hir::db::ParseMacroQuery
310 hir::db::MacroExpandQuery 314 hir::db::MacroExpandQuery
315
316 // DefDatabase
317 hir::db::RawItemsQuery
318 hir::db::ComputeCrateDefMapQuery
311 hir::db::StructDataQuery 319 hir::db::StructDataQuery
320 hir::db::UnionDataQuery
312 hir::db::EnumDataQuery 321 hir::db::EnumDataQuery
322 hir::db::ImplDataQuery
313 hir::db::TraitDataQuery 323 hir::db::TraitDataQuery
314 hir::db::RawItemsQuery
315 hir::db::ComputeCrateDefMapQuery
316 hir::db::GenericParamsQuery
317 hir::db::FunctionDataQuery
318 hir::db::TypeAliasDataQuery 324 hir::db::TypeAliasDataQuery
325 hir::db::FunctionDataQuery
319 hir::db::ConstDataQuery 326 hir::db::ConstDataQuery
320 hir::db::StaticDataQuery 327 hir::db::StaticDataQuery
328 hir::db::BodyWithSourceMapQuery
329 hir::db::BodyQuery
330 hir::db::ExprScopesQuery
331 hir::db::GenericParamsQuery
332 hir::db::AttrsQuery
321 hir::db::ModuleLangItemsQuery 333 hir::db::ModuleLangItemsQuery
322 hir::db::CrateLangItemsQuery 334 hir::db::CrateLangItemsQuery
323 hir::db::LangItemQuery 335 hir::db::LangItemQuery
324 hir::db::DocumentationQuery 336 hir::db::DocumentationQuery
325 hir::db::ExprScopesQuery 337
338 // InternDatabase
339 hir::db::InternFunctionQuery
340 hir::db::InternStructQuery
341 hir::db::InternUnionQuery
342 hir::db::InternEnumQuery
343 hir::db::InternConstQuery
344 hir::db::InternStaticQuery
345 hir::db::InternTraitQuery
346 hir::db::InternTypeAliasQuery
347 hir::db::InternImplQuery
348
349 // HirDatabase
326 hir::db::DoInferQuery 350 hir::db::DoInferQuery
327 hir::db::TyQuery 351 hir::db::TyQuery
328 hir::db::ValueTyQuery 352 hir::db::ValueTyQuery
353 hir::db::ImplSelfTyQuery
354 hir::db::ImplTraitQuery
329 hir::db::FieldTypesQuery 355 hir::db::FieldTypesQuery
330 hir::db::CallableItemSignatureQuery 356 hir::db::CallableItemSignatureQuery
357 hir::db::GenericPredicatesForParamQuery
331 hir::db::GenericPredicatesQuery 358 hir::db::GenericPredicatesQuery
332 hir::db::GenericDefaultsQuery 359 hir::db::GenericDefaultsQuery
333 hir::db::BodyWithSourceMapQuery
334 hir::db::BodyQuery
335 hir::db::ImplsInCrateQuery 360 hir::db::ImplsInCrateQuery
336 hir::db::ImplsForTraitQuery 361 hir::db::ImplsForTraitQuery
362 hir::db::TraitSolverQuery
363 hir::db::InternTypeCtorQuery
364 hir::db::InternChalkImplQuery
365 hir::db::InternAssocTyValueQuery
337 hir::db::AssociatedTyDataQuery 366 hir::db::AssociatedTyDataQuery
367 hir::db::AssociatedTyValueQuery
368 hir::db::TraitSolveQuery
338 hir::db::TraitDatumQuery 369 hir::db::TraitDatumQuery
339 hir::db::StructDatumQuery 370 hir::db::StructDatumQuery
340 hir::db::ImplDatumQuery 371 hir::db::ImplDatumQuery
341 hir::db::ImplDataQuery
342 hir::db::TraitSolveQuery
343 ]; 372 ];
344 acc.sort_by_key(|it| std::cmp::Reverse(it.1)); 373 acc.sort_by_key(|it| std::cmp::Reverse(it.1));
345 acc 374 acc