1.Add typelowering framework.
2.Add newobjdynrange in typelowering which brings static TS type
info to runtime phase.
3.Serialize and deserialize hclass table with snapshot, fix minor bugs
in snapshot by the way.
4.Add IsFormTSTypeBit in HClass to distinguish hclasses which come from
compile phase.
5.Fix compatibility issues in property operations api and some builints
api.
6.Add 3 compatibility issues test cases.
Issue:https://gitee.com/openharmony/ark_js_runtime/issues/I5E2N9
Signed-off-by: ding <dingding5@huawei.com>
Change-Id: I98626e6eea01f4455ec818ba0ad872b3be98b729
1.For callee func with variable-length arguments,Aot only receive the first one in variable-length arguments.
So Change to get all args from OptimizedJsFunctionFrame in JsCall
2.Add path to get all args from OptimizedJsFunctionFrame to GetUnmappedArgs.
3.Fix ThrowIfNotObject error found in aottest case getiterator.ts
issue:https://gitee.com/openharmony/ark_js_runtime/issues/I57L70
Signed-off-by: lijincheng <lijincheng13@huawei.com>
Correct the offset of SingleStepDebugging. Return sp in JumpToCInterpreter instead of pc.
Issue: #I5BIJG
Signed-off-by: lichenshuai <lichenshuai@huawei.com>
Change-Id: I1dcfab10b8244a874838434df8c1ea8935d71d84
description:
1 Refactor Call Dispatcher, and Regactor common call
2 use circuit IR implments getter/setter
issue: I59POB
Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
description:
1 add align up for rodata section, incase movdqa crash
2 set gc leaf function attribute for no gc all
3 fix mega ic run slowpath bug for asm interpreter
4 remove trampoline unused code
issue: #I58VFA
Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
1. skip builtin frame and asm interpreter entry frame when upframe
2. skip push args when argc is 0
3. check thread exception, rather not ret value
4. deal with fp when entry Execute
5. deal with call class Constructor
Issue:https://gitee.com/openharmony/ark_js_runtime/issues/I58I4H?from=project-issue
Signed-off-by: zhangyukun <zhangyukun8@huawei.com>
Change-Id: I874f1437d5d21a8cf50a8d9ca73d7a92007f1bab
1.Fix aot newobjdynrange by call JSFunction::Construct.
2.Add native new test case(new non-native constructor depends on
`defineclass`).
3.Add StackAssertScope in debug mode.
4.Delete retired `call` code in runtime_stubs.
5.Refactor GetArg from macros to inline function in RuntimeStubs.
Signed-off-by: ding <dingding5@huawei.com>
Change-Id: Ic89b98af11f2e2fc97aaeba1704d27a95d2c0c7b
Add new stackless stub to syncronize asm interpreter with C interpreter.
Issue: #I54DXV
Signed-off-by: lichenshuai <lichenshuai@huawei.com>
Change-Id: Ie6bef96e4ecd692d5a32a13eaa719859424c4b24
desc: add asmInter debugger to support ide debug.
solu:
1.add bc debugger stub entry;
2.check is or not debug mode in runInternal and switch release to debug or debug to release.
issue: https://gitee.com/openharmony/ark_js_runtime/issues/I53Z4V
Signed-off-by: wanghuan <wanghuan80@huawei.com>
Change-Id: I3f61bed8b4e17c43d22b5e6f103fe897cd8b41c1
Record idx in const pool of aot function in llvmmodule and aotcodeinfo.
Tweak code in circuit builder for slowpath lowering scenario where
constpool is null.
New JSFunction object for main function in AOT file and new JSFunction object
for each defined function in lowerDefineFuncDyn.
Fix bug in call.S after JSMethod refactor.
Issue: https://gitee.com/openharmony/ark_js_runtime/issues/I545X0
Signed-off-by: luochuhao <luochuhao@huawei.com>
Change-Id: Ie6448f8740caddf79c3b9ed3385ba5739c7eb76b
Description
Cut out most of the initialization logic in Runtime::Create and disconnect the
inheritance relationship of most classes such as JSThread.
Issue:
#I53418: Runtime architecture adjustment
Signed-off-by: lifansheng <lifansheng1@huawei.com>
Change-Id: Ib9c1a40354f77d32e515e23334e7f4b4a4fa3259
1 Set FindElementWithCache and Float as no GC runtime
2 Add SavePC for RuntimeCall if needed
issue: #I53PT7
Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
There are some redundant code, such as runtime_api.h/cpp, which only
contains a method. Therefore, we can merge it to corresponding class and
remove these two files.
issue:https://gitee.com/openharmony/ark_js_runtime/issues/I53P9M
Signed-off-by: wuzhefeng <wuzhefeng1@huawei.com>
Change-Id: Ie4ae7c23fbedf15b53e8856d7455aa7c37afd1b3
when function need call another js function, it will lowering to call "JSCall" trampoline function
JSCall trampoline function will check calltarget function, then correct the arguments, finally jump
the native or optimized code address of the target function.
JSCall(glue, argc, calltarget, ....)
then proxy call(glue, argc, callTarget, argv[])
if proxy->GetHandler is function
tail call JSCall(glue, argc, callTarget, argv); // consider performance
else
//Call(trap, handler, «target, thisArgument, argArray»)
call CreateArrayFromList(glue, argc, argv[]) ---> arrHandle // maybe trigger GC, construct OptimizedWithArgvLeaveFrame, visitor argv[0]..argv[argc-1]
call JSCall(glue, argc, method, argv[])
issue:https://gitee.com/openharmony/ark_js_runtime/issues/I52T6B?from=project-issue
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
Change-Id: I994aae1eb9cbf51982348ae6e203c24c326f617e