mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-01 14:45:29 +00:00
Fix bug 506312, see the bug for the sordid details (r=jorendorff).
This commit is contained in:
parent
f76691bedb
commit
17888173c0
@ -106,8 +106,8 @@ PurgeThreadData(JSContext *cx, JSThreadData *data)
|
||||
{
|
||||
js_PurgeGSNCache(&data->gsnCache);
|
||||
|
||||
if (cx->runtime->gcRegenShapes)
|
||||
js_PurgePropertyCache(cx, &data->propertyCache);
|
||||
/* FIXME: bug 506341. */
|
||||
js_PurgePropertyCache(cx, &data->propertyCache);
|
||||
|
||||
# ifdef JS_TRACER
|
||||
JSTraceMonitor *tm = &data->traceMonitor;
|
||||
|
@ -1632,20 +1632,19 @@ js_DestroyScript(JSContext *cx, JSScript *script)
|
||||
JS_ASSERT_IF(cx->runtime->gcRunning, !script->owner);
|
||||
#endif
|
||||
|
||||
if (!cx->runtime->gcRegenShapes) {
|
||||
/* FIXME: bug 506341; would like to do this only if regenerating shapes. */
|
||||
if (!cx->runtime->gcRunning) {
|
||||
JSStackFrame *fp = js_GetTopStackFrame(cx);
|
||||
|
||||
if (!(fp && (fp->flags & JSFRAME_EVAL))) {
|
||||
js_PurgePropertyCacheForScript(cx, script);
|
||||
|
||||
if (!cx->runtime->gcRunning) {
|
||||
#ifdef CHECK_SCRIPT_OWNER
|
||||
JS_ASSERT(script->owner == cx->thread);
|
||||
JS_ASSERT(script->owner == cx->thread);
|
||||
#endif
|
||||
#ifdef JS_TRACER
|
||||
js_PurgeScriptFragments(cx, script);
|
||||
js_PurgeScriptFragments(cx, script);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -9305,7 +9305,8 @@ TraceRecorder::record_SetPropHit(JSPropCacheEntry* entry, JSScopeProperty* sprop
|
||||
ABORT_TRACE("non-native map");
|
||||
|
||||
LIns* shape_ins = addName(lir->insLoad(LIR_ld, map_ins, offsetof(JSScope, shape)), "shape");
|
||||
guard(true, addName(lir->ins2i(LIR_eq, shape_ins, entry->kshape), "guard(kshape)(record_SetPropHit)"),
|
||||
guard(true,
|
||||
addName(lir->ins2i(LIR_eq, shape_ins, entry->kshape), "guard(kshape)(record_SetPropHit)"),
|
||||
BRANCH_EXIT);
|
||||
|
||||
uint32 vshape = PCVCAP_SHAPE(entry->vcap);
|
||||
@ -9313,7 +9314,8 @@ TraceRecorder::record_SetPropHit(JSPropCacheEntry* entry, JSScopeProperty* sprop
|
||||
LIns *vshape_ins = lir->insLoad(LIR_ld,
|
||||
lir->insLoad(LIR_ldp, cx_ins, offsetof(JSContext, runtime)),
|
||||
offsetof(JSRuntime, protoHazardShape));
|
||||
guard(true, addName(lir->ins2i(LIR_eq, vshape_ins, vshape), "guard(vshape)(record_SetPropHit)"),
|
||||
guard(true,
|
||||
addName(lir->ins2i(LIR_eq, vshape_ins, vshape), "guard(vshape)(record_SetPropHit)"),
|
||||
MISMATCH_EXIT);
|
||||
|
||||
LIns* args[] = { INS_CONSTPTR(sprop), obj_ins, cx_ins };
|
||||
|
Loading…
Reference in New Issue
Block a user