From bcfb0eadfdcfb79e4f8a205a89db1f768da96dc7 Mon Sep 17 00:00:00 2001 From: Nicholas Nethercote Date: Thu, 14 Feb 2013 11:11:46 -0800 Subject: [PATCH] Bug 840809 (part 2) - Measure RegExpCompartment::inUse_. r=sstangl. --HG-- extra : rebase_source : 6eb3e6d42f0dd09eb62ffc887b0e6243de2f7202 --- js/src/vm/RegExpObject.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/src/vm/RegExpObject.cpp b/js/src/vm/RegExpObject.cpp index 1ed17781105..34e30dc2862 100644 --- a/js/src/vm/RegExpObject.cpp +++ b/js/src/vm/RegExpObject.cpp @@ -711,7 +711,10 @@ RegExpCompartment::get(JSContext *cx, HandleAtom atom, JSString *opt, RegExpGuar size_t RegExpCompartment::sizeOfExcludingThis(JSMallocSizeOfFun mallocSizeOf) { - return map_.sizeOfExcludingThis(mallocSizeOf); + size_t n = 0; + n += map_.sizeOfExcludingThis(mallocSizeOf); + n += inUse_.sizeOfExcludingThis(mallocSizeOf); + return n; } /* Functions */