mirror of
https://gitee.com/openharmony/arkcompiler_ets_runtime
synced 2024-11-23 18:20:04 +00:00
Fix wrong PGO worknode for deserialized function
Issue: https://gitee.com/openharmony/arkcompiler_ets_runtime/issues/IAG24R Tests: all per-merge test passed Signed-off-by: zhaoziming <zhaoziming9@huawei.com> Change-Id: I2053dee9f40a71e137c8349cf2e97811bcf365c8
This commit is contained in:
parent
6df8e37801
commit
bcbbd36570
@ -185,6 +185,7 @@ void BaseDeserializer::HandleNewObjectEncodeFlag(SerializedObjectSpace space, u
|
||||
concurrentFunctions_.push_back(reinterpret_cast<JSFunction *>(object));
|
||||
}
|
||||
func->SetRawProfileTypeInfo(thread_, thread_->GlobalConstants()->GetEmptyProfileTypeInfoCell(), SKIP_BARRIER);
|
||||
func->SetWorkNodePointer(reinterpret_cast<uintptr_t>(nullptr));
|
||||
}
|
||||
UpdateMaybeWeak(ObjectSlot(objAddr + fieldOffset), addr, isWeak);
|
||||
if (!isRoot) {
|
||||
|
@ -851,11 +851,12 @@ public:
|
||||
OperationResult result2 = JSObject::GetProperty(thread, res, key2);
|
||||
JSHandle<JSTaggedValue> value2 = result2.GetRawValue();
|
||||
EXPECT_TRUE(value2->IsJSFunction());
|
||||
|
||||
EXPECT_TRUE(JSHandle<JSFunction>::Cast(value2)->GetWorkNodePointer() == reinterpret_cast<uintptr_t>(nullptr));
|
||||
JSHandle<JSTaggedValue> key3(factory->NewFromASCII("key"));
|
||||
OperationResult result3 = JSObject::GetProperty(thread, res, key3);
|
||||
JSHandle<JSTaggedValue> value3 = result3.GetRawValue();
|
||||
EXPECT_TRUE(value3->IsJSFunction());
|
||||
EXPECT_TRUE(JSHandle<JSFunction>::Cast(value3)->GetWorkNodePointer() == reinterpret_cast<uintptr_t>(nullptr));
|
||||
|
||||
Destroy();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user