Commit Graph

49 Commits

Author SHA1 Message Date
sunzhe23
1f2bd00aad Merge branch 'master' of https://gitee.com/openharmony/ark_js_runtime
Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
2022-03-02 23:56:46 -08:00
sunzhe23
4737a4f59e Related issue: #I4W0C0
Modifications:
* Fix write barrier stub bug
* Adapt HandleNewLexEnvWithNameDynPrefImm16Imm16 for asm interpreter

Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
2022-03-02 01:52:51 -08:00
wupengyong
699c5a0f62 fix ptr cast to taggedvalue
Signed-off-by: wupengyong <wupengyong@huawei.com>
Change-Id: If7ee291d9b705277d815ddf19973622f7ff78ca0
2022-03-02 11:12:53 +08:00
Mingliang Zeng
f433c7efed Related issue: https://gitee.com/openharmony/ark_js_runtime/issues/I4VSUH
Modifications:

* Rename StubMachineType to VariableType
* Remove the information about signed/unsigned
* VariableType is a class that bundled MachineType and GateType (not an enumerator anymore)

Signed-off-by: Mingliang Zeng <zengmingliang1@huawei.com>
2022-03-01 18:54:11 +08:00
wupengyong
05a33528c5 modify call runtime
Signed-off-by: wupengyong <wupengyong@huawei.com>
Change-Id: Iae4050f3e61ba9e76cfedcdff00748c7d78d6ecd
2022-02-26 09:43:43 +08:00
sunzhe23
cc073e1c59 issue:#I4UX5L
Reason: fix FastStub SetPropertyByName crash bug

 Description: SetLayoutToHClass set the wrong machine type, and cause a crash.

Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
2022-02-22 22:57:50 -08:00
zhangyukun
3b881fa018 Sync code from c_asm_interpreter to master
Use Stub to impl handlers of bytecodes and use tail call to impl
dispatch of handlers of bytecodes

Signed-off-by: zhangyukun <zhangyukun8@huawei.com>
Change-Id: I7afabdc40ddfa11345aa1029059514aa4f55b9f8
2022-02-22 17:01:18 +08:00
openharmony_ci
cf3ee3ab96
!577 Add JS Function Entry frame & LeaveFrame
Merge pull request !577 from getingke/js_function_entry_frame
2022-02-21 12:44:08 +00:00
getingke
88429808d5 fixed for revert test code
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I725d9f53d3666b74b9430857e3ac0c8c33b3892c
2022-02-19 13:32:14 +08:00
getingke
deab3fbbbc fixed for gc test
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I358802cfacd4c592abe6fedbb571194b4d85d5d4
2022-02-19 09:54:46 +08:00
getingke
76734dd503 fixed for x86 test double mod ok
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I347316cfbbdc8e2ca15b222e1149a41712b35fca
2022-02-18 14:03:24 +08:00
liuganlin
3f93f046c1 Add container ArrayList
Description
  To ensure the high performance of container classes, ArrayList is provided in ark.
Related issue
  #I4T65T:Add Container ArrayList

Signed-off-by: liuganlin <liuganlin@huawei.com>
2022-02-18 10:37:31 +08:00
luochuhao
068021ac66 Add new Gate opcode: relocatable data and related llvm IR translation.
issue: https://gitee.com/openharmony/ark_js_runtime/issues/I4T3DT?from=project-issue
Signed-off-by: luochuhao <luochuhao@huawei.com>
Change-Id: I06b0a8d9da52f3197b50fcd9807f7f194502437d
2022-02-16 11:02:52 +08:00
songzhengchao
2f9d60d2d6 implement machineType INT* FLOAT* rename to I* and F*
current machineType INT * FLOAT* confuse people to associate UINT*.
the INT* is simlar with LLVM IR too
we reanme  machineType INT* FLOAT* rename to I* and F*

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

Signed-off-by: songzhengchao <songzhengchao@huawei.com>
Change-Id: Ie188e07039cd9f26aed436ce96618ea4143fccd6
2022-02-10 15:51:18 +08:00
songzhengchao
3069773a49 implement word and uint/int mixed usage
current stub Word*** function sometime handle unsigned int or signed
int, we refactor name it uint** or int** whichi is more clear

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

