diff --git a/en/release-notes/changelogs/OpenHarmony_4.0.8.1/changelogs-arkcompiler.md b/en/release-notes/changelogs/OpenHarmony_4.0.8.1/changelogs-arkcompiler.md new file mode 100644 index 0000000000000000000000000000000000000000..a0d37340a474ee713030ae1177a4b9af4bc47a63 --- /dev/null +++ b/en/release-notes/changelogs/OpenHarmony_4.0.8.1/changelogs-arkcompiler.md @@ -0,0 +1,23 @@ +# ArkCompiler Subsystem Changelog + +## cl.ArkCompiler.1 type compileMode uses es2abc by default + +The composition of ArkCompiler in sdk has ts2abc compiler and es2abc compiler, supporting compilation of ets/ts/js files.
+Compilation Mode Introduction:
+​ Non-type compilation: convert ets/ts sourceCode into js sourceCode, and use ArkCompiler compiler es2abc to generate bytecode.
+​ type compilation: convert ets/ts sourceCode into ts sourceCode, and use ArkCompiler compiler ts2abc (previous version)/es2abc (enabled in this version) to generate bytecode.
+Application Project hvigor version:
+​ hvigorVersion field and @ohos/hvigor-ohos-plugin field in dependencies of hvigor-config.json5 file in the hvigor directory of the application project.
+Enable type compilation:
+​ When the hvigor version is greater than or equal to 2.6.0-rc.9.s, the type compilation mode is used by default, or in the build-profile.json5 file of the same level directory as the application sourceCode (src directory), configure the "aotCompileMode": "type" option under the buildOption tag
+ +When type compilation is enabled and this version of the SDK is used, the ArkCompiler compiler es2abc will be used by default to compile the ts sourceCode to generate bytecode, and it is not recommended to use the old version SDK with ts2abc enabled for type compilation.
+ +**Change Impact**
+With DevEco Studio development, after the type compilation mode is enabled and the new version of the SDK is used, due to the change of the compilation mode and the change of the ArkCompiler compiler, application compilation failures and runtime crashes may occur.
+ +**Key API/Component Changes**
+type compileMode uses arkcompiler frontend compiler es2abc by default
+ +**Adaptation Guide** +1. When the hvigor version is greater than or equal to 2.6.0-rc.9.s, the developer needs to configure "aotCompileMode": "" in the build-profile.json5 file to switch to the original compilation mode (not type). diff --git a/zh-cn/release-notes/changelogs/OpenHarmony_4.0.8.1/changelogs-arkcompiler.md b/zh-cn/release-notes/changelogs/OpenHarmony_4.0.8.1/changelogs-arkcompiler.md new file mode 100644 index 0000000000000000000000000000000000000000..8dd9017d4d34ddceb2d866ad047d8112686f4698 --- /dev/null +++ b/zh-cn/release-notes/changelogs/OpenHarmony_4.0.8.1/changelogs-arkcompiler.md @@ -0,0 +1,23 @@ +# ArkCompiler子系统ChangeLog + +## cl.ArkCompiler.1 type编译模式默认使用es2abc + +SDK中ArkCompiler有两个编译器支持ets/ts/js的编译,分别是ts2abc编译器和es2abc编译器。
+编译模式介绍:
+​ 非type编译:ets/ts源码转化为js源码,使用ArkCompiler编译器es2abc生成字节码。
+​ type编译:ets/ts源码转化为ts源码,使用ArkCompiler编译器ts2abc(之前版本)/es2abc(此版本使能)生成字节码。
+应用工程hvigor版本信息查看:
+​ 应用工程hvigor目录hvigor-config.json5文件中hvigorVersion字段以及dependencies中@ohos/hvigor-ohos-plugin字段。
+开启type编译:
+​ hvigor版本大于等于2.6.0-rc.9.s时默认使用type模式编译,或者应用源码(src目录)同级目录build-profile.json5文件中,buildOption标签下配置"aotCompileMode": "type"选项。
+ +当开启type编译且使用该版本的SDK时,将默认使用ArkCompiler编译器es2abc编译ts源码生成字节码,并且不推荐使用使能ts2abc的老版本SDK进行type编译。
+ +**变更影响**
+使用DevEco Studio进行应用开发,使能type编译模式并使用新版SDK后,由于编译模式的变更以及ArkCompiler编译器的变更,可能会出现应用编译失败,运行时Crash等。
+ +**关键的接口/组件变更**
+type编译模式默认使用ArkCompiler编译器es2abc
+ +**适配指导**
+1. hvigor版本大于等于2.6.0-rc.9.s时,切换原来的编译模式(非type),开发者需要在build-profile.json5文件中配置"aotCompileMode":""。