From ce36e574f4f404d7b0c8d15d3d55ea62fca8deb6 Mon Sep 17 00:00:00 2001 From: Nicholas Nethercote Date: Sun, 22 Mar 2015 15:20:31 -0700 Subject: Rename lots of profiling-related things. ------------------------------------------------------------------------ BEFORE AFTER ------------------------------------------------------------------------ util::memory util::mem - heap_size_of - heap_size_of (unchanged) - SizeOf - HeapSizeOf - size_of_excluding_self - heap_size_of_children prof::mem prof::mem - MemoryProfilerChan - ProfilerChan - MemoryReport - Report - MemoryReportsChan - ReportsChan - MemoryReporter - Reporter - MemoryProfilerMsg - ProfilerMsg - {R,UnR}egisterMemoryReporter - {R,UnR}egisterReporter - MemoryProfiler - Prof - ReportsForest - ReportsForest (unchanged) - ReportsTree - ReportsTree (unchanged) - SystemMemoryReporter - SystemReporter prof::time prof::time - TimeProfilerChan - ProfilerChan - TimerMetadata - TimerMetadata (unchanged) - Formatable - Formattable [spelling!] - TimeProfilerMsg - ProfilerMsg - TimeProfilerCategory - ProfilerCategory - TimeProfilerBuckets - ProfilerBuckets - TimeProfiler - Profiler - TimerMetadataFrameType - TimerMetadataFrameType (unchanged) - TimerMetadataReflowType - TimerMetadataReflowType (unchanged) - ProfilerMetadata - ProfilerMetadata (unchanged) In a few places both prof::time and prof::mem are used, and so module-qualification is needed to avoid overlap, e.g. time::Profiler and mem::Profiler. Likewise with std::mem and prof::mem. This is not a big deal. --- components/script/layout_interface.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'components/script/layout_interface.rs') diff --git a/components/script/layout_interface.rs b/components/script/layout_interface.rs index b24adf944f6..e14475aa793 100644 --- a/components/script/layout_interface.rs +++ b/components/script/layout_interface.rs @@ -11,7 +11,7 @@ use dom::node::LayoutData; use geom::point::Point2D; use geom::rect::Rect; use msg::constellation_msg::{PipelineExitType, WindowSizeData}; -use profile::mem::{MemoryReporter, MemoryReportsChan}; +use profile::mem::{Reporter, ReportsChan}; use script_traits::{ScriptControlChan, OpaqueScriptLayoutChannel, UntrustedNodeAddress}; use std::any::Any; use std::sync::mpsc::{channel, Receiver, Sender}; @@ -47,7 +47,7 @@ pub enum Msg { /// Requests that the layout task measure its memory usage. The resulting reports are sent back /// via the supplied channel. - CollectMemoryReports(MemoryReportsChan), + CollectReports(ReportsChan), /// Requests that the layout task enter a quiescent state in which no more messages are /// accepted except `ExitMsg`. A response message will be sent on the supplied channel when @@ -66,7 +66,7 @@ pub enum Msg { /// /// 1) read-only with respect to LayoutTaskData, /// 2) small, -// 3) and really needs to be fast. +/// 3) and really needs to be fast. pub trait LayoutRPC { /// Requests the dimensions of the content box, as in the `getBoundingClientRect()` call. fn content_box(&self) -> ContentBoxResponse; @@ -133,11 +133,11 @@ impl LayoutChan { } } -impl MemoryReporter for LayoutChan { +impl Reporter for LayoutChan { // Just injects an appropriate event into the layout task's queue. - fn collect_reports(&self, reports_chan: MemoryReportsChan) -> bool { + fn collect_reports(&self, reports_chan: ReportsChan) -> bool { let LayoutChan(ref c) = *self; - c.send(Msg::CollectMemoryReports(reports_chan)).is_ok() + c.send(Msg::CollectReports(reports_chan)).is_ok() } } -- cgit v1.2.3