servo/components/util
Nicholas Nethercote ece2711185 Add memory reporting infrastructure and use it to measure the display list.
This changeset implements the beginnings of fine-grained measurement of
Servo's data structures.

- It adds a new `SizeOf` trait, which is used to measure the memory used
  by heap data structures, and implements it for some std types: Box,
  String, Option, Arc, Vec, and DList.

- It adds a new `MemoryReporter` trait which is used to report memory
  measurements from other threads to the memory profiler. Reporters are
  registered and unregistered with the memory profiler, and the memory
  profiler makes measurement requests of reporters when necessary.

- It plumbs a MemoryProfilerChan through to the layout task so it can
  register a memory reporter.

- It implements the `SizeOf` trait for `DisplayList` and associated
  types, and adds a memory reporter that uses it.

The display list hits 14.77 MiB when viewing
tests/html/perf-rainbow.html, and 2.51 MiB when viewing the Guardians of
the Galaxy Wikipedia page from servo-static-suite. Example output:

  0.29: display-list::http://www.reddit.com/
  0.00: display-list::http://static.adzerk.net/reddit/ads.html?sr=-reddit.com,loggedout&bust2#http://www.reddit.com
  0.00: display-list::http://www.reddit.com/static/createadframe.html

There are a number of FIXME comments indicating sub-optimal things. This
is a big enough change for now that doing them as follow-ups seems best.
2015-03-16 18:12:26 -07:00
..
deque Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
cache.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
Cargo.toml Report detailed RSS measurements from /proc/<pid>/smaps on Linux. 2015-02-23 15:20:32 -08:00
cursor.rs Upgrade to rustc ba2f13ef0 2015-02-04 2015-02-11 14:48:34 -08:00
debug_utils.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
dlist.rs Make dlist::split use new DList::split_off. 2015-02-12 15:39:08 -08:00
fnv.rs Update rustc to 00b112c45a604fa6f4b59af2a40c9deeadfdb7c6/rustc-1.0.0-dev. 2015-01-28 10:16:49 +10:00
geometry.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
lib.rs Report detailed RSS measurements from /proc/<pid>/smaps on Linux. 2015-02-23 15:20:32 -08:00
logical_geometry.rs Upgrade to rustc ba2f13ef0 2015-02-04 2015-02-11 14:48:34 -08:00
memory.rs Add memory reporting infrastructure and use it to measure the display list. 2015-03-16 18:12:26 -07:00
namespace.rs Use Gecko's simpler Bloom filter instead of one based on hash 2014-10-10 17:02:27 -07:00
opts.rs Add --no-ssl flag for bypassing SSL checking 2015-03-14 19:17:07 +05:30
persistent_list.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
range.rs Upgrade to rustc ba2f13ef0 2015-02-04 2015-02-11 14:48:34 -08:00
resource_files.rs Fix warnings in util. 2015-02-13 11:42:13 +01:00
str.rs Fix warnings in util. 2015-02-13 11:42:13 +01:00
task.rs add unwrap to send/recv calls 2015-02-03 16:05:13 +01:00
task_state.rs Upgrade to rustc ba2f13ef0 2015-02-04 2015-02-11 14:48:34 -08:00
taskpool.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
tid.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
time.rs layout: Implement ordered lists, CSS counters, and quotes per CSS 2.1 2015-03-09 17:13:45 -07:00
vec.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00
workqueue.rs Remove uint/int inside components/util (partial #4745). 2015-02-28 15:03:07 +01:00