From d4b135f38c8c0050768c50e62043ddca5f09079a Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Sat, 21 Dec 2019 18:45:46 +0100 Subject: Optimize and profile --- crates/ra_hir_def/src/body.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'crates/ra_hir_def') diff --git a/crates/ra_hir_def/src/body.rs b/crates/ra_hir_def/src/body.rs index 445d215b7..148ff007e 100644 --- a/crates/ra_hir_def/src/body.rs +++ b/crates/ra_hir_def/src/body.rs @@ -11,6 +11,7 @@ use hir_expand::{ ast_id_map::AstIdMap, hygiene::Hygiene, AstId, HirFileId, InFile, MacroCallKind, MacroDefId, }; use ra_arena::{map::ArenaMap, Arena}; +use ra_prof::profile; use ra_syntax::{ast, AstNode, AstPtr}; use rustc_hash::FxHashMap; @@ -168,6 +169,7 @@ impl Body { db: &impl DefDatabase, def: DefWithBodyId, ) -> (Arc, Arc) { + let _p = profile("body_with_source_map_query"); let mut params = None; let (file_id, module, body) = match def { -- cgit v1.2.3