MCPcopy Create free account
hub / github.com/acking-you/static_flow / collect_stack_rows

Method collect_stack_rows

crates/backend/src/memory_profiler.rs:558–570  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

556 }
557
558 fn collect_stack_rows(&self) -> (u64, Vec<(StackKey, StackStats)>) {
559 let mut total_live_bytes = 0_u64;
560 let mut rows = Vec::with_capacity(self.stacks.len());
561 for entry in &self.stacks {
562 let stats = *entry.value();
563 if stats.live_bytes == 0 && stats.alloc_bytes_total == 0 {
564 continue;
565 }
566 total_live_bytes = total_live_bytes.saturating_add(stats.live_bytes);
567 rows.push((*entry.key(), stats));
568 }
569 (total_live_bytes, rows)
570 }
571
572 fn total_bytes(&self) -> (u64, u64) {
573 let mut live = 0_u64;

Callers 3

stacks_reportMethod · 0.80
functions_reportMethod · 0.80
modules_reportMethod · 0.80

Calls 2

lenMethod · 0.80
pushMethod · 0.80

Tested by

no test coverage detected