Commit Graph

22 Commits

Author SHA1 Message Date
lukai cdcd46b347 fix concurrent sweep bugs
Both concurrentSweep thread and js thread will operate remember set, which leads to competition.

Use two remembersets, one for concurrentSweep, one for js thread

issue: https://gitee.com/openharmony/ark_js_runtime/issues/I5794M?from=project-issue

Signed-off-by: lukai <lukai25@huawei.com>
Change-Id: Ie86ead2e5f5dfaf47c9830a56d158711b0ba9147
2022-05-15 19:42:58 +08:00
Yuqiang Xian 3f15ef4723 Fix code check issues.
Issue: https://gitee.com/openharmony/ark_js_runtime/issues/I55HWI

Signed-off-by: Yuqiang Xian <xianyuqiang@huawei.com>
2022-05-05 20:40:35 +08:00
Yuqiang Xian 42bbb16a55 Get rid of "Heap" class / instance dependency from "Space" base class.
Issue: https://gitee.com/openharmony/ark_js_runtime/issues/I55HWI

Signed-off-by: Yuqiang Xian <xianyuqiang@huawei.com>
2022-05-05 20:14:16 +08:00
Yuqiang Xian 5925e8ff44 Fix some terminologies used in concurrent marker and sweeper.
Issue: https://gitee.com/openharmony/ark_js_runtime/issues/I54NZF

Signed-off-by: Yuqiang Xian <xianyuqiang@huawei.com>
Change-Id: I2d398290ff7c0febffa7eb15bac78a4c3d9bc6a1
2022-04-27 18:28:18 +08:00
Yuqiang Xian 91c54d3b74 Fix several typos in the code.
Issue: https://gitee.com/openharmony/ark_js_runtime/issues/I54NZF

Signed-off-by: Yuqiang Xian <xianyuqiang@huawei.com>
Change-Id: I51002ec27cbbb46263a104e6e19c5e354dcbc189
2022-04-27 18:28:18 +08:00
yingguofeng@huawei.com aeb8531377 Bitmap Refactor
Refactor the markbitmap used to mark objects and the rememberset used to record cross generational references

https://gitee.com/openharmony/ark_js_runtime/issues/I534B6?from=project-issue

Change-Id: Icc4ac21219b5b7514b77291e436f79cf286515b2
Signed-off-by: yingguofeng@huawei.com <yingguofeng@huawei.com>
2022-04-22 10:28:36 +08:00
xiongluo ae86ac820b Fix OOM and crash problem in triggering gc
1. Trigger GC before huge space and sparse expanding.
2. Avoid triggering concurrent mark twice.
3. Add unittest to check huge objects can be allocated frequently.

Signed-off-by: xiongluo <xiongluo@huawei.com>
2022-04-12 17:01:09 -10:00
yingguofeng@huawei.com de5ce040c0 Bugfix:Fix application bug that found by monkey testing
Description:The Type of Size field in FreeObject modified to JSTaggedValue. Nonmovable And HugeObject Space OOM bugfix

issue: https://gitee.com/openharmony/ark_js_runtime/issues/I4VE6U
Signed-off-by: yingguofeng@huawei.com <yingguofeng@huawei.com>
Change-Id: If4f046d26500e6d7635a3b6e7e7b1c5817027f08
2022-02-26 18:39:47 +08:00
yingguofeng@huawei.com 12e27e6863 Heap code refactoring
Delete MemManager class. The allocation function move to heap.cpp. The Space
manage Allocator.

issue: https://gitee.com/openharmony/ark_js_runtime/issues/I4UTFQ

Change-Id: I03cef52d9a1c86b07323de1e19ead53fe6daaf99
Signed-off-by: yingguofeng@huawei.com <yingguofeng@huawei.com>
2022-02-25 16:03:15 +08:00
openharmony_ci bcff5f0b7a !585 Adjust the initial limits of old space and global space adaptively.
Merge pull request !585 from xiongluo/adjust_initial_limit
2022-02-23 08:26:32 +00:00
xiongluo 70147c1220 The limits of old space and global space were fixed.
According to the survival rate, adjust the initial old space limit adaptively.

 https://gitee.com/openharmony/ark_js_runtime/issues/I4UAY2

