Bug 1331092 - Part 6: Support JSOP_TOASYNCGEN in JIT.

Tag #1287
This commit is contained in:
Gaming4JC 2019-12-14 09:13:04 -05:00 committed by Roy Tam
commit 67b8cd621a
12 changed files with 94 additions and 0 deletions

View file

@ -41,6 +41,7 @@
#include "jit/RangeAnalysis.h"
#include "jit/SharedICHelpers.h"
#include "vm/AsyncFunction.h"
#include "vm/AsyncIteration.h"
#include "vm/MatchPairs.h"
#include "vm/RegExpObject.h"
#include "vm/RegExpStatics.h"
@ -10213,6 +10214,17 @@ CodeGenerator::visitToAsync(LToAsync* lir)
callVM(ToAsyncInfo, lir);
}
typedef JSObject* (*ToAsyncGenFn)(JSContext*, HandleFunction);
static const VMFunction ToAsyncGenInfo =
FunctionInfo<ToAsyncGenFn>(js::WrapAsyncGenerator, "ToAsyncGen");
void
CodeGenerator::visitToAsyncGen(LToAsyncGen* lir)
{
pushArg(ToRegister(lir->unwrapped()));
callVM(ToAsyncGenInfo, lir);
}
typedef bool (*ToIdFn)(JSContext*, HandleScript, jsbytecode*, HandleValue,
MutableHandleValue);
static const VMFunction ToIdInfo = FunctionInfo<ToIdFn>(ToIdOperation, "ToIdOperation");