Signed-off-by: songzhengchao <songzhengchao@huawei.com>
Change-Id: Ieb6e201d18c59fdd3fa7130b70389c54d619e3b2
2022-02-09 16:02:32 +08:00
songzhengchao
0e74edbe82 implement fastpath writebarrier and region class init markingbitmap on
construct function and refactor stub call runtime offset which's relative with
arch framework

current stub call runtime writebarrier, writebarrier stub is conveient
to optimized by llvm pass

region class markingbitmap should be not nullptr, it's good way to
inilized on construct class other than lazy inilized

current stub get member offset of runtime class, need to modify multiple
places which is not coveient to maintance. stub call offset by GetOldToxxxOffset and
CheckLayout which is checked by compile phase

issue: https://gitee.com/openharmony/ark_js_runtime/issues/I4SC94
Change-Id: Iec087f07ca27ef95b20ff65ea8bb9408b5887d9c
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2022-02-07 17:23:21 +08:00
wanyanglan
65d1f2de01 Redefine the layout of TypeCode to accommodate MIR, TS types
The current TypeCode is only used to represent the type of the MIR
and cannot represent the TS type data type. The type derivation
process needs to get the TS type information from the circuit ir.

Redefining the layout of TypeCode

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

Signed-off-by: wanyanglan <wanyanglan1@huawei.com>
Change-Id: I53292db81712b84210114f9f92c44b6236c356af
2022-01-30 11:03:57 +08:00
wanyanglan
792f51bbf7 refactoring circuit ir
The current circuit ir is translated to llvm ir according to the type of opcode,
and depends on different platforms. circuit ir, as an intermediate state from MIR
to LLVM IR, only performs the conversion role and should not depend on different
platforms for different conversion operations.

The uniqueness of the opcode is removed, and the opcode is combined with a valuecode,
which indicates the uniqueness of each MIR.

issue: https://gitee.com/openharmony/ark_js_runtime/issues/I4RP3H
Signed-off-by: wanyanglan <wanyanglan1@huawei.com>
Change-Id: I2804e7ba9be58fcc4acf3d95a417224b7984018a
2022-01-26 11:33:05 +08:00
wuzhefeng
4ee0455c00 Signed-off-by: wuzhefeng <wuzhefeng1@huawei.com>
Change-Id: Ic990c5f11caeb3075033719a13e759baaf6dfefb
2022-01-13 00:26:00 -08:00
xliu
9849598f97 1.add arraylist and ArkPrivate. 2.add special container in stub. 3.fix Switch
Signed-off-by: xliu <liuxin259@huawei.com>
Change-Id: I4082326fa075bce0c5c7bf8e6873282086fe5d6e
2022-01-04 19:30:40 +08:00
songzhengchao
5d59d320e7 1 review code
2 visit gc ptr by patchpoint instead of pc
3 contruct frame for aot

Change-Id: I98d1f8e39803ef7e1ac6c2f88e08d3254c6ef6af
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2022-01-01 11:17:09 +08:00
sunzhe23
b5fa6d5cee 1 add macro for glue offset table
2 remove unused FindOwnElement2 stub
3 remove SET_STUB_TO_MODULE marcro and replace it with FAST_RUNTIME_STUB_LIST

