Bug 641027 - Add snapshot-at-the-beginning write barriers for incremental GC (r=luke,bhackett)

This commit is contained in:
Bill McCloskey
2011-10-25 16:07:42 -07:00
parent 5ee7fc420f
commit 267d9855a3
112 changed files with 3686 additions and 1391 deletions

View File

@@ -80,7 +80,7 @@ WeakMapBase::sweepAll(JSTracer *tracer)
} /* namespace js */
typedef WeakMap<JSObject *, Value> ObjectValueMap;
typedef WeakMap<HeapPtr<JSObject>, HeapValue> ObjectValueMap;
static ObjectValueMap *
GetObjectMap(JSObject *obj)
@@ -275,7 +275,7 @@ WeakMap_construct(JSContext *cx, uintN argc, Value *vp)
if (!obj)
return false;
obj->setPrivate(NULL);
obj->initPrivate(NULL);
vp->setObject(*obj);
return true;
@@ -320,7 +320,7 @@ js_InitWeakMapClass(JSContext *cx, JSObject *obj)
JSObject *weakMapProto = global->createBlankPrototype(cx, &WeakMapClass);
if (!weakMapProto)
return NULL;
weakMapProto->setPrivate(NULL);
weakMapProto->initPrivate(NULL);
JSFunction *ctor = global->createConstructor(cx, WeakMap_construct, &WeakMapClass,
CLASS_ATOM(cx, WeakMap), 0);