dart-sdk/tests/language/deferred
Ryan Macnak 93a4247af3 Reapply "Account for @pragma("vm:entry-point") creating additional "root" libraries when partitioning the program into loading units."
Weaken assertion in gen_snapshot requiring all libraries to have a loading unit as there can still be unreachable libraries:
  - Google3 and Fuchsia will compile all the sources in a package to a single dill file, then present multiple input dill files to the AOT compilation. Since the set of libraries was derived from package membership instead of imports, many can be unreachable.
  - When the root library's main comes from an export, the frontend's representation will incorrectly report the library containing main as the root library and the true root library may be unreachable from it.

Instead, assert only that surviving compiled code is assigned a loading unit.

TEST=gallery
Bug: https://github.com/flutter/gallery/issues/545
Bug: https://github.com/dart-lang/sdk/issues/49325
Bug: https://github.com/dart-lang/sdk/issues/41974
Bug: b/237016312
Change-Id: Ia52563a6f517308d041368be11dcc85270f19acc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/249724
Commit-Queue: Ryan Macnak <rmacnak@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
2022-06-27 18:56:12 +00:00
..
call_empty_before_load_lib.dart
call_empty_before_load_test.dart
closurize_load_library_lib.dart
closurize_load_library_test.dart
constant_list_lib.dart
constant_list_test.dart
constraints_lib.dart
constraints_lib2.dart
constraints_type_annotation_test.dart Remove the last vestiges of two dead multitest outcomes. 2021-05-05 15:39:45 +00:00
deferred_and_immediate_import_lib.dart
deferred_and_immediate_import_test.dart
duplicate_prefix1_runtime_test.dart
duplicate_prefix1_test.dart
duplicate_prefix2_runtime_test.dart
duplicate_prefix2_test.dart
duplicate_prefix3_runtime_test.dart
duplicate_prefix3_test.dart
exported_main_lib.dart Reapply "Account for @pragma("vm:entry-point") creating additional "root" libraries when partitioning the program into loading units." 2022-06-27 18:56:12 +00:00
exported_main_test.dart Reapply "Account for @pragma("vm:entry-point") creating additional "root" libraries when partitioning the program into loading units." 2022-06-27 18:56:12 +00:00
function_type_lib.dart
function_type_test.dart [vm/aot] Discard Code objects from the heap 2021-04-13 02:36:16 +00:00
global_lib.dart
global_test.dart
import_core_test.dart Add onError extension method to Future. 2021-01-21 23:13:56 +00:00
inheritance_constraints_lib.dart
inheritance_constraints_runtime_test.dart
inheritance_constraints_test.dart Unify three diagnostics for documentation purposes 2021-03-22 14:44:33 +00:00
inlined_test.dart
load_constants.dart
load_constants_runtime_test.dart
load_constants_test.dart Unify four diagnostics for documentation purposes 2021-03-22 14:43:43 +00:00
load_inval_code_lib.dart
load_inval_code_test.dart
load_library_wrong_args_lib.dart
load_library_wrong_args_test.dart [cfe] Fix message offset on unresolved prefix access 2021-08-11 16:12:01 +00:00
loading_unit_root_has_only_export_lib1.dart Reapply "Account for @pragma("vm:entry-point") creating additional "root" libraries when partitioning the program into loading units." 2022-06-27 18:56:12 +00:00
loading_unit_root_has_only_export_lib2.dart Reapply "Account for @pragma("vm:entry-point") creating additional "root" libraries when partitioning the program into loading units." 2022-06-27 18:56:12 +00:00
loading_unit_root_has_only_export_test.dart Reapply "Account for @pragma("vm:entry-point") creating additional "root" libraries when partitioning the program into loading units." 2022-06-27 18:56:12 +00:00
mixin_lib1.dart
mixin_lib2.dart
mixin_shared.dart
mixin_test.dart
no_prefix_runtime_test.dart
no_prefix_test.dart
no_such_method_lib.dart
no_such_method_test.dart
not_loaded_check_lib.dart
not_loaded_check_test.dart
only_constant_lib.dart
only_constant_test.dart
optimized_test.dart
prefix_constraints_lib.dart
prefix_constraints_lib2.dart
prefix_importer_tree_shaken_deferred.dart [vm] Don't write LibraryPrefix::importer_ in AOT snapshots. 2020-09-01 16:49:49 +00:00
prefix_importer_tree_shaken_immediate.dart [vm] Don't write LibraryPrefix::importer_ in AOT snapshots. 2020-09-01 16:49:49 +00:00
prefix_importer_tree_shaken_test.dart [vm] Don't write LibraryPrefix::importer_ in AOT snapshots. 2020-09-01 16:49:49 +00:00
redirecting_factory_lib1.dart
redirecting_factory_lib2.dart
redirecting_factory_test.dart
regression_22995_lib.dart
regression_22995_test.dart
regression_28678_lib.dart
regression_28678_test.dart
shadow_load_library_lib.dart
shadow_load_library_test.dart
shared_and_unshared_classes_lib1.dart
shared_and_unshared_classes_lib2.dart
shared_and_unshared_classes_lib_shared.dart
shared_and_unshared_classes_test.dart [vm/aot] Discard Code objects from the heap 2021-04-13 02:36:16 +00:00
split_constants_canonicalization_a.dart Add tests for the identity of constants repeated in different loading units but not present in the main unit. 2020-10-30 19:16:42 +00:00
split_constants_canonicalization_a_1.dart [tests] fix language/deferred/split_constants_canonicalization_test 2020-12-05 17:47:43 +00:00
split_constants_canonicalization_a_2.dart [tests] fix language/deferred/split_constants_canonicalization_test 2020-12-05 17:47:43 +00:00
split_constants_canonicalization_b.dart Add tests for the identity of constants repeated in different loading units but not present in the main unit. 2020-10-30 19:16:42 +00:00
split_constants_canonicalization_b_1.dart [tests] fix language/deferred/split_constants_canonicalization_test 2020-12-05 17:47:43 +00:00
split_constants_canonicalization_b_2.dart [tests] fix language/deferred/split_constants_canonicalization_test 2020-12-05 17:47:43 +00:00
split_constants_canonicalization_test.dart [vm] Remove support for non-bare AOT snapshots 2021-11-24 13:03:52 +00:00
static_separate_lib1.dart Fix typos 2022-06-15 11:08:28 +00:00
static_separate_lib2.dart Fix typos 2022-06-15 11:08:28 +00:00
static_separate_test.dart Fix typos 2022-06-15 11:08:28 +00:00
super_dependency_lib.dart
super_dependency_runtime_test.dart
super_dependency_test.dart Unify four diagnostic codes for the purpose of documentation 2020-08-11 01:07:44 +00:00
type_dependency_lib1.dart
type_dependency_lib2.dart
type_dependency_lib3.dart
type_dependency_test.dart
unreachable_loading_unit_deferred.dart
unreachable_loading_unit_immediate.dart
unreachable_loading_unit_test.dart