Bug 1311212 - Add dead CPOW debugging facility (r=mrbkap)

This commit is contained in:
Bill McCloskey
2016-10-18 15:58:33 -07:00
parent ee69fe3289
commit 1deceb4b29
13 changed files with 155 additions and 29 deletions

View File

@@ -91,7 +91,7 @@ class IdToObjectMap
IdToObjectMap();
bool init();
void trace(JSTracer* trc);
void trace(JSTracer* trc, uint64_t minimumId = 0);
void sweep();
bool add(ObjectId id, JSObject* obj);
@@ -200,6 +200,10 @@ class JavaScriptShared : public CPOWManager
uint64_t nextSerialNumber_;
// nextCPOWNumber_ should be the value of nextSerialNumber_ in the other
// process. The next new CPOW we get should have this serial number.
uint64_t nextCPOWNumber_;
// CPOW references can be weak, and any object we store in a map may be
// GCed (at which point the CPOW will report itself "dead" to the owner).
// This means that we don't want to store any js::Wrappers in the CPOW map,