1# Copyright (c) 2021 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14group("ark_aot_js_test") { 15 testonly = true 16 test_list = [ 17 "asyncfunctionenter", 18 "bigint_typed_array_constructors", 19 "call_default_args", 20 "constructor_returns_non_object", 21 "tryldglobalbyname", 22 "dynamicimport", 23 "formatrangetoparts", 24 "module", 25 "undefined", 26 "cjs", 27 "for_await_of", 28 "dead_code_elimination", 29 "equal", 30 "js_string_equal", 31 "js_string_add", 32 "regressioncase", 33 "definefieldbyname", 34 "definefieldbyname2", 35 "induction_variable", 36 ] 37 38 deps = [] 39 foreach(test, test_list) { 40 deps += [ "${test}:${test}AotAction" ] 41 if (!is_debug) { 42 deps += [ "${test}:${test}AotContextAction" ] 43 } 44 } 45} 46 47group("ark_aot_js_assert_test") { 48 testonly = true 49 deps = [] 50 test_assert_list = [ "emptyif" ] 51 foreach(test, test_assert_list) { 52 deps += [ "${test}:${test}AotAssertAction" ] 53 if (!is_debug) { 54 deps += [ "${test}:${test}AotContextAssertAction" ] 55 } 56 } 57} 58 59group("ark_aot_ts_test") { 60 testonly = true 61 test_list = [ 62 "add", 63 "array", 64 "array_foreach_inline", 65 "array_inline_exception", 66 "ashr", 67 "asyncgenerator", 68 "asyncgeneratormultiloop", 69 "asyncgeneratorrest", 70 "async_context", 71 "async_env", 72 "await", 73 "await_loop", 74 "bc_builder", 75 "bind", 76 "binaryop_special_value", 77 "builtinmath", 78 "builtin_math1", 79 "builtin_math2", 80 "builtins_decode_uri_component", 81 "builtins_string", 82 "call_builtin_objects", 83 "call_same_bytecode_func", 84 "callithisrange", 85 "calls", 86 "classstatic", 87 "class_method_signature", 88 "closeiterator", 89 "combined_pass", 90 "compiler_test", 91 "constpool", 92 "construct_deopt_frame_stack_overflow", 93 "continue_from_finally", 94 "copyrestargs", 95 "createarray_meta_data", 96 "createarrayimm16", 97 "createarraywithbuffer", 98 "createemptyarray", 99 "createemptyobject", 100 "creategeneratorobj", 101 "createiterresultobj", 102 "createobjecthavingmethod", 103 "createobjectwithbuffer", 104 "createobjectwithexcludedkeys", 105 "createregexpwithliteral", 106 "dec", 107 "default_supers", 108 "defineasyncfunc", 109 "defineclasswithbuffer", 110 "defineclass", 111 "definefunc", 112 "definefunc_variable_args", 113 "definegeneratorfunc", 114 "definegettersetterbyvalue", 115 "definemethod", 116 "definencfunc", 117 "delobjprop", 118 "deopt", 119 "deopt_clear_aotflags", 120 "destructuring", 121 "div", 122 "duplicatefunctions", 123 "duplicatekey", 124 "elements_kind", 125 "elements_kind_update", 126 "shr_overflow", 127 "equal_nan", 128 "exception_case1", 129 "exception_case10", 130 "exception_case11", 131 "exception_case12", 132 "exception_case13", 133 "exception_case2", 134 "exception_case3", 135 "exception_case4", 136 "exception_case5", 137 "exception_case6", 138 "exception_case7", 139 "exception_case8", 140 "exception_case9", 141 "exp", 142 "extends_builtins", 143 "fast_call_builtins", 144 "frame_iteration", 145 "frame_states", 146 "forin_delete_property", 147 "forin_dictionary_mode", 148 "forin_empty_prototype", 149 "forin_enum_cache", 150 "forin_non_empty_prototype", 151 "forin_special_object", 152 "forloop", 153 "framestatesalloc", 154 "framestatesasync", 155 "framestatesphi", 156 "framestates_elimination", 157 "generatormerge", 158 "generatorcontinuefinally", 159 "getiterator", 160 "getiteratornext", 161 "getnextpropname", 162 "getpropiterator", 163 "getresumemode", 164 "gettemplateobject", 165 "getunmappedargs", 166 "global_this_ts", 167 "generic_instance_type_literal", 168 "helloaot", 169 "helloconcurrent", 170 "ic", 171 "inc", 172 "inline", 173 "inline_array_exception", 174 "instanceof", 175 "isfalse", 176 "isin", 177 "isomorphism", 178 "istrue", 179 "jsonstringify", 180 "large_func", 181 "large_func_acc", 182 "ldbigint", 183 "ldconst", 184 "ldfunctionpref", 185 "ldglobalvar", 186 "ldobjbyname", 187 "ldobjbyname_typed_path", 188 "ldobjbyvalue", 189 "ldstlexvar", 190 "ldsuperbyname", 191 "load_local_module_var", 192 "logic_op", 193 "loop_peeling", 194 "loop_phi", 195 "loop_with_variable_exchange", 196 "loops", 197 "map", 198 "mod", 199 "modules", 200 "mono_builtin", 201 "mul", 202 "multi_module_compilation", 203 "neg", 204 "nested_if_try_emptycatch", 205 "nested_try_emptycatch", 206 "nested_try_emptycatch_finally", 207 "new", 208 "newlexenv", 209 "newobjrange", 210 "newobjspread", 211 "not", 212 "not_equal", 213 "numberspeculativeretype", 214 "operations_stub_test", 215 "optimization", 216 "optimized_call", 217 "or", 218 "ordinaryhasinstance", 219 "pgo_aot_call_deopt_bridge", 220 "pgo_aot_newobj", 221 "pgo_array_prototype", 222 "pgo_builtins", 223 "pgo_call", 224 "pgo_call_builtin_ctor", 225 "pgo_call_js", 226 "pgo_float32array_construct", 227 "pgo_class_operation", 228 "pgo_class_prototype", 229 "pgo_constant_value_deopt", 230 "pgo_constructor_number", 231 "pgo_element_transition", 232 "pgo_elimination_loadconstoffset", 233 "pgo_fast_call_bridge", 234 "pgo_fast_call_deopt_bridge", 235 "pgo_forof_array", 236 "pgo_forof_map", 237 "pgo_forof_set", 238 "pgo_forof_string", 239 "pgo_forof_typed_array", 240 "pgo_force_ic", 241 "pgo_function_prototype", 242 "pgo_gettersetter", 243 "pgo_extrainfomap_expand", 244 "pgo_extrainfomap_gc", 245 "pgo_inherited_function_operation", 246 "pgo_ldobjbyvalue_array", 247 "pgo_ldobjbyvalue_string", 248 "pgo_retype", 249 "pgo_length", 250 "pgo_loop_peeling", 251 "pgo_math", 252 "pgo_math_round", 253 "pgo_objectliteral_operation", 254 "pgo_object_prototype", 255 "pgo_profiletypeinfo", 256 "pgo_call_deopt_js", 257 "pgo_call_recursive_js", 258 259 #"pgo_call_with_repetitive_method_id", 260 "pgo_char_to_string_deopt", 261 "pgo_on_heap", 262 "pgo_space_flag", 263 "pgo_store_deopt", 264 "pgo_track_type", 265 "poplexenv", 266 "proxy", 267 "privateproperty", 268 "privateproperty_js", 269 "resumegenerator", 270 "rodata", 271 "setobjectwithproto", 272 "set", 273 "shl", 274 "shr", 275 "specialloops", 276 "starrayspread", 277 "statesplit", 278 "stclasstoglobalrecord", 279 "stconsttoglobalrecord", 280 "stglobalvar", 281 "stlettoglobalrecord", 282 "stobjbyindex", 283 "stobjbyname", 284 "stobjbyvalue", 285 "stownbyindex", 286 "stownbyname", 287 "stownbynamewithnameset", 288 "stownbyvalue", 289 "stownbyvaluewithnameset", 290 "strictequal", 291 "strictnotequal", 292 "string", 293 "string_add", 294 "string_equal", 295 "string_localecompare", 296 "stsuperbyname", 297 "sub", 298 "supercall", 299 "supercallspread", 300 "supercallforward", 301 "suspendgenerator", 302 "suspendgeneratorbranch", 303 "suspendgeneratorfor", 304 "suspendgeneratorphi", 305 "suspendgeneratorreturn", 306 "suspendgeneratorthrow", 307 "throw", 308 "throwifsupernotcorrectcall", 309 "throwundefindeifhole", 310 "tonumber", 311 "tonumeric", 312 "try", 313 "try_catch_finally", 314 "try_emptycatch_forloop", 315 "try_emptycatch_nested", 316 "try_emptycatch_switch_case", 317 "try_forloop_emptycatch", 318 "tryldglobalbyname_global_object", 319 "tryldglobalbyname_global_record", 320 "trystglobalbynameprefid32", 321 "ts_hclass_generator", 322 "typedarray", 323 "typedarray_load_store", 324 "typedarrayfill", 325 "typedarraymap", 326 "typeof", 327 "unaryop_special_value", 328 "useless_gate_elimination", 329 "xor", 330 "sharedcheck", 331 "sharedarray", 332 "sharedcollectionsexception", 333 "sharedmap", 334 "sharedJSON", 335 "sharedset", 336 "definesendableclass", 337 "sendableenv", 338 "sendablefunc", 339 "sendablecontext", 340 "createarraywithbuffer2", 341 "builtins_number", 342 "builtins_number2", 343 "builtins_parseint", 344 "constructor", 345 "proxy_fast_call", 346 "shared_module", 347 "func_profile_type_info", 348 "sendable", 349 "webkit_call_convention", 350 "retype_isnan", 351 "inline_abs", 352 "retype_test", 353 ] 354 355 if (!is_debug) { 356 test_list += [ 357 "pgo_function_operation", 358 "proxy2", 359 360 #"lexenv_specialization", 361 #"lexenv_specialization_multi_inline", 362 #"lexenv_specialization_noopt", 363 #"loop_hoist", 364 #"pgo_call_deopt", 365 #"ts_inline", 366 #"ts_inline_accessor", 367 #"ts_inline_accessor_deopt", 368 #"ts_inline_accessor_extends", 369 #"ts_inline_accessor_same_name", 370 #"ts_inline_accessor_symbol", 371 #"ts_inline_change_target", 372 #"ts_inline_deopt", 373 #"ts_inline_deopt_loop", 374 #"ts_inline_exception1", 375 #"ts_inline_exception2", 376 #"ts_inline_exception3", 377 #"ts_inline_exception4", 378 #"ts_inline_exception5", 379 #"ts_inline_exception6", 380 #"ts_inline_exception7", 381 #"ts_inline_exception8", 382 #"ts_inline_extends", 383 #"ts_inline_loop", 384 #"ts_inline_max_call", 385 #"ts_multi_inline", 386 #"ts_multi_inline_deopt", 387 #"ts_multi_inline_max_call", 388 #"ts_multi_inline_recursive", 389 ] 390 } 391 392 deps = [ "builtin_inlining:ark_aot_builtin_inlining_test" ] 393 394 foreach(test, test_list) { 395 deps += [ "${test}:${test}AotAction" ] 396 if (!is_debug) { 397 deps += [ "${test}:${test}AotContextAction" ] 398 } 399 } 400 401 if (is_debug) { 402 debug_test_list = [ 403 # builtins_stub test only print log in debug mode 404 "builtins_array", 405 "builtins_stub", 406 ] 407 foreach(test, debug_test_list) { 408 deps += [ "${test}:${test}AotAction" ] 409 } 410 } 411} 412 413group("ark_aot_ts_assert_test") { 414 testonly = true 415 416 deps = [] 417 assert_test_list = [ 418 "and", 419 "array_bounds_check_elimination", 420 "check_dump", 421 "empty", 422 ] 423 foreach(test, assert_test_list) { 424 deps += [ "${test}:${test}AotAssertAction" ] 425 if (!is_debug) { 426 deps += [ "${test}:${test}AotContextAssertAction" ] 427 } 428 } 429} 430 431group("ark_aot_test") { 432 testonly = true 433 deps = [ 434 ":ark_aot_js_assert_test", 435 ":ark_aot_js_test", 436 ":ark_aot_ts_assert_test", 437 ":ark_aot_ts_test", 438 "analyze_property:analyze_property_test", 439 "aot_compatibility_test:aot_compatibility_test", 440 "aot_multi_constantpool_test:aot_multi_constantpool_test", 441 "aot_type_test:aot_type_test", 442 "object:object_test", 443 "vtable:vtable_test", 444 ] 445 446 if (is_mac) { 447 deps -= [ 448 ":ark_aot_js_assert_test", 449 ":ark_aot_js_test", 450 ":ark_aot_ts_assert_test", 451 ":ark_aot_ts_test", 452 "aot_type_test:aot_type_test", 453 ] 454 } 455} 456