Signed-off-by: sunzhe23 <sunzhe23@huawei.com>
2021-12-29 01:44:35 -08:00
getingke
0b2bf052ce fixed for code style check
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I4a644610efc9e0689207818f07667e68e345552c
2021-12-23 17:32:43 +08:00
getingke
c108665b1c fixed for add CompilationConfig Class to support all arch
Change-Id: Ifd5cbb143350ecb9c496d8c7cbc3ee3745e74399
Signed-off-by: getingke <getingke@huawei.com>
2021-12-23 15:00:19 +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
xujie
e818a0ba9e Add FastEqual Stub
Signed-off-by: xujie <xujie101@huawei.com>
2021-11-01 20:09:17 +08:00
songzhengchao
b975e6fd95 code review
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2021-10-30 14:25:13 +08:00
songzhengchao
a331635a94 Merge remote-tracking branch 'szc/gc_x86_2'
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2021-10-30 14:10:40 +08:00
songzhengchao
9d975faeb6 enum MachineType replace with enum class MachineType
GetInteger32Constant replace with GetInt32Constant

Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2021-10-30 10:28:23 +08:00
songzhengchao
8b166ee59f Merge remote-tracking branch 'open/master' into gc_x86_2
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2021-10-29 16:42:01 +08:00
songzhengchao
c4c4d68a4f code review
Signed-off-by: songzhengchao <songzhengchao@huawei.com>
2021-10-28 15:06:25 +08:00
getingke
371ff7fced fixed for code static check
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I537a1ece719508c0a78b0481a62f34896bb65f5c
2021-10-27 16:23:48 +08:00
getingke
f0a82545a7 fixed for review comment by luochuhao
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I74946948bdf127b88a032b16abf49ea890a80bf2
2021-10-27 16:23:48 +08:00
getingke
839ad28e6a fixed for code static check
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I82acce47c83c72a2a9b0c316c4e339d5127e02f7
2021-10-27 16:22:43 +08:00
getingke
27a544bf56 fixed for review comment by wuzhefeng
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: Ie4b779dd73db792c4d8315ad3a051fb9692d0623
2021-10-27 16:22:43 +08:00
getingke
136e3f7b08 fixed 262 test case fail for getpropertybyvalue
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I33b9d68efeb2d8ed19848699c98dedb984174296
2021-10-27 16:09:49 +08:00
getingke
b35952f22a fixed for Set/GetPropertyByValue & test262 case verify
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I06214f39ebff93754edb3d275be4d4d76c1dba0c
2021-10-27 16:09:49 +08:00
wanyanglan
1017da4e46 merge master
Signed-off-by: wanyanglan <wanyanglan1@huawei.com>
Change-Id: Ic60a38cbaf56e04674ae91519c8ab7f161407744
2021-10-19 16:18:32 +08:00
wanyanglan
d4704cb738 translate FastTypeOf function and add corresponding test cases
Signed-off-by: wanyanglan <wanyanglan1@huawei.com>
Change-Id: I3a5d408a7bfe9f21dbe78d3f002fbfb8b0fc9010
2021-10-19 10:05:25 +08:00
wupengyong
50ee964a21 add function call and bugfix ThrowTypeAndReturn
Signed-off-by: wupengyong <wupengyong@huawei.com>
Change-Id: I085d81d00b00a0b49daa0d28af591b83dc1c9759
2021-10-18 20:57:06 +08:00
luochuhao
807af102c3 Tweak on llvm api usage in stub_test.cpp and multiple optimizations
Signed-off-by: luochuhao <luochuhao@huawei.com>
Change-Id: Ia21b1a3e2b3ae13ab5dd151b7654c1f220e3b362
2021-10-12 16:01:56 +08:00
Han00000000
064135d18a fix stub_aot_opt running errors and add arm/arm64 target for js
optimizer

Signed-off-by: Han00000000 <jianghan2@huawei.com>
Change-Id: Idb10d3dffbf79a7f615ccb3f8a468cd35caf73a0
2021-10-12 14:43:18 +08:00
wanyanglan
c613732ebd translate FastMod function and add corresponding test cases
Signed-off-by: wanyanglan <wanyanglan1@huawei.com>
Change-Id: I49271e308a40ee5b3426f0277c02014ec06c8227
2021-10-08 16:47:08 +08:00
luochuhao
36f1b7dbd2 Add stub GetPropertyByName and related test.
Signed-off-by: luochuhao <luochuhao@huawei.com>
Change-Id: Id52bc1b3f33bdd6cfe2e04c45f2ecec9db4f4f31
2021-09-28 16:34:13 +08:00
getingke
05931e38fd fixed for build dependy web & SetPropertyByIndex
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: Icb7d8beb64c8123814b67211db5956e3231a3ecb
2021-09-26 14:47:20 +08:00
getingke
7ff677936c fixed for review comments by wuzhefeng
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I5debcfcc4450fc22e33549911d8c557b2a671a35
2021-09-24 11:47:27 +08:00
getingke
ff82e15154 fixed for codestyle check
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: I3a6a7536a7f079726fd79a4d10d906632eb21644
2021-09-23 19:32:53 +08:00
getingke
2c3adbfbfe fixed for codestyle check
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: If2d8a0734b4c67151468c86854b0299171e4b617
2021-09-23 11:26:42 +08:00
getingke
13e4e9f5a8 rebase with master
Signed-off-by: getingke <getingke@huawei.com>
Change-Id: Ib764c465916b0d8b34f298d04e462b81001d359e
2021-09-23 11:26:42 +08:00