mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-15 06:15:43 +00:00
Bug 872384 - Clone self hosted objects directly into tenured; r=till
The jit is allowed to bake pointers to intrinsics into jitcode. Since all self-hosted clones are intrinsics, we need these to always be tenured. --HG-- extra : rebase_source : b4e6b63db874a95d5eac4cafa34a7aaadd163f58
This commit is contained in:
parent
4a127d1c70
commit
e61de5ae64
@ -611,7 +611,7 @@ CloneObject(JSContext *cx, HandleObject srcObj, CloneMemory &clonedObjects)
|
||||
return NULL;
|
||||
} else {
|
||||
RootedFunction fun(cx, srcObj->toFunction());
|
||||
clone = CloneFunctionObject(cx, fun, cx->global(), fun->getAllocKind());
|
||||
clone = CloneFunctionObject(cx, fun, cx->global(), fun->getAllocKind(), TenuredObject);
|
||||
}
|
||||
} else if (srcObj->isRegExp()) {
|
||||
RegExpObject &reobj = srcObj->asRegExp();
|
||||
@ -632,7 +632,7 @@ CloneObject(JSContext *cx, HandleObject srcObj, CloneMemory &clonedObjects)
|
||||
return NULL;
|
||||
clone = StringObject::create(cx, str);
|
||||
} else if (srcObj->isArray()) {
|
||||
clone = NewDenseEmptyArray(cx);
|
||||
clone = NewDenseEmptyArray(cx, NULL, TenuredObject);
|
||||
} else {
|
||||
JS_ASSERT(srcObj->isNative());
|
||||
clone = NewObjectWithGivenProto(cx, srcObj->getClass(), NULL, cx->global(),
|
||||
|
Loading…
Reference in New Issue
Block a user