Disable ir of typedarraymap

Disable ir of the map function of buildin typedarray due to correctness problem.

Issue: https://gitee.com/openharmony/arkcompiler_ets_runtime/issues/IADFKB
Test: All pre-merge tests
Change-id: i1ef72089dee8491f11f4b83424a4e5e13f70bf19
Signed-off-by: zhaoziming <zhaoziming9@huawei.com>
This commit is contained in:
zhaoziming 2024-07-16 19:42:56 +08:00
parent 15ea60efd4
commit 626e63738e
5 changed files with 61 additions and 1 deletions

View File

@ -104,7 +104,7 @@
/* %TypedArray%.prototype.lastIndexOf ( searchElement [ , fromIndex ] ) */ \
V("lastIndexOf", LastIndexOf, 1, TypedArrayLastIndexOf) \
/* %TypedArray%.prototype.map ( callbackfn [ , thisArg ] ) */ \
V("map", Map, 1, TypedArrayMap) \
V("map", Map, 1, INVALID) \
/* %TypedArray%.prototype.reduce ( callbackfn [ , initialValue ] ) */ \
V("reduce", Reduce, 1, TypedArrayReduce) \
/* %TypedArray%.prototype.reduceRight ( callbackfn [ , initialValue ] ) */ \

View File

@ -284,6 +284,7 @@ group("ark_aot_ts_test") {
"typedarray",
"typedarray_load_store",
"typedarrayfill",
"typedarraymap",
"typeof",
"unaryop_special_value",
"xor",

View File

@ -0,0 +1,18 @@
# Copyright (c) 2024 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import("//arkcompiler/ets_runtime/test/test_helper.gni")
host_aot_test_action("typedarraymap") {
deps = []
}

View File

@ -0,0 +1,16 @@
# Copyright (c) 2024 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
hello
hello
hello

View File

@ -0,0 +1,25 @@
/*
* Copyright (c) 2024 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
class C extends Float64Array {
}
const v1 = new C(3, 255);
function foo(a, b, c, d) {
print("hello");
}
v1.map(foo);