servo/components/style/gecko_string_cache
Nicholas Nethercote 46e572a497
Store nsDynamicAtom's chars after the end of the object.
This reduces memory usage because we only need one allocation instead of two
for the dynamic atom and its chars, and because we don't need to store a
refcount and a size. It precludes sharing of chars between dynamic atoms, but
we weren't benefiting much from that anyway.

This reduces per-process memory usage by up to several hundred KiB on my
Linux64 box.

One consequence of this change is that we need to allocate + copy in
DOMString::SetKnownLiveAtom(), which could make some things slower.

Bug: 1447951
Reviewed-by: froydnj
2018-06-23 20:36:41 +02:00
..
mod.rs Store nsDynamicAtom's chars after the end of the object. 2018-06-23 20:36:41 +02:00
namespace.rs Run rustfmt on selectors, servo_arc, and style. 2018-04-10 17:35:15 -07:00