Move profiler code from util into a new crate profile.

- Most of util::memory has been moved into profile::mem, though the
  `SizeOf` trait and related things remain in util::memory. The
  `SystemMemoryReporter` code is now in a submodule
  profile::mem::system_reporter.

- util::time has been moved entirely into profile::time.
This commit is contained in:
Nicholas Nethercote 2015-03-23 16:48:54 -07:00
parent cad58b3bec
commit 52447ccd9b
36 changed files with 850 additions and 726 deletions

27
components/profile/lib.rs Normal file
View file

@ -0,0 +1,27 @@
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#![feature(collections)]
#![feature(core)]
#![cfg_attr(target_os="linux", feature(io))]
#![feature(old_io)]
#![cfg_attr(target_os="linux", feature(page_size))]
#![feature(rustc_private)]
#![feature(std_misc)]
#![cfg_attr(target_os="linux", feature(str_words))]
#[macro_use] extern crate log;
extern crate collections;
extern crate libc;
#[cfg(target_os="linux")]
extern crate regex;
#[cfg(target_os="macos")]
extern crate task_info;
extern crate "time" as std_time;
extern crate util;
extern crate url;
pub mod mem;
pub mod time;