Bug 700915: 64-bit RegExp domaeo_basics diagnostic. (r=billm)

This commit is contained in:
Chris Leary 2011-11-10 12:42:58 -08:00
parent a145bef354
commit 9f866be0ff
2 changed files with 20 additions and 9 deletions

View File

@ -6917,27 +6917,36 @@ mjit::Compiler::jsop_newinit()
return true;
}
bool
mjit::Compiler::jsop_regexp_stub(RegExpObject *reobj)
{
prepareStubCall(Uses(0));
masm.move(ImmPtr(reobj), Registers::ArgReg1);
INLINE_STUBCALL(stubs::RegExp, REJOIN_FALLTHROUGH);
frame.pushSynced(JSVAL_TYPE_OBJECT);
return true;
}
bool
mjit::Compiler::jsop_regexp()
{
JSObject *obj = script->getRegExp(fullAtomIndex(PC));
RegExpStatics *res = globalObj ? globalObj->getRegExpStatics() : NULL;
RegExpObject *reobj = obj->asRegExp();
return jsop_regexp_stub(reobj);
// FIXME diagnostic bug 700915.
#if 0
if (!globalObj ||
obj->getGlobal() != globalObj ||
reobj->getGlobal() != globalObj ||
!cx->typeInferenceEnabled() ||
analysis->localsAliasStack() ||
types::TypeSet::HasObjectFlags(cx, globalObj->getType(cx),
types::OBJECT_FLAG_REGEXP_FLAGS_SET)) {
prepareStubCall(Uses(0));
masm.move(ImmPtr(obj), Registers::ArgReg1);
INLINE_STUBCALL(stubs::RegExp, REJOIN_FALLTHROUGH);
frame.pushSynced(JSVAL_TYPE_OBJECT);
return true;
return jsop_regexp_stub(reobj);
}
RegExpObject *reobj = obj->asRegExp();
RegExpStatics *res = globalObj ? globalObj->getRegExpStatics() : NULL;
DebugOnly<uint32> origFlags = reobj->getFlags();
DebugOnly<uint32> staticsFlags = res->getFlags();
JS_ASSERT((origFlags & staticsFlags) == staticsFlags);
@ -7006,6 +7015,7 @@ mjit::Compiler::jsop_regexp()
stubcc.rejoin(Changes(1));
return true;
#endif
}
bool

View File

@ -707,6 +707,7 @@ private:
bool jsop_arginc(JSOp op, uint32 slot);
bool jsop_localinc(JSOp op, uint32 slot);
bool jsop_newinit();
bool jsop_regexp_stub(RegExpObject *reobj);
bool jsop_regexp();
void jsop_initmethod();
void jsop_initprop();