Signed-off-by: xiongluo <xiongluo@huawei.com>
2022-02-21 23:05:13 -10:00
dingwen 87e9f4ff3c Modify RegionFactory and Chunk
Description:Divide RegionFactory into HeapRegionAllocator and
NativeAreaAllocator,use ChunkVector replace some unreasonable CVector.
issue:https://gitee.com/openharmony/ark_js_runtime/issues/I4TRB8

Signed-off-by: dingwen <dingwen6@huawei.com>
2022-02-21 15:22:01 +08:00
yingguofeng@huawei.com 3ace067f87 GC performance optimization
1、Delete strategy no gc for start up
2、Adapter performance tools: runtime stat
3、Modify freeObjectKind to freeObjectSet

issue:https://gitee.com/openharmony/ark_js_runtime/issues/I4SASV?from=project-issue

Signed-off-by: yingguofeng@huawei.com <yingguofeng@huawei.com>
Change-Id: I01643755057b6146d1f6b67032256e687873cd07
2022-02-15 14:24:21 +08:00
yingguofeng@huawei.com ef9b13734d Performance optimization for gc
1、Optimize GC parallel evacate strategy: evacuate to old space with FreeListAllocator.
2、Adjust strategy that whole region evacuate: Only support new fromspace to new tospace.
3、Adjust Semi space capacity growing/shrinking strategy and Adjust Semi space initialize size.

splay-benchmark:
blue zone: ark_js(2500), v8(2000)
ark-dev:  ark(1200), v8(1500)

issue:https://gitee.com/openharmony/ark_js_runtime/issues/I4SASV?from=project-issue

Signed-off-by: yingguofeng@huawei.com <yingguofeng@huawei.com>
Change-Id: Ie9c6e94c47f531bf9c1ebf5bc7443dd1acb7d2ac
2022-02-15 14:23:43 +08:00
xiongluo 510d33a07b Optimize GC trigger
Signed-off-by: xiongluo <xiongluo@huawei.com>
2022-01-13 22:30:21 -10:00
linxiang 3178cc419e fix hppgc bug
Signed-off-by: linxiang <linxiang8@huawei.com>
2022-01-07 11:00:49 +08:00
dingwen 066ef423de cset enable
Signed-off-by: dingwen <dingwen6@huawei.com>
2021-12-23 21:06:49 +08:00
zhangyukun a97747fe18 Description:sync from code from wgr_master to ohos
Signed-off-by: zhangyukun <zhangyukun8@huawei.com>
Change-Id: Ic66a9e649de8c0ce530483296fe323b8f50621fb
2021-12-21 09:36:03 +08:00
yingguofeng@huawei.com c259d52c5f Concurrent sweep
Signed-off-by: yingguofeng@huawei.com <yingguofeng@huawei.com>
Change-Id: I2a5a0172577971c96e156f99b5ccf1f6c3d0063c
2021-10-13 17:47:42 +08:00
Han00000000 6a4cf27ff7 fix linking of ark_aot_opt
Signed-off-by: Han00000000 <jianghan2@huawei.com>
Change-Id: I29d3a9dee2497c76dcbcc066a20c2f85b2247d1c
2021-10-09 15:09:43 +08:00
zhangyukun 7ffcc4b20f Sync js_runtime to openharmony
Signed-off-by: zhangyukun <zhangyukun8@huawei.com>
2021-09-08 09:20:53 +08:00
wanyanglan 86cfe52253 add ark js_runtime
Signed-off-by: wanyanglan <wanyanglan1@huawei.com>
Change-Id: Iac7851492f10c0ef1303c621febb65e5fdd22e41
2021-09-05 16:05:06 +08:00