|
|
|
@ -155,6 +155,7 @@ DECLARE_ASM_HANDLER(HandleLdFalsePref)
|
|
|
|
|
|
|
|
|
|
DECLARE_ASM_HANDLER(HandleThrowDynPref)
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowDyn)), { acc });
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
|
}
|
|
|
|
@ -312,6 +313,7 @@ DECLARE_ASM_HANDLER(HandleGetUnmappedArgsPref)
|
|
|
|
|
{
|
|
|
|
|
DEFVARIABLE(varAcc, VariableType::JS_ANY(), acc);
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GetUnmapedArgs)),
|
|
|
|
|
{});
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -331,6 +333,7 @@ DECLARE_ASM_HANDLER(HandleCopyRestArgsPrefImm16)
|
|
|
|
|
DEFVARIABLE(varAcc, VariableType::JS_ANY(), acc);
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef restIdx = ZExtInt16ToInt32(ReadInst16_1(pc));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CopyRestArgs)),
|
|
|
|
|
{ IntBuildTaggedTypeWithNoGC(restIdx) });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -351,6 +354,7 @@ DECLARE_ASM_HANDLER(HandleCreateArrayWithBufferPrefImm16)
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef imm = ZExtInt16ToInt32(ReadInst16_1(pc));
|
|
|
|
|
GateRef result = GetObjectFromConstPool(constpool, imm);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(CreateArrayWithBuffer)), { result });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -371,6 +375,7 @@ DECLARE_ASM_HANDLER(HandleCreateObjectWithBufferPrefImm16)
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef imm = ZExtInt16ToInt32(ReadInst16_1(pc));
|
|
|
|
|
GateRef result = GetObjectFromConstPool(constpool, imm);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(CreateObjectWithBuffer)), { result });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -392,6 +397,7 @@ DECLARE_ASM_HANDLER(HandleCreateObjectWithExcludedKeysPrefImm16V8V8)
|
|
|
|
|
GateRef numKeys = ReadInst16_1(pc);
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_3(pc)));
|
|
|
|
|
GateRef firstArgRegIdx = ZExtInt8ToInt16(ReadInst8_4(pc));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CreateObjectWithExcludedKeys)),
|
|
|
|
|
{ Int16BuildTaggedTypeWithNoGC(numKeys), obj, Int16BuildTaggedTypeWithNoGC(firstArgRegIdx) });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -412,6 +418,7 @@ DECLARE_ASM_HANDLER(HandleCreateObjectHavingMethodPrefImm16)
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef imm = ZExtInt16ToInt32(ReadInst16_1(pc));
|
|
|
|
|
GateRef result = GetObjectFromConstPool(constpool, imm);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CreateObjectHavingMethod)),
|
|
|
|
|
{ result, acc, constpool }); // acc is env
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -430,6 +437,7 @@ DECLARE_ASM_HANDLER(HandleThrowIfSuperNotCorrectCallPrefImm16)
|
|
|
|
|
{
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef imm = ReadInst16_1(pc);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowIfSuperNotCorrectCall)),
|
|
|
|
|
{ Int16BuildTaggedTypeWithNoGC(imm), acc }); // acc is thisValue
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -448,6 +456,7 @@ DECLARE_ASM_HANDLER(HandleNewLexEnvDynPrefImm16)
|
|
|
|
|
DEFVARIABLE(varAcc, VariableType::JS_ANY(), acc);
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef numVars = ReadInst16_1(pc);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(NewLexicalEnvDyn)),
|
|
|
|
|
{ Int16BuildTaggedTypeWithNoGC(numVars) });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -474,6 +483,7 @@ DECLARE_ASM_HANDLER(HandleNewObjDynRangePrefImm16V8)
|
|
|
|
|
GateRef newTarget = GetVregValue(sp, IntPtrAdd(ZExtInt16ToPtr(firstArgRegIdx), GetIntPtrConstant(1)));
|
|
|
|
|
GateRef firstArgIdx = Int16Add(firstArgRegIdx, firstArgOffset);
|
|
|
|
|
GateRef length = Int16Sub(numArgs, firstArgOffset);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(NewObjDynRange)),
|
|
|
|
|
{ func, newTarget, Int16BuildTaggedTypeWithNoGC(firstArgIdx), Int16BuildTaggedTypeWithNoGC(length) });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -503,6 +513,7 @@ DECLARE_ASM_HANDLER(HandleDefineFuncDynPrefId16Imm16V8)
|
|
|
|
|
Branch(FunctionIsResolved(*result), &isResolved, ¬Resolved);
|
|
|
|
|
Bind(&isResolved);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
result = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(DefinefuncDyn)), { *result });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -550,6 +561,7 @@ DECLARE_ASM_HANDLER(HandleDefineNCFuncDynPrefId16Imm16V8)
|
|
|
|
|
Branch(FunctionIsResolved(*result), &isResolved, ¬Resolved);
|
|
|
|
|
Bind(&isResolved);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
result = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(DefineNCFuncDyn)), { *result });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -598,6 +610,7 @@ DECLARE_ASM_HANDLER(HandleDefineGeneratorFuncPrefId16Imm16V8)
|
|
|
|
|
Branch(FunctionIsResolved(*result), &isResolved, ¬Resolved);
|
|
|
|
|
Bind(&isResolved);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
result = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(DefineGeneratorFunc)), { *result });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -645,6 +658,7 @@ DECLARE_ASM_HANDLER(HandleDefineAsyncFuncPrefId16Imm16V8)
|
|
|
|
|
Branch(FunctionIsResolved(*result), &isResolved, ¬Resolved);
|
|
|
|
|
Bind(&isResolved);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
result = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(DefineAsyncFunc)), { *result });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -692,6 +706,7 @@ DECLARE_ASM_HANDLER(HandleDefineMethodPrefId16Imm16V8)
|
|
|
|
|
Branch(FunctionIsResolved(*result), &isResolved, ¬Resolved);
|
|
|
|
|
Bind(&isResolved);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(DefineMethod)),
|
|
|
|
|
{ *result, acc }); // acc is homeObject
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -732,6 +747,7 @@ DECLARE_ASM_HANDLER(HandleCallSpreadDynPrefV8V8V8)
|
|
|
|
|
GateRef func = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_1(pc)));
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_2(pc)));
|
|
|
|
|
GateRef array = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_3(pc)));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CallSpreadDyn)),
|
|
|
|
|
{ func, obj, array });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -754,6 +770,7 @@ DECLARE_ASM_HANDLER(HandleAsyncFunctionResolvePrefV8V8V8)
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef asyncFuncObj = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_1(pc)));
|
|
|
|
|
GateRef value = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_3(pc)));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(AsyncFunctionResolveOrReject)),
|
|
|
|
|
{ asyncFuncObj, value, TaggedTrue() });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -775,6 +792,7 @@ DECLARE_ASM_HANDLER(HandleAsyncFunctionRejectPrefV8V8V8)
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef asyncFuncObj = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_1(pc)));
|
|
|
|
|
GateRef value = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_3(pc)));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(AsyncFunctionResolveOrReject)),
|
|
|
|
|
{ asyncFuncObj, value, TaggedFalse() });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -798,6 +816,7 @@ DECLARE_ASM_HANDLER(HandleDefineGetterSetterByValuePrefV8V8V8V8)
|
|
|
|
|
GateRef prop = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_2(pc)));
|
|
|
|
|
GateRef getter = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_3(pc)));
|
|
|
|
|
GateRef setter = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_4(pc)));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(DefineGetterSetterByValue)),
|
|
|
|
|
{ obj, prop, getter, setter, acc }); // acc is flag
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -820,6 +839,7 @@ DECLARE_ASM_HANDLER(HandleSuperCallPrefImm16V8)
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
GateRef range = ReadInst16_1(pc);
|
|
|
|
|
GateRef v0 = ZExtInt8ToInt16(ReadInst8_3(pc));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// acc is thisFunc
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(SuperCall)),
|
|
|
|
|
{ acc, Int16BuildTaggedTypeWithNoGC(v0), Int16BuildTaggedTypeWithNoGC(range) });
|
|
|
|
@ -841,7 +861,7 @@ DECLARE_ASM_HANDLER(HandleGetPropIteratorPref)
|
|
|
|
|
{
|
|
|
|
|
DEFVARIABLE(varAcc, VariableType::JS_ANY(), acc);
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GetPropIterator)), { *varAcc });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -859,6 +879,7 @@ DECLARE_ASM_HANDLER(HandleAsyncFunctionEnterPref)
|
|
|
|
|
{
|
|
|
|
|
DEFVARIABLE(varAcc, VariableType::JS_ANY(), acc);
|
|
|
|
|
auto env = GetEnvironment();
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(AsyncFunctionEnter)), {});
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -912,6 +933,7 @@ DECLARE_ASM_HANDLER(HandleGetIteratorPref)
|
|
|
|
|
}
|
|
|
|
|
Bind(¬GeneratorObj);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GetIterator)), { *varAcc });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -930,12 +952,14 @@ DECLARE_ASM_HANDLER(HandleGetIteratorPref)
|
|
|
|
|
|
|
|
|
|
DECLARE_ASM_HANDLER(HandleThrowThrowNotExistsPref)
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowThrowNotExists)), {});
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
DECLARE_ASM_HANDLER(HandleThrowPatternNonCoerciblePref)
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowPatternNonCoercible)), {});
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
|
}
|
|
|
|
@ -950,6 +974,7 @@ DECLARE_ASM_HANDLER(HandleLdHomeObjectPref)
|
|
|
|
|
|
|
|
|
|
DECLARE_ASM_HANDLER(HandleThrowDeleteSuperPropertyPref)
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowDeleteSuperProperty)), {});
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
|
}
|
|
|
|
@ -973,6 +998,7 @@ DECLARE_ASM_HANDLER(HandleMul2DynPrefV8)
|
|
|
|
|
Branch(TaggedIsHole(*result), &isHole, ¬Hole);
|
|
|
|
|
Bind(&isHole);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(Mul2Dyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1011,6 +1037,7 @@ DECLARE_ASM_HANDLER(HandleDiv2DynPrefV8)
|
|
|
|
|
Branch(TaggedIsHole(*result), &isHole, ¬Hole);
|
|
|
|
|
Bind(&isHole);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(Div2Dyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1049,6 +1076,7 @@ DECLARE_ASM_HANDLER(HandleMod2DynPrefV8)
|
|
|
|
|
Branch(TaggedIsHole(*result), &isHole, ¬Hole);
|
|
|
|
|
Bind(&isHole);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(Mod2Dyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1087,6 +1115,7 @@ DECLARE_ASM_HANDLER(HandleEqDynPrefV8)
|
|
|
|
|
Branch(TaggedIsHole(*result), &isHole, ¬Hole);
|
|
|
|
|
Bind(&isHole);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(EqDyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1125,6 +1154,7 @@ DECLARE_ASM_HANDLER(HandleNotEqDynPrefV8)
|
|
|
|
|
Branch(TaggedIsHole(*result), &isHole, ¬Hole);
|
|
|
|
|
Bind(&isHole);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(NotEqDyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1247,6 +1277,7 @@ DECLARE_ASM_HANDLER(HandleLessDynPrefV8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&slowPath);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(LessDyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1353,6 +1384,7 @@ DECLARE_ASM_HANDLER(HandleLessEqDynPrefV8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&slowPath);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(LessEqDyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1459,6 +1491,7 @@ DECLARE_ASM_HANDLER(HandleGreaterDynPrefV8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&slowPath);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GreaterDyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1566,6 +1599,7 @@ DECLARE_ASM_HANDLER(HandleGreaterEqDynPrefV8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&slowPath);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GreaterEqDyn)), { left, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1888,6 +1922,7 @@ DECLARE_ASM_HANDLER(HandleIncDynPrefV8)
|
|
|
|
|
Bind(&valueNotDouble);
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(IncDyn)), { value });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1942,6 +1977,7 @@ DECLARE_ASM_HANDLER(HandleDecDynPrefV8)
|
|
|
|
|
Bind(&valueNotDouble);
|
|
|
|
|
}
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(DecDyn)), { value });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1967,6 +2003,7 @@ DECLARE_ASM_HANDLER(HandleExpDynPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef base = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ExpDyn)),
|
|
|
|
|
{ base, acc }); // acc is exponent
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -1988,6 +2025,7 @@ DECLARE_ASM_HANDLER(HandleIsInDynPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef prop = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(IsInDyn)),
|
|
|
|
|
{ prop, acc }); // acc is obj
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2009,6 +2047,7 @@ DECLARE_ASM_HANDLER(HandleInstanceOfDynPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(InstanceOfDyn)),
|
|
|
|
|
{ obj, acc }); // acc is target
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2075,6 +2114,7 @@ DECLARE_ASM_HANDLER(HandleCreateGeneratorObjPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef genFunc = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CreateGeneratorObj)),
|
|
|
|
|
{ genFunc });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2093,6 +2133,7 @@ DECLARE_ASM_HANDLER(HandleThrowConstAssignmentPrefV8)
|
|
|
|
|
{
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef value = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowConstAssignment)), { value });
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
|
}
|
|
|
|
@ -2124,6 +2165,7 @@ DECLARE_ASM_HANDLER(HandleGetNextPropNamePrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef iter = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GetNextPropName)), { iter });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -2151,6 +2193,7 @@ DECLARE_ASM_HANDLER(HandleThrowIfNotObjectPrefV8)
|
|
|
|
|
DISPATCH(PREF_V8);
|
|
|
|
|
}
|
|
|
|
|
Bind(¬EcmaObject);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowIfNotObject)), {});
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
|
}
|
|
|
|
@ -2162,6 +2205,7 @@ DECLARE_ASM_HANDLER(HandleIterNextPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef iter = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(IterNext)), { iter });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -2182,6 +2226,7 @@ DECLARE_ASM_HANDLER(HandleCloseIteratorPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef iter = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CloseIterator)), { iter });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -2207,6 +2252,7 @@ DECLARE_ASM_HANDLER(HandleSuperCallSpreadPrefV8)
|
|
|
|
|
|
|
|
|
|
GateRef v0 = ReadInst8_1(pc);
|
|
|
|
|
GateRef array = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(SuperCallSpread)),
|
|
|
|
|
{ acc, array }); // acc is thisFunc, sp for newTarget
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2230,6 +2276,7 @@ DECLARE_ASM_HANDLER(HandleDelObjPropPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef prop = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(DelObjProp)),
|
|
|
|
|
{ obj, prop });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2253,6 +2300,7 @@ DECLARE_ASM_HANDLER(HandleNewObjSpreadDynPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef func = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef newTarget = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(NewObjSpreadDyn)),
|
|
|
|
|
{ func, newTarget, acc }); // acc is array
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2276,6 +2324,7 @@ DECLARE_ASM_HANDLER(HandleCreateIterResultObjPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef value = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef flag = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CreateIterResultObj)),
|
|
|
|
|
{ value, flag });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2299,6 +2348,7 @@ DECLARE_ASM_HANDLER(HandleAsyncFunctionAwaitUncaughtPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef asyncFuncObj = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef value = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(AsyncFunctionAwaitUncaught)),
|
|
|
|
|
{ asyncFuncObj, value });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2329,6 +2379,7 @@ DECLARE_ASM_HANDLER(HandleThrowUndefinedIfHolePrefV8V8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&isHole);
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// assert obj.IsString()
|
|
|
|
|
CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ThrowUndefinedIfHole)), { obj });
|
|
|
|
|
DISPATCH_LAST();
|
|
|
|
@ -2343,6 +2394,7 @@ DECLARE_ASM_HANDLER(HandleCopyDataPropertiesPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef dst = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef src = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CopyDataProperties)),
|
|
|
|
|
{ dst, src });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2366,6 +2418,7 @@ DECLARE_ASM_HANDLER(HandleStArraySpreadPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef dst = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef index = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(StArraySpread)),
|
|
|
|
|
{ dst, index, acc }); // acc is res
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2389,6 +2442,7 @@ DECLARE_ASM_HANDLER(HandleGetIteratorNextPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef method = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(GetIteratorNext)),
|
|
|
|
|
{ obj, method });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2412,6 +2466,7 @@ DECLARE_ASM_HANDLER(HandleSetObjectWithProtoPrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef proto = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef obj = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(SetObjectWithProto)),
|
|
|
|
|
{ proto, obj });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2440,6 +2495,7 @@ DECLARE_ASM_HANDLER(HandleLdObjByValuePrefV8V8)
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label accDispatch(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &receiverIsHeapObject, &slowPath);
|
|
|
|
|
Bind(&receiverIsHeapObject);
|
|
|
|
|
{
|
|
|
|
@ -2541,6 +2597,7 @@ DECLARE_ASM_HANDLER(HandleStObjByValuePrefV8V8)
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &receiverIsHeapObject, &slowPath);
|
|
|
|
|
Bind(&receiverIsHeapObject);
|
|
|
|
|
{
|
|
|
|
@ -2631,6 +2688,7 @@ DECLARE_ASM_HANDLER(HandleStOwnByValuePrefV8V8)
|
|
|
|
|
Branch(IsClassConstructor(receiver), &slowPath, ¬ClassConstructor);
|
|
|
|
|
Bind(¬ClassConstructor);
|
|
|
|
|
Label notClassPrototype(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(IsClassPrototype(receiver), &slowPath, ¬ClassPrototype);
|
|
|
|
|
Bind(¬ClassPrototype);
|
|
|
|
|
{
|
|
|
|
@ -2666,6 +2724,7 @@ DECLARE_ASM_HANDLER(HandleLdSuperByValuePrefV8V8)
|
|
|
|
|
GateRef v1 = ReadInst8_2(pc);
|
|
|
|
|
GateRef receiver = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef propKey = GetVregValue(sp, ZExtInt8ToPtr(v1));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(LdSuperByValue)),
|
|
|
|
|
{ receiver, propKey }); // sp for thisFunc
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -2693,6 +2752,7 @@ DECLARE_ASM_HANDLER(HandleStSuperByValuePrefV8V8)
|
|
|
|
|
{ receiver, propKey, acc });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsException(result), &isException, ¬Exception);
|
|
|
|
|
Bind(&isException);
|
|
|
|
|
{
|
|
|
|
@ -2714,7 +2774,7 @@ DECLARE_ASM_HANDLER(HandleLdSuperByNamePrefId32V8)
|
|
|
|
|
GateRef v0 = ReadInst8_5(pc);
|
|
|
|
|
GateRef receiver = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef propKey = GetObjectFromConstPool(constpool, stringId);
|
|
|
|
|
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(LdSuperByValue)),
|
|
|
|
|
{ receiver, propKey }); // sp for thisFunc
|
|
|
|
|
Branch(TaggedIsException(result), &isException, &dispatch);
|
|
|
|
@ -2738,7 +2798,7 @@ DECLARE_ASM_HANDLER(HandleStSuperByNamePrefId32V8)
|
|
|
|
|
GateRef v0 = ReadInst8_5(pc);
|
|
|
|
|
GateRef receiver = GetVregValue(sp, ZExtInt8ToPtr(v0));
|
|
|
|
|
GateRef propKey = GetObjectFromConstPool(constpool, stringId);
|
|
|
|
|
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(StSuperByValue)),
|
|
|
|
|
{ receiver, propKey, acc }); // sp for thisFunc
|
|
|
|
|
Branch(TaggedIsException(result), &isException, &dispatch);
|
|
|
|
@ -2762,6 +2822,7 @@ DECLARE_ASM_HANDLER(HandleLdObjByIndexPrefV8Imm32)
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label accDispatch(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &fastPath, &slowPath);
|
|
|
|
|
Bind(&fastPath);
|
|
|
|
|
{
|
|
|
|
@ -2806,6 +2867,7 @@ DECLARE_ASM_HANDLER(HandleStObjByIndexPrefV8Imm32)
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &fastPath, &slowPath);
|
|
|
|
|
Bind(&fastPath);
|
|
|
|
|
{
|
|
|
|
@ -2842,6 +2904,7 @@ DECLARE_ASM_HANDLER(HandleStOwnByIndexPrefV8Imm32)
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &isHeapObject, &slowPath);
|
|
|
|
|
Bind(&isHeapObject);
|
|
|
|
|
Label notClassConstructor(env);
|
|
|
|
@ -2883,6 +2946,7 @@ DECLARE_ASM_HANDLER(HandleStConstToGlobalRecordPrefId32)
|
|
|
|
|
Label notException(env);
|
|
|
|
|
GateRef stringId = ReadInst32_1(pc);
|
|
|
|
|
GateRef propKey = GetValueFromTaggedArray(VariableType::JS_ANY(), constpool, stringId);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(StGlobalRecord)),
|
|
|
|
|
{ propKey, *varAcc, TaggedTrue() });
|
|
|
|
|
Branch(TaggedIsException(result), &isException, ¬Exception);
|
|
|
|
@ -2903,6 +2967,7 @@ DECLARE_ASM_HANDLER(HandleStLetToGlobalRecordPrefId32)
|
|
|
|
|
Label notException(env);
|
|
|
|
|
GateRef stringId = ReadInst32_1(pc);
|
|
|
|
|
GateRef propKey = GetValueFromTaggedArray(VariableType::JS_ANY(), constpool, stringId);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(StGlobalRecord)),
|
|
|
|
|
{ propKey, *varAcc, TaggedFalse() });
|
|
|
|
|
Branch(TaggedIsException(result), &isException, ¬Exception);
|
|
|
|
@ -2923,6 +2988,7 @@ DECLARE_ASM_HANDLER(HandleStClassToGlobalRecordPrefId32)
|
|
|
|
|
Label notException(env);
|
|
|
|
|
GateRef stringId = ReadInst32_1(pc);
|
|
|
|
|
GateRef propKey = GetValueFromTaggedArray(VariableType::JS_ANY(), constpool, stringId);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(StGlobalRecord)),
|
|
|
|
|
{ propKey, *varAcc, TaggedFalse() });
|
|
|
|
|
Branch(TaggedIsException(result), &isException, ¬Exception);
|
|
|
|
@ -2979,6 +3045,7 @@ DECLARE_ASM_HANDLER(HandleNegDynPrefV8)
|
|
|
|
|
Label notException(env);
|
|
|
|
|
Bind(&valueNotDouble);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(NegDyn)), { value });
|
|
|
|
|
Branch(TaggedIsException(result), &isException, ¬Exception);
|
|
|
|
@ -3028,6 +3095,7 @@ DECLARE_ASM_HANDLER(HandleNotDynPrefV8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&numberNotDouble);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
// slow path
|
|
|
|
|
GateRef result = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(NotDyn)), { value });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -3116,6 +3184,7 @@ DECLARE_ASM_HANDLER(HandleAnd2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&leftNotNumberOrRightNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(ChangeTwoInt32AndToJSTaggedValue)), { left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -3208,6 +3277,7 @@ DECLARE_ASM_HANDLER(HandleOr2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&leftNotNumberOrRightNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(ChangeTwoInt32OrToJSTaggedValue)), { left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -3300,6 +3370,7 @@ DECLARE_ASM_HANDLER(HandleXOr2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&leftNotNumberOrRightNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(ChangeTwoInt32XorToJSTaggedValue)), { left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -3392,6 +3463,7 @@ DECLARE_ASM_HANDLER(HandleAshr2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&leftNotNumberOrRightNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(ChangeTwoUint32AndToJSTaggedValue)), { left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -3485,6 +3557,7 @@ DECLARE_ASM_HANDLER(HandleShr2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&leftNotNumberOrRightNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(ChangeUintAndIntShrToJSTaggedValue)), { left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -3577,6 +3650,7 @@ DECLARE_ASM_HANDLER(HandleShl2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&leftNotNumberOrRightNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue,
|
|
|
|
|
GetInt64Constant(FAST_STUB_ID(ChangeUintAndIntShlToJSTaggedValue)), { left, right });
|
|
|
|
|
Label IsException(env);
|
|
|
|
@ -3622,6 +3696,7 @@ DECLARE_ASM_HANDLER(HandleDefineClassWithBufferPrefId16Imm16Imm16V8V8)
|
|
|
|
|
Label isResolved(env);
|
|
|
|
|
Label isNotResolved(env);
|
|
|
|
|
Label afterCheckResolved(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(FunctionIsResolved(classTemplate), &isResolved, &isNotResolved);
|
|
|
|
|
Bind(&isResolved);
|
|
|
|
|
{
|
|
|
|
@ -3662,6 +3737,7 @@ DECLARE_ASM_HANDLER(HandleLdObjByNamePrefId32V8)
|
|
|
|
|
Label receiverIsHeapObject(env);
|
|
|
|
|
Label dispatch(env);
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &receiverIsHeapObject, &slowPath);
|
|
|
|
|
Bind(&receiverIsHeapObject);
|
|
|
|
|
{
|
|
|
|
@ -3747,6 +3823,7 @@ DECLARE_ASM_HANDLER(HandleStObjByNamePrefId32V8)
|
|
|
|
|
GateRef receiver = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_5(pc)));
|
|
|
|
|
GateRef slotId = ZExtInt8ToInt32(ReadInst8_0(pc));
|
|
|
|
|
DEFVARIABLE(result, VariableType::INT64(), GetHoleConstant(VariableType::INT64()));
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
|
|
|
|
|
Label checkResult(env);
|
|
|
|
|
Label dispatch(env);
|
|
|
|
@ -3833,7 +3910,7 @@ DECLARE_ASM_HANDLER(HandleStOwnByValueWithNameSetPrefV8V8)
|
|
|
|
|
Label notException(env);
|
|
|
|
|
Label isException1(env);
|
|
|
|
|
Label notException1(env);
|
|
|
|
|
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsHeapObject(receiver), &isHeapObject, &slowPath);
|
|
|
|
|
Bind(&isHeapObject);
|
|
|
|
|
{
|
|
|
|
@ -3883,7 +3960,7 @@ DECLARE_ASM_HANDLER(HandleStOwnByNamePrefId32V8)
|
|
|
|
|
GateRef propKey = GetValueFromTaggedArray(VariableType::JS_ANY(), constpool, stringId);
|
|
|
|
|
GateRef receiver = GetVregValue(sp, ZExtInt8ToPtr(ReadInst8_5(pc)));
|
|
|
|
|
DEFVARIABLE(result, VariableType::INT64(), GetHoleConstant(VariableType::INT64()));
|
|
|
|
|
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Label checkResult(env);
|
|
|
|
|
Label dispatch(env);
|
|
|
|
|
|
|
|
|
@ -3939,6 +4016,7 @@ DECLARE_ASM_HANDLER(HandleStOwnByNameWithNameSetPrefId32V8)
|
|
|
|
|
Label notException(env);
|
|
|
|
|
Label isException1(env);
|
|
|
|
|
Label notException1(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(IsJSObject(receiver), &isJSObject, ¬JSObject);
|
|
|
|
|
Bind(&isJSObject);
|
|
|
|
|
{
|
|
|
|
@ -4487,6 +4565,7 @@ DECLARE_ASM_HANDLER(HandleTryLdGlobalByNamePrefId32)
|
|
|
|
|
Label dispatch(env);
|
|
|
|
|
Label icAvailable(env);
|
|
|
|
|
Label icNotAvailable(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsUndefined(profileTypeInfo), &icNotAvailable, &icAvailable);
|
|
|
|
|
Bind(&icAvailable);
|
|
|
|
|
{
|
|
|
|
@ -4584,6 +4663,7 @@ DECLARE_ASM_HANDLER(HandleTryStGlobalByNamePrefId32)
|
|
|
|
|
|
|
|
|
|
Label icAvailable(env);
|
|
|
|
|
Label icNotAvailable(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsUndefined(profileTypeInfo), &icNotAvailable, &icAvailable);
|
|
|
|
|
Bind(&icAvailable);
|
|
|
|
|
{
|
|
|
|
@ -4667,7 +4747,7 @@ DECLARE_ASM_HANDLER(HandleLdGlobalVarPrefId32)
|
|
|
|
|
Label dispatch(env);
|
|
|
|
|
Label slowPath(env);
|
|
|
|
|
GateRef globalObject = GetGlobalObject(glue);
|
|
|
|
|
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Label icAvailable(env);
|
|
|
|
|
Label icNotAvailable(env);
|
|
|
|
|
Branch(TaggedIsUndefined(profileTypeInfo), &icNotAvailable, &icAvailable);
|
|
|
|
@ -4731,6 +4811,7 @@ DECLARE_ASM_HANDLER(HandleStGlobalVarPrefId32)
|
|
|
|
|
|
|
|
|
|
Label icAvailable(env);
|
|
|
|
|
Label icNotAvailable(env);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
Branch(TaggedIsUndefined(profileTypeInfo), &icNotAvailable, &icAvailable);
|
|
|
|
|
Bind(&icAvailable);
|
|
|
|
|
{
|
|
|
|
@ -4780,6 +4861,7 @@ DECLARE_ASM_HANDLER(HandleCreateRegExpWithLiteralPrefId32Imm8)
|
|
|
|
|
GateRef stringId = ReadInst32_1(pc);
|
|
|
|
|
GateRef pattern = GetObjectFromConstPool(constpool, stringId);
|
|
|
|
|
GateRef flags = ReadInst8_5(pc);
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(CreateRegExpWithLiteral)),
|
|
|
|
|
{ pattern, Int8BuildTaggedTypeWithNoGC(flags) });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -4883,6 +4965,7 @@ DECLARE_ASM_HANDLER(HandleToNumberPrefV8)
|
|
|
|
|
}
|
|
|
|
|
Bind(&valueNotNumber);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef res = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(ToNumber)), { value });
|
|
|
|
|
Label isException(env);
|
|
|
|
|
Label notException(env);
|
|
|
|
@ -4986,6 +5069,7 @@ DECLARE_ASM_HANDLER(HandleAdd2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&slowPath);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(Add2Dyn)),
|
|
|
|
|
{ left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
@ -5095,6 +5179,7 @@ DECLARE_ASM_HANDLER(HandleSub2DynPrefV8)
|
|
|
|
|
// slow path
|
|
|
|
|
Bind(&slowPath);
|
|
|
|
|
{
|
|
|
|
|
SetPcToFrame(glue, GetFrame(sp), pc);
|
|
|
|
|
GateRef taggedNumber = CallRuntimeTrampoline(glue, GetInt64Constant(FAST_STUB_ID(Sub2Dyn)),
|
|
|
|
|
{ left, right });
|
|
|
|
|
Label isException(env);
|
|
|
|
|