Lines Matching defs:thread
65 EcmaRuntimeCallInfo *CreateEcmaRuntimeCallInfo(JSThread *thread, JSTaggedValue newTgt, uint32_t argvLength)
69 JSTaggedType *sp = const_cast<JSTaggedType *>(thread->GetCurrentSPFrame());
72 if (thread->IsAsmInterpreter()) {
83 *(--newSp) = panda::ecmascript::ToUintPtr(thread);
88 static JSTaggedType *SetupFrame(JSThread *thread, EcmaRuntimeCallInfo *info)
90 JSTaggedType *sp = const_cast<JSTaggedType *>(thread->GetCurrentSPFrame());
93 // 2 means thread and numArgs
94 if (thread->IsAsmInterpreter()) {
105 thread->SetCurrentSPFrame(newSp);
109 void TearDownFrame(JSThread *thread, JSTaggedType *prev)
111 thread->SetCurrentSPFrame(prev);
114 JSHandle<JSAPILightWeightMap> ConstructobjectLightWeightMap(JSThread *thread)
116 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory();
117 JSHandle<GlobalEnv> env = thread->GetEcmaVM()->GetGlobalEnv();
121 JSObject::GetProperty(thread, JSHandle<JSTaggedValue>(globalObject), key).GetValue();
122 auto objCallInfo1 = CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 6);
126 [[maybe_unused]] auto prev1 = SetupFrame(thread, objCallInfo1);
128 JSHandle<JSFunction> newTarget(thread, result1);
129 auto objCallInfo = CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 4);
133 [[maybe_unused]] auto prev = SetupFrame(thread, objCallInfo);
135 TearDownFrame(thread, prev);
136 JSHandle<JSAPILightWeightMap> mapHandle(thread, result);
140 JSHandle<JSAPILightWeightSet> ConstructobjectLightWeightSet(JSThread *thread)
142 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory();
143 JSHandle<GlobalEnv> env = thread->GetEcmaVM()->GetGlobalEnv();
147 JSObject::GetProperty(thread, JSHandle<JSTaggedValue>(globalObject), key).GetValue();
148 auto objCallInfo1 = CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 6);
152 [[maybe_unused]] auto prev1 = SetupFrame(thread, objCallInfo1);
154 JSHandle<JSFunction> newTarget(thread, result1);
155 auto objCallInfo = CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 4);
159 [[maybe_unused]] auto prev = SetupFrame(thread, objCallInfo);
161 TearDownFrame(thread, prev);
162 JSHandle<JSAPILightWeightSet> mapHandle(thread, result);
177 auto thread = vm->GetAssociatedJSThread();
178 JSHandle<JSAPILightWeightMap> mapHandle = ConstructobjectLightWeightMap(thread);
197 auto thread = vm->GetAssociatedJSThread();
198 JSHandle<JSAPILightWeightSet> mapHandle = ConstructobjectLightWeightSet(thread);