aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-04-01 22:01:39 +0100
committerGitHub <[email protected]>2021-04-01 22:01:39 +0100
commit1c936dcbe1be90e094ac436a0b62ec070bd6953d (patch)
tree2ae4a8aac20af124befaf10e30db7b7b00f90a25
parent25201b2dad7b4b0d41494e238ebf643ad7ad8cd6 (diff)
parent0a8274dd46e152ea9fae7053eba5dd4bc9329665 (diff)
Merge #8286
8286: Include remaining memory in memory usage stats r=jonas-schievink a=jonas-schievink bors r+ Co-authored-by: Jonas Schievink <[email protected]>
-rw-r--r--crates/rust-analyzer/src/handlers.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/crates/rust-analyzer/src/handlers.rs b/crates/rust-analyzer/src/handlers.rs
index 85e67554c..53d29ddfc 100644
--- a/crates/rust-analyzer/src/handlers.rs
+++ b/crates/rust-analyzer/src/handlers.rs
@@ -84,7 +84,8 @@ pub(crate) fn handle_analyzer_status(
84 84
85pub(crate) fn handle_memory_usage(state: &mut GlobalState, _: ()) -> Result<String> { 85pub(crate) fn handle_memory_usage(state: &mut GlobalState, _: ()) -> Result<String> {
86 let _p = profile::span("handle_memory_usage"); 86 let _p = profile::span("handle_memory_usage");
87 let mem = state.analysis_host.per_query_memory_usage(); 87 let mut mem = state.analysis_host.per_query_memory_usage();
88 mem.push(("Remaining".into(), profile::memory_usage().allocated));
88 89
89 let mut out = String::new(); 90 let mut out = String::new();
90 for (name, bytes) in mem { 91 for (name, bytes) in mem {