diff --git a/xla/tests/BUILD b/xla/tests/BUILD index 25045815a5a03..37489e805f8c1 100644 --- a/xla/tests/BUILD +++ b/xla/tests/BUILD @@ -92,10 +92,10 @@ cc_library( "//xla:literal", "//xla:literal_comparison", "//xla:literal_util", - "//xla:test", - "//xla:test_helpers", "//xla:types", "//xla:xla_data_proto_cc", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/base:core_headers", "@com_google_absl//absl/strings:str_format", "@com_google_absl//absl/types:span", @@ -217,11 +217,11 @@ cc_library( "//xla:error_spec", "//xla:literal", "//xla:shape_util", - "//xla:test_helpers", "//xla:util", "//xla:xla_data_proto_cc", "//xla/hlo/ir:hlo", "//xla/hlo/testlib:hlo_hardware_independent_test_base", + "//xla/hlo/testlib:test_helpers", "//xla/hlo/testlib:verified_hlo_module", "//xla/service:computation_placer_hdr", "//xla/service:executable", @@ -348,7 +348,6 @@ cc_library( "//xla:literal_util", "//xla:shape_util", "//xla:status_macros", - "//xla:test_helpers", "//xla:types", "//xla:xla_data_proto_cc", "//xla/client:client_library", @@ -356,6 +355,7 @@ cc_library( "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test_helpers", "//xla/service:interpreter_plugin", # reference backend "//xla/service:platform_util", "//xla/stream_executor:stream_executor_h", @@ -418,13 +418,13 @@ cc_library( ":client_library_test_base", "//xla:shape_util", "//xla:status_macros", - "//xla:test_helpers", "//xla:util", "//xla:xla_data_proto_cc", "//xla/client:client_library", "//xla/client:local_client", "//xla/hlo/builder:xla_computation", "//xla/hlo/parser:hlo_parser", + "//xla/hlo/testlib:test_helpers", "//xla/hlo/testlib:verified_hlo_module", "//xla/service:computation_placer", "//xla/service:hlo_module_config", @@ -453,10 +453,10 @@ xla_test( ":client_library_test_base", ":xla_internal_test_main", "//xla:shape_util", - "//xla:test", "//xla:xla_data_proto_cc", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:logging", ], @@ -512,8 +512,8 @@ xla_test( ":xla_internal_test_main", "//xla:execution_options_util", "//xla:status_macros", - "//xla:test", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "//xla/hlo/transforms:despecializer", "//xla/hlo/transforms/simplifiers:float_normalization", ], @@ -532,8 +532,8 @@ xla_test( ":xla_internal_test_main", "//xla:execution_options_util", "//xla:status_macros", - "//xla:test", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "//xla/hlo/transforms:despecializer", "//xla/hlo/transforms/simplifiers:float_normalization", ], @@ -557,8 +557,8 @@ xla_test( ":xla_internal_test_main", "//xla:execution_options_util", "//xla:status_macros", - "//xla:test", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "//xla/hlo/transforms:despecializer", "//xla/hlo/transforms/simplifiers:float_normalization", "@com_google_absl//absl/algorithm:container", @@ -575,12 +575,12 @@ xla_test( ":xla_internal_test_main", "//xla:literal", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", ], ) @@ -593,10 +593,10 @@ xla_test( ":client_library_test_base", ":xla_internal_test_main", "//xla:shape_util", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:test", ], @@ -660,14 +660,14 @@ xla_test( "//xla:array2d", "//xla:literal", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", "//xla/hlo/builder/lib:arithmetic", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "//xla/stream_executor:stream_executor_h", "@com_google_absl//absl/status:statusor", ], @@ -805,12 +805,12 @@ xla_test( "//xla:literal", "//xla:literal_util", "//xla:status_macros", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", "@com_google_absl//absl/types:span", @@ -826,12 +826,12 @@ xla_test( ":client_library_test_base", ":test_macros_header", ":xla_internal_test_main", - "//xla:test", - "//xla:test_helpers", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/types:span", ], @@ -847,13 +847,13 @@ xla_test( ":xla_internal_test_main", "//xla:literal", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/types:span", "@tsl//tsl/platform:test", @@ -876,10 +876,10 @@ xla_test( "//xla:fp_util", "//xla:literal", "//xla:shape_util", - "//xla:test", "//xla:types", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", "//xla/stream_executor:device_description", "@com_google_absl//absl/base", "@com_google_absl//absl/status:statusor", @@ -899,8 +899,8 @@ cc_library( ":test_macros_header", "//xla:execution_options_util", "//xla:status_macros", - "//xla:test", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "//xla/hlo/transforms:despecializer", "//xla/hlo/transforms/simplifiers:float_normalization", ], @@ -918,11 +918,11 @@ xla_test( "//xla:array2d", "//xla:literal", "//xla:shape_util", - "//xla:test", "//xla:types", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", "@com_google_absl//absl/base", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", @@ -989,7 +989,6 @@ xla_test( "//xla:literal_util", "//xla:reference_util", "//xla:shape_util", - "//xla:test_helpers", "//xla:types", "//xla/client:client_library", "//xla/client:executable_build_options", @@ -998,6 +997,7 @@ xla_test( "//xla/hlo/builder/lib:arithmetic", "//xla/hlo/builder/lib:matrix", "//xla/hlo/parser:hlo_parser", + "//xla/hlo/testlib:test_helpers", "//xla/service", "//xla/service:platform_util", "//xla/service:shaped_buffer", @@ -1131,9 +1131,9 @@ xla_test( "//xla:execution_options_util", "//xla:literal", "//xla:literal_util", - "//xla:test", "//xla/hlo/builder:xla_builder", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "//xla/service", "//xla/service:hlo_module_config", "@tsl//tsl/platform:statusor", @@ -1155,8 +1155,8 @@ xla_test( "//xla:literal", "//xla:shape_util", "//xla:status_macros", - "//xla:test", "//xla:types", + "//xla/hlo/testlib:test", "@com_google_absl//absl/strings", ], ) @@ -1472,10 +1472,10 @@ xla_test( ":xla_internal_test_main", "//xla:array4d", "//xla:reference_util", - "//xla:test", "//xla/client:local_client", "//xla/hlo/builder:padding", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status:statusor", ], ) @@ -1522,8 +1522,6 @@ xla_test( "//xla:literal", "//xla:reference_util", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", "//xla:types", "//xla:util", "//xla:xla_data_proto_cc", @@ -1533,6 +1531,8 @@ xla_test( "//xla/hlo/builder/lib:arithmetic", "//xla/hlo/builder/lib:math", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "//xla/tsl/lib/math:math_util", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", @@ -1558,13 +1558,13 @@ xla_test( "//xla:literal", "//xla:reference_util", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", "//xla:util", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder/lib:arithmetic", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:test", ], @@ -1577,8 +1577,8 @@ xla_test( deps = [ ":client_library_test_base", ":xla_internal_test_main", - "//xla:test", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", "@com_google_googletest//:gtest", "@tsl//tsl/platform:ml_dtypes", ], @@ -1598,9 +1598,9 @@ xla_test( ":test_utils", ":xla_internal_test_main", "//xla:literal", - "//xla:test", - "//xla:test_helpers", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", ], ) @@ -1618,9 +1618,9 @@ xla_test( ":client_library_test_base", ":hlo_test_base", ":xla_internal_test_main", - "//xla:test", "//xla/hlo/builder:xla_builder", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "@com_google_absl//absl/strings", "@tsl//tsl/platform:errors", ], @@ -1680,10 +1680,10 @@ xla_test( ":xla_internal_test_main", "//xla:array2d", "//xla:reference_util", - "//xla:test_helpers", "//xla/client:client_library", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test_helpers", "//xla/service:computation_placer", "//xla/service:local_service", "//xla/service:platform_util", @@ -1710,12 +1710,12 @@ xla_test( "//xla:array2d", "//xla:literal_util", "//xla:shape_util", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", "//xla/hlo/parser:hlo_parser", + "//xla/hlo/testlib:test_helpers", "//xla/tsl/lib/core:status_test_util", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:test", @@ -2013,10 +2013,10 @@ xla_test( "//xla:literal", "//xla:literal_util", "//xla:shape_util", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test_helpers", "@tsl//tsl/platform:test", ], ) @@ -2098,9 +2098,9 @@ xla_test( "//xla:array4d", "//xla:literal", "//xla:literal_util", - "//xla:test", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings:string_view", ], @@ -2174,11 +2174,11 @@ xla_test( "//xla:literal", "//xla:reference_util", "//xla:shape_util", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test_helpers", "//xla/stream_executor:device_description", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", @@ -2206,11 +2206,11 @@ xla_test( ":xla_internal_test_main", "//xla:literal", "//xla:shape_util", - "//xla:test", "//xla:util", "//xla:xla_data_proto_cc", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test", "@com_google_absl//absl/types:span", "@eigen_archive//:eigen3", "@tsl//tsl/platform:protobuf", @@ -2257,12 +2257,12 @@ xla_test( "//xla:literal_util", "//xla:reference_util", "//xla:shape_util", - "//xla:test", "//xla:types", "//xla:xla_data_proto_cc", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "@com_google_absl//absl/log", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/types:span", @@ -2285,7 +2285,7 @@ xla_test( ":xla_internal_test_main", # fixdeps: keep "//xla:literal", "//xla:literal_util", - "//xla:test", + "//xla/hlo/testlib:test", "@tsl//tsl/platform:statusor", ], ) @@ -2342,13 +2342,13 @@ xla_test( ":xla_internal_test_main", "//xla:array4d", "//xla:shape_util", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", "//xla/hlo/builder/lib:arithmetic", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:test", ], @@ -2368,11 +2368,11 @@ xla_test( "//xla:array3d", "//xla:literal_util", "//xla:reference_util", - "//xla:test", - "//xla:test_helpers", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:test", ], @@ -2414,7 +2414,7 @@ xla_test( ":test_macros_header", ":xla_internal_test_main", "//xla:literal_util", - "//xla:test", + "//xla/hlo/testlib:test", ], ) @@ -2596,8 +2596,8 @@ xla_test( "//xla:literal", "//xla:literal_util", "//xla:shape_util", - "//xla:test_helpers", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test_helpers", "//xla/service:computation_placer_hdr", "//xla/service:hlo_runner_interface", "//xla/tsl/lib/core:status_test_util", @@ -2639,8 +2639,8 @@ xla_test( ":xla_internal_test_main", "//xla:literal", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", ], ) @@ -2675,8 +2675,8 @@ xla_test( "//xla:literal", "//xla:literal_util", "//xla:shape_util", - "//xla:test", - "//xla:test_helpers", + "//xla/hlo/testlib:test", + "//xla/hlo/testlib:test_helpers", "//xla/service:hlo_proto_cc", "//xla/tsl/lib/core:status_test_util", "@com_google_absl//absl/status", @@ -2699,7 +2699,6 @@ xla_test( "//xla:literal", "//xla:shape_util", "//xla:status_macros", - "//xla:test", "//xla:xla_data_proto_cc", "//xla/client:client_library", "//xla/client:global_data", @@ -2708,6 +2707,7 @@ xla_test( "//xla/hlo/builder:xla_computation", "//xla/hlo/builder/lib:arithmetic", "//xla/hlo/builder/lib:prng", + "//xla/hlo/testlib:test", "//xla/tsl/lib/core:status_test_util", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", @@ -2729,12 +2729,12 @@ xla_test( "//xla:literal", "//xla:shape_util", "//xla:status_macros", - "//xla:test", "//xla:xla_data_proto_cc", "//xla/client:client_library", "//xla/client:global_data", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test", "//xla/tsl/lib/core:status_test_util", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", @@ -2753,12 +2753,12 @@ xla_test( ":xla_internal_test_main", "//xla:shape_util", "//xla:status_macros", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder:xla_computation", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:test", ], @@ -2820,9 +2820,9 @@ xla_test( deps = [ ":hlo_test_base", "//xla:literal_util", - "//xla:test_helpers", "//xla/hlo/ir:hlo", "//xla/hlo/ir:hlo_module_group", + "//xla/hlo/testlib:test_helpers", "//xla/service:backend", "//xla/service:llvm_compiler", "//xla/stream_executor:device_description", @@ -2974,12 +2974,12 @@ xla_test( ":xla_internal_test_main", "//xla:literal", "//xla:shape_util", - "//xla:test_helpers", "//xla:xla_data_proto_cc", "//xla/client:client_library", "//xla/client:local_client", "//xla/hlo/builder:sharding_builder", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test_helpers", "//xla/service:platform_util", "//xla/service:shaped_buffer", "//xla/service:transfer_manager", @@ -3020,9 +3020,9 @@ xla_cc_test( tags = ["test_xla_cpu_no_thunks"], deps = [ ":local_client_test_base", - "//xla:test_helpers", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test_helpers", "//xla/service:cpu_plugin", "//xla/service:local_service", "@tsl//tsl/platform:test_main", @@ -3062,10 +3062,10 @@ xla_test( "//xla:reference_util", "//xla:shape_util", "//xla:status_macros", - "//xla:test_helpers", "//xla/client:global_data", "//xla/client:local_client", "//xla/hlo/builder:xla_builder", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/types:span", "@tsl//tsl/platform:test", @@ -3090,7 +3090,7 @@ xla_cc_test( deps = [ ":literal_test_util", "//xla:literal", - "//xla:test_helpers", + "//xla/hlo/testlib:test_helpers", "@com_google_absl//absl/strings", "@tsl//tsl/platform:env", "@tsl//tsl/platform:logging", @@ -3141,8 +3141,8 @@ xla_test( ":literal_test_util", ":test_macros_header", ":xla_internal_test_main", - "//xla:test", "//xla:types", + "//xla/hlo/testlib:test", ], ) @@ -3155,7 +3155,7 @@ xla_test( deps = [ ":hlo_test_base", ":xla_internal_test_main", # fixdeps: keep - "//xla:test", + "//xla/hlo/testlib:test", "//xla/service:cpu_plugin", # reference backend "//xla/service:platform_util", "@tsl//tsl/platform:path", @@ -3242,7 +3242,7 @@ xla_test( ":test_macros_header", ":xla_internal_test_main", # fixdeps: keep "//xla:debug_options_flags", - "//xla:test", + "//xla/hlo/testlib:test", ], ) @@ -3255,8 +3255,8 @@ xla_test( ":xla_internal_test_main", # fixdeps: keep "//xla:literal", "//xla:literal_util", - "//xla:test", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status", "@tsl//tsl/platform:statusor", ], @@ -3274,8 +3274,8 @@ xla_test( ":xla_internal_test_main", # fixdeps: keep "//xla:literal", "//xla:literal_util", - "//xla:test", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status", "@tsl//tsl/platform:statusor", ], @@ -3298,12 +3298,12 @@ xla_test( "//xla:array", "//xla:array2d", "//xla:literal", - "//xla:test", "//xla:types", "//xla:xla_data_proto_cc", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder/lib:math", "//xla/hlo/builder/lib:matrix", + "//xla/hlo/testlib:test", "//xla/tsl/lib/core:status_test_util", "@com_google_absl//absl/status:statusor", "@com_google_absl//absl/strings", @@ -3325,11 +3325,11 @@ xla_test( ":xla_internal_test_main", "//xla:array2d", "//xla:literal", - "//xla:test", "//xla:types", "//xla/hlo/builder:xla_builder", "//xla/hlo/builder/lib:arithmetic", "//xla/hlo/builder/lib:matrix", + "//xla/hlo/testlib:test", "//xla/tsl/lib/core:status_test_util", "@com_google_absl//absl/status:statusor", ], @@ -3344,8 +3344,8 @@ xla_test( ":literal_test_util", ":test_macros_header", ":xla_internal_test_main", - "//xla:test", "//xla:types", + "//xla/hlo/testlib:test", ], ) @@ -3356,8 +3356,8 @@ xla_cc_test( deps = [ ":xla_internal_test_main", "//xla:array3d", - "//xla:test", "//xla/hlo/ir:tile_assignment", + "//xla/hlo/testlib:test", "@com_google_absl//absl/hash", ], ) @@ -3371,9 +3371,9 @@ xla_test( ":test_macros_header", ":xla_internal_test_main", "//xla:literal_util", - "//xla:test", "//xla:types", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status:statusor", "@tsl//tsl/platform:statusor", "@tsl//tsl/platform:test", @@ -3394,7 +3394,7 @@ xla_test( "//xla:literal", "//xla:literal_util", "//xla:shape_util", - "//xla:test", + "//xla/hlo/testlib:test", "@com_google_absl//absl/algorithm:container", "@com_google_absl//absl/strings", "@com_google_absl//absl/types:span", @@ -3414,8 +3414,8 @@ xla_test( ":xla_internal_test_main", # fixdeps: keep "//xla:literal", "//xla:literal_util", - "//xla:test", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status", "@tsl//tsl/platform:statusor", ], @@ -3430,8 +3430,8 @@ xla_test( ":xla_internal_test_main", # fixdeps: keep "//xla:literal", "//xla:literal_util", - "//xla:test", "//xla/hlo/ir:hlo", + "//xla/hlo/testlib:test", "@com_google_absl//absl/status", "@tsl//tsl/platform:statusor", ], diff --git a/xla/tests/all_reduce_test.cc b/xla/tests/all_reduce_test.cc index 0fb659f87b09d..d4ce1b89b63ab 100644 --- a/xla/tests/all_reduce_test.cc +++ b/xla/tests/all_reduce_test.cc @@ -16,8 +16,8 @@ limitations under the License. #include #include +#include "xla/hlo/testlib/test.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_pjrt_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/array_elementwise_ops_test.cc b/xla/tests/array_elementwise_ops_test.cc index 6be771f403ec4..fde51c9d99b16 100644 --- a/xla/tests/array_elementwise_ops_test.cc +++ b/xla/tests/array_elementwise_ops_test.cc @@ -38,11 +38,11 @@ limitations under the License. #include "xla/comparison_util.h" #include "xla/fp_util.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/layout_util.h" #include "xla/literal.h" #include "xla/primitive_util.h" #include "xla/stream_executor/device_description.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" #include "xla/types.h" diff --git a/xla/tests/bad_rng_shape_validation_test.cc b/xla/tests/bad_rng_shape_validation_test.cc index f1275741be212..c4a8efbc7509e 100644 --- a/xla/tests/bad_rng_shape_validation_test.cc +++ b/xla/tests/bad_rng_shape_validation_test.cc @@ -19,8 +19,8 @@ limitations under the License. #include "absl/status/statusor.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/shape.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/xla_data.pb.h" #include "tsl/platform/logging.h" diff --git a/xla/tests/batch_norm_grad_test.cc b/xla/tests/batch_norm_grad_test.cc index 0bff1da41b90f..74512febada3c 100644 --- a/xla/tests/batch_norm_grad_test.cc +++ b/xla/tests/batch_norm_grad_test.cc @@ -16,8 +16,8 @@ limitations under the License. #include #include "absl/status/status.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "tsl/platform/statusor.h" diff --git a/xla/tests/batch_norm_training_test.cc b/xla/tests/batch_norm_training_test.cc index 581a47090cfa0..77386432c733b 100644 --- a/xla/tests/batch_norm_training_test.cc +++ b/xla/tests/batch_norm_training_test.cc @@ -16,8 +16,8 @@ limitations under the License. #include #include "absl/status/status.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "tsl/platform/statusor.h" diff --git a/xla/tests/batch_normalization_test.cc b/xla/tests/batch_normalization_test.cc index 3b6aebc95cb05..8569a2b48e651 100644 --- a/xla/tests/batch_normalization_test.cc +++ b/xla/tests/batch_normalization_test.cc @@ -29,11 +29,11 @@ limitations under the License. #include "xla/hlo/ir/hlo_computation.h" #include "xla/hlo/ir/hlo_instruction.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/reference_util.h" #include "xla/shape_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/bfloat16_test.cc b/xla/tests/bfloat16_test.cc index 22085485fde57..2eb9dea66b859 100644 --- a/xla/tests/bfloat16_test.cc +++ b/xla/tests/bfloat16_test.cc @@ -26,11 +26,11 @@ limitations under the License. #include "xla/hlo/ir/hlo_computation.h" #include "xla/hlo/ir/hlo_instruction.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/reference_util.h" #include "xla/shape_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/broadcast_simple_test.cc b/xla/tests/broadcast_simple_test.cc index 2876714ab94e0..0f7f5656dc75e 100644 --- a/xla/tests/broadcast_simple_test.cc +++ b/xla/tests/broadcast_simple_test.cc @@ -23,9 +23,9 @@ limitations under the License. #include "xla/array4d.h" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/call_test.cc b/xla/tests/call_test.cc index 36aae1aed51de..4fdfc73db8429 100644 --- a/xla/tests/call_test.cc +++ b/xla/tests/call_test.cc @@ -18,10 +18,10 @@ limitations under the License. #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/shape_util.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/check_execution_arity_test.cc b/xla/tests/check_execution_arity_test.cc index fd0f5bd9bf75e..5ec2910810944 100644 --- a/xla/tests/check_execution_arity_test.cc +++ b/xla/tests/check_execution_arity_test.cc @@ -20,10 +20,10 @@ limitations under the License. #include "xla/client/global_data.h" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/shape_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" #include "xla/xla_data.pb.h" diff --git a/xla/tests/cholesky_test.cc b/xla/tests/cholesky_test.cc index c52ea4b9ea849..26d10e3dc773b 100644 --- a/xla/tests/cholesky_test.cc +++ b/xla/tests/cholesky_test.cc @@ -23,8 +23,8 @@ limitations under the License. #include "xla/hlo/builder/lib/arithmetic.h" #include "xla/hlo/builder/lib/matrix.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/client_library_test_base.cc b/xla/tests/client_library_test_base.cc index 01944740eab9e..1882948c9595a 100644 --- a/xla/tests/client_library_test_base.cc +++ b/xla/tests/client_library_test_base.cc @@ -26,11 +26,11 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal_util.h" #include "xla/service/platform_util.h" #include "xla/shape_util.h" #include "xla/status_macros.h" -#include "xla/test_helpers.h" #include "xla/xla_data.pb.h" #include "tsl/platform/logging.h" diff --git a/xla/tests/client_test.cc b/xla/tests/client_test.cc index 59eafe57b1214..77f2345c7a1ab 100644 --- a/xla/tests/client_test.cc +++ b/xla/tests/client_test.cc @@ -21,9 +21,9 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/shape_util.h" #include "xla/status_macros.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/compute_constant_test.cc b/xla/tests/compute_constant_test.cc index 6524e47ffa548..7d3065bb0d1fb 100644 --- a/xla/tests/compute_constant_test.cc +++ b/xla/tests/compute_constant_test.cc @@ -23,11 +23,11 @@ limitations under the License. #include "xla/client/global_data.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/layout_util.h" #include "xla/literal.h" #include "xla/shape_util.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" #include "xla/tests/test_utils.h" diff --git a/xla/tests/concat_test.cc b/xla/tests/concat_test.cc index 6f831d8f29c99..7301d7bf8c9c0 100644 --- a/xla/tests/concat_test.cc +++ b/xla/tests/concat_test.cc @@ -22,10 +22,10 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal_util.h" #include "xla/reference_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/concatenate_test.cc b/xla/tests/concatenate_test.cc index 02a28684beaf2..460087a3e16c4 100644 --- a/xla/tests/concatenate_test.cc +++ b/xla/tests/concatenate_test.cc @@ -23,10 +23,10 @@ limitations under the License. #include "absl/strings/str_cat.h" #include "absl/strings/str_join.h" #include "absl/types/span.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/shape.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" #include "tsl/platform/status.h" diff --git a/xla/tests/constant_reduction_function_test.cc b/xla/tests/constant_reduction_function_test.cc index 57c603023610c..4c2529ca46f33 100644 --- a/xla/tests/constant_reduction_function_test.cc +++ b/xla/tests/constant_reduction_function_test.cc @@ -20,7 +20,7 @@ limitations under the License. #include #include -#include "xla/test.h" +#include "xla/hlo/testlib/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/conv_depthwise_backprop_filter_test.cc b/xla/tests/conv_depthwise_backprop_filter_test.cc index d53458d3ae9af..c0770876733e1 100644 --- a/xla/tests/conv_depthwise_backprop_filter_test.cc +++ b/xla/tests/conv_depthwise_backprop_filter_test.cc @@ -17,10 +17,10 @@ limitations under the License. #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/hlo/transforms/despecializer.h" #include "xla/hlo/transforms/simplifiers/float_normalization.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/conv_depthwise_common.cc b/xla/tests/conv_depthwise_common.cc index 5c4bb5d1fcef4..09cd38576322f 100644 --- a/xla/tests/conv_depthwise_common.cc +++ b/xla/tests/conv_depthwise_common.cc @@ -19,10 +19,10 @@ limitations under the License. #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/hlo/transforms/despecializer.h" #include "xla/hlo/transforms/simplifiers/float_normalization.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/conv_depthwise_common.h b/xla/tests/conv_depthwise_common.h index 350858498111f..010dde8489881 100644 --- a/xla/tests/conv_depthwise_common.h +++ b/xla/tests/conv_depthwise_common.h @@ -20,10 +20,10 @@ limitations under the License. #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/hlo/transforms/despecializer.h" #include "xla/hlo/transforms/simplifiers/float_normalization.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/conv_depthwise_test.cc b/xla/tests/conv_depthwise_test.cc index 05d2e6c446ee4..b5dc09522591e 100644 --- a/xla/tests/conv_depthwise_test.cc +++ b/xla/tests/conv_depthwise_test.cc @@ -17,10 +17,10 @@ limitations under the License. #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/hlo/transforms/despecializer.h" #include "xla/hlo/transforms/simplifiers/float_normalization.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/conv_depthwise_common.h" #include "xla/tests/hlo_test_base.h" diff --git a/xla/tests/convolution_dimension_numbers_test.cc b/xla/tests/convolution_dimension_numbers_test.cc index 557f4046ca4e8..833a9266afb3b 100644 --- a/xla/tests/convolution_dimension_numbers_test.cc +++ b/xla/tests/convolution_dimension_numbers_test.cc @@ -22,8 +22,8 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/padding.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/reference_util.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/deallocation_test.cc b/xla/tests/deallocation_test.cc index 213e3f05ed993..b901d7f5f7ebb 100644 --- a/xla/tests/deallocation_test.cc +++ b/xla/tests/deallocation_test.cc @@ -21,8 +21,8 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" -#include "xla/test.h" -#include "xla/test_helpers.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/deconstruct_tuple_test.cc b/xla/tests/deconstruct_tuple_test.cc index e5579e7abc4e2..da6752ffdb1b4 100644 --- a/xla/tests/deconstruct_tuple_test.cc +++ b/xla/tests/deconstruct_tuple_test.cc @@ -23,10 +23,10 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/shape_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" #include "xla/xla_data.pb.h" diff --git a/xla/tests/dynamic_ops_test.cc b/xla/tests/dynamic_ops_test.cc index ab27dbe99072f..747d073fc5dd8 100644 --- a/xla/tests/dynamic_ops_test.cc +++ b/xla/tests/dynamic_ops_test.cc @@ -20,6 +20,7 @@ limitations under the License. #include "xla/client/client_library.h" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/reference_util.h" #include "xla/service/local_service.h" #include "xla/service/platform_util.h" @@ -28,7 +29,6 @@ limitations under the License. #include "xla/stream_executor/device_memory_allocator.h" #include "xla/stream_executor/stream_executor.h" #include "xla/stream_executor/stream_executor_memory_allocator.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/dynamic_reshape_test.cc b/xla/tests/dynamic_reshape_test.cc index b4584a785c7f5..6b0f534c66851 100644 --- a/xla/tests/dynamic_reshape_test.cc +++ b/xla/tests/dynamic_reshape_test.cc @@ -16,9 +16,9 @@ limitations under the License. #include #include +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "tsl/platform/statusor.h" diff --git a/xla/tests/float8_test.cc b/xla/tests/float8_test.cc index 648c718d7cd95..71d50ebd6f867 100644 --- a/xla/tests/float8_test.cc +++ b/xla/tests/float8_test.cc @@ -19,7 +19,7 @@ limitations under the License. #include #include "xla/hlo/builder/xla_builder.h" -#include "xla/test.h" +#include "xla/hlo/testlib/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" #include "tsl/platform/ml_dtypes.h" diff --git a/xla/tests/gather_operation_test.cc b/xla/tests/gather_operation_test.cc index 4f9dd2f9e017c..6544c85d1e022 100644 --- a/xla/tests/gather_operation_test.cc +++ b/xla/tests/gather_operation_test.cc @@ -23,11 +23,11 @@ limitations under the License. #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/service/hlo_module_config.h" #include "xla/service/service.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_pjrt_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/get_dimension_size_test.cc b/xla/tests/get_dimension_size_test.cc index 44d88f0608ea2..3c815fd989d17 100644 --- a/xla/tests/get_dimension_size_test.cc +++ b/xla/tests/get_dimension_size_test.cc @@ -17,9 +17,9 @@ limitations under the License. #include "absl/status/status.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "tsl/platform/statusor.h" diff --git a/xla/tests/grouped_convolution_test.cc b/xla/tests/grouped_convolution_test.cc index 7a86547f171aa..01f10b8273745 100644 --- a/xla/tests/grouped_convolution_test.cc +++ b/xla/tests/grouped_convolution_test.cc @@ -20,10 +20,10 @@ limitations under the License. #include "absl/algorithm/container.h" #include "xla/execution_options_util.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/hlo/transforms/despecializer.h" #include "xla/hlo/transforms/simplifiers/float_normalization.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/half_test.cc b/xla/tests/half_test.cc index 385e362223077..3da23420fccbd 100644 --- a/xla/tests/half_test.cc +++ b/xla/tests/half_test.cc @@ -18,9 +18,9 @@ limitations under the License. #include "absl/status/statusor.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" #include "xla/tests/test_utils.h" diff --git a/xla/tests/hlo_metadata_test.cc b/xla/tests/hlo_metadata_test.cc index 30cb1fa0e3b26..ecd7d3de892a4 100644 --- a/xla/tests/hlo_metadata_test.cc +++ b/xla/tests/hlo_metadata_test.cc @@ -15,8 +15,8 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/service/local_service.h" -#include "xla/test_helpers.h" #include "xla/tests/local_client_test_base.h" namespace xla { diff --git a/xla/tests/hlo_runner_agnostic_test_base.h b/xla/tests/hlo_runner_agnostic_test_base.h index 9b8ae26f615f4..3bb8c5b787a91 100644 --- a/xla/tests/hlo_runner_agnostic_test_base.h +++ b/xla/tests/hlo_runner_agnostic_test_base.h @@ -35,13 +35,13 @@ limitations under the License. #include "xla/hlo/ir/hlo_instruction.h" #include "xla/hlo/ir/hlo_module.h" #include "xla/hlo/testlib/hlo_hardware_independent_test_base.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/hlo/testlib/verified_hlo_module.h" #include "xla/literal.h" #include "xla/service/computation_placer.h" #include "xla/service/executable.h" #include "xla/service/hlo_module_config.h" #include "xla/service/hlo_runner_interface.h" -#include "xla/test_helpers.h" #include "xla/tsl/platform/test.h" #include "xla/util.h" #include "xla/xla_data.pb.h" diff --git a/xla/tests/int4_test.cc b/xla/tests/int4_test.cc index 264a68e2d0479..dc925069a462d 100644 --- a/xla/tests/int4_test.cc +++ b/xla/tests/int4_test.cc @@ -20,7 +20,7 @@ limitations under the License. #include "absl/strings/substitute.h" #include "xla/hlo/ir/hlo_instruction.h" #include "xla/hlo/ir/hlo_opcode.h" -#include "xla/test.h" +#include "xla/hlo/testlib/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/literal_test_util.h b/xla/tests/literal_test_util.h index 01b2aa6433c30..d5d3090288000 100644 --- a/xla/tests/literal_test_util.h +++ b/xla/tests/literal_test_util.h @@ -28,10 +28,10 @@ limitations under the License. #include "xla/array3d.h" #include "xla/array4d.h" #include "xla/error_spec.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/literal_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/types.h" #include "xla/xla_data.pb.h" #include "tsl/platform/errors.h" diff --git a/xla/tests/literal_test_util_test.cc b/xla/tests/literal_test_util_test.cc index 4912a37255d9d..7c6b201fb9a26 100644 --- a/xla/tests/literal_test_util_test.cc +++ b/xla/tests/literal_test_util_test.cc @@ -21,8 +21,8 @@ limitations under the License. #include #include "absl/strings/str_join.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" -#include "xla/test_helpers.h" #include "tsl/platform/env.h" #include "tsl/platform/logging.h" #include "tsl/platform/path.h" diff --git a/xla/tests/llvm_compiler_test.cc b/xla/tests/llvm_compiler_test.cc index 94e37c6466494..b099b6271319b 100644 --- a/xla/tests/llvm_compiler_test.cc +++ b/xla/tests/llvm_compiler_test.cc @@ -25,11 +25,11 @@ limitations under the License. #include "llvm/IR/Module.h" #include "xla/hlo/ir/hlo_instruction.h" #include "xla/hlo/ir/hlo_module_group.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal_util.h" #include "xla/service/backend.h" #include "xla/stream_executor/device_description.h" #include "xla/stream_executor/stream_executor.h" -#include "xla/test_helpers.h" #include "xla/tests/hlo_test_base.h" #include "tsl/platform/casts.h" #include "tsl/platform/test.h" diff --git a/xla/tests/local_client_execute_test.cc b/xla/tests/local_client_execute_test.cc index 22c469aa99286..8d4c0f5345fb6 100644 --- a/xla/tests/local_client_execute_test.cc +++ b/xla/tests/local_client_execute_test.cc @@ -23,6 +23,7 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/sharding_builder.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/layout_util.h" #include "xla/literal.h" #include "xla/service/platform_util.h" @@ -34,7 +35,6 @@ limitations under the License. #include "xla/stream_executor/platform_manager.h" #include "xla/stream_executor/stream_executor.h" #include "xla/stream_executor/stream_executor_memory_allocator.h" -#include "xla/test_helpers.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/local_client_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/local_client_test_base.cc b/xla/tests/local_client_test_base.cc index 0f4750132889b..aaebced1f3b9b 100644 --- a/xla/tests/local_client_test_base.cc +++ b/xla/tests/local_client_test_base.cc @@ -25,12 +25,12 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_computation.h" #include "xla/hlo/parser/hlo_parser.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/map_util.h" #include "xla/service/hlo_module_config.h" #include "xla/shape_util.h" #include "xla/status_macros.h" #include "xla/stream_executor/stream_executor_memory_allocator.h" -#include "xla/test_helpers.h" #include "tsl/platform/env.h" #include "tsl/platform/errors.h" #include "tsl/platform/logging.h" diff --git a/xla/tests/map_test.cc b/xla/tests/map_test.cc index 6d654a74a0665..fcb381bf7e069 100644 --- a/xla/tests/map_test.cc +++ b/xla/tests/map_test.cc @@ -23,11 +23,11 @@ limitations under the License. #include "xla/hlo/builder/lib/arithmetic.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/shape_util.h" #include "xla/stream_executor/stream_executor.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/matmul_test.cc b/xla/tests/matmul_test.cc index 1ed47869346ad..19c671f138b05 100644 --- a/xla/tests/matmul_test.cc +++ b/xla/tests/matmul_test.cc @@ -15,10 +15,10 @@ limitations under the License. #include +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/shape_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/matrix_ops_simple_test.cc b/xla/tests/matrix_ops_simple_test.cc index cabdb174ae76c..b7e06fc286c96 100644 --- a/xla/tests/matrix_ops_simple_test.cc +++ b/xla/tests/matrix_ops_simple_test.cc @@ -27,11 +27,11 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/reference_util.h" #include "xla/shape_util.h" #include "xla/stream_executor/device_description.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/multithreaded_compilation_test.cc b/xla/tests/multithreaded_compilation_test.cc index 1e5f138389a28..f8708a6fef4f6 100644 --- a/xla/tests/multithreaded_compilation_test.cc +++ b/xla/tests/multithreaded_compilation_test.cc @@ -21,12 +21,12 @@ limitations under the License. #include #include "absl/status/status.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/service/hlo.pb.h" #include "xla/shape_util.h" -#include "xla/test.h" -#include "xla/test_helpers.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "xla/tsl/lib/core/status_test_util.h" diff --git a/xla/tests/numerics_test.cc b/xla/tests/numerics_test.cc index b1bfcd9ed24d4..988f9d6990c1c 100644 --- a/xla/tests/numerics_test.cc +++ b/xla/tests/numerics_test.cc @@ -19,8 +19,8 @@ limitations under the License. #include "absl/status/statusor.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "xla/types.h" diff --git a/xla/tests/prng_test.cc b/xla/tests/prng_test.cc index b68f56c415763..0400c3683cc2f 100644 --- a/xla/tests/prng_test.cc +++ b/xla/tests/prng_test.cc @@ -27,10 +27,10 @@ limitations under the License. #include "unsupported/Eigen/SpecialFunctions" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/primitive_util.h" #include "xla/shape_util.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/test_macros.h" #include "xla/util.h" diff --git a/xla/tests/ptxas_bug_120501638.cc b/xla/tests/ptxas_bug_120501638.cc index 2c1217cf8be91..9cc57edcac2ce 100644 --- a/xla/tests/ptxas_bug_120501638.cc +++ b/xla/tests/ptxas_bug_120501638.cc @@ -14,7 +14,7 @@ limitations under the License. ==============================================================================*/ #include "xla/debug_options_flags.h" -#include "xla/test.h" +#include "xla/hlo/testlib/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/query_inferred_shape_test.cc b/xla/tests/query_inferred_shape_test.cc index 871e6266220cc..a163ba58dd831 100644 --- a/xla/tests/query_inferred_shape_test.cc +++ b/xla/tests/query_inferred_shape_test.cc @@ -18,8 +18,8 @@ limitations under the License. #include "absl/status/statusor.h" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/shape_util.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/xla_data.pb.h" #include "tsl/platform/test.h" diff --git a/xla/tests/reduce_precision_test.cc b/xla/tests/reduce_precision_test.cc index b3614174902dc..72b535e2908f7 100644 --- a/xla/tests/reduce_precision_test.cc +++ b/xla/tests/reduce_precision_test.cc @@ -27,9 +27,9 @@ limitations under the License. #include "xla/client/global_data.h" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/layout_util.h" #include "xla/literal.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/replicated_io_feed_test.cc b/xla/tests/replicated_io_feed_test.cc index df9155ab8141a..a6d82d33112c4 100644 --- a/xla/tests/replicated_io_feed_test.cc +++ b/xla/tests/replicated_io_feed_test.cc @@ -20,12 +20,13 @@ limitations under the License. #include "absl/strings/string_view.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/service/computation_placer.h" #include "xla/service/hlo_runner_interface.h" #include "xla/shape_util.h" -#include "xla/test_helpers.h" #include "xla/tests/hlo_pjrt_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tsl/lib/core/status_test_util.h" diff --git a/xla/tests/reshape_motion_test.cc b/xla/tests/reshape_motion_test.cc index 2300df5990c63..07dc6473f2e16 100644 --- a/xla/tests/reshape_motion_test.cc +++ b/xla/tests/reshape_motion_test.cc @@ -25,12 +25,12 @@ limitations under the License. #include "xla/client/global_data.h" #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/layout_util.h" #include "xla/literal.h" #include "xla/reference_util.h" #include "xla/shape_util.h" #include "xla/status_macros.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/reshape_test.cc b/xla/tests/reshape_test.cc index 84d51c5f53de4..925b3e2f72b84 100644 --- a/xla/tests/reshape_test.cc +++ b/xla/tests/reshape_test.cc @@ -31,12 +31,12 @@ limitations under the License. #include "xla/error_spec.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/layout_util.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/reference_util.h" #include "xla/shape_util.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/sample_file_test.cc b/xla/tests/sample_file_test.cc index 367ef95880fb9..be3392fbb79df 100644 --- a/xla/tests/sample_file_test.cc +++ b/xla/tests/sample_file_test.cc @@ -19,8 +19,8 @@ limitations under the License. #include #include +#include "xla/hlo/testlib/test.h" #include "xla/service/platform_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "tsl/platform/path.h" #include "tsl/platform/test.h" diff --git a/xla/tests/sample_text_test.cc b/xla/tests/sample_text_test.cc index 576cdeffea8a8..3b5dc2692149d 100644 --- a/xla/tests/sample_text_test.cc +++ b/xla/tests/sample_text_test.cc @@ -20,7 +20,7 @@ limitations under the License. #include #include -#include "xla/test.h" +#include "xla/hlo/testlib/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/scalar_computations_test.cc b/xla/tests/scalar_computations_test.cc index bc9ab8b7326d3..b5383efe438b3 100644 --- a/xla/tests/scalar_computations_test.cc +++ b/xla/tests/scalar_computations_test.cc @@ -25,10 +25,10 @@ limitations under the License. #include "xla/client/local_client.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal.h" #include "xla/literal_util.h" #include "xla/status_macros.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/scatter_test.cc b/xla/tests/scatter_test.cc index 0151b863e1a08..f3d32dfe758e9 100644 --- a/xla/tests/scatter_test.cc +++ b/xla/tests/scatter_test.cc @@ -19,10 +19,10 @@ limitations under the License. #include "absl/strings/substitute.h" #include "xla/array2d.h" #include "xla/error_spec.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/shape_util.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/set_dimension_size_test.cc b/xla/tests/set_dimension_size_test.cc index 5e7d3984f5952..3674e58280264 100644 --- a/xla/tests/set_dimension_size_test.cc +++ b/xla/tests/set_dimension_size_test.cc @@ -18,9 +18,9 @@ limitations under the License. #include "absl/status/status.h" #include "xla/hlo/ir/hlo_module.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" #include "xla/literal_util.h" -#include "xla/test.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/test_macros.h" #include "tsl/platform/statusor.h" diff --git a/xla/tests/tile_assignment_test.cc b/xla/tests/tile_assignment_test.cc index 0f8368555f320..9f20e86d6b452 100644 --- a/xla/tests/tile_assignment_test.cc +++ b/xla/tests/tile_assignment_test.cc @@ -20,7 +20,7 @@ limitations under the License. #include "absl/hash/hash.h" #include "xla/array3d.h" -#include "xla/test.h" +#include "xla/hlo/testlib/test.h" namespace xla { namespace { diff --git a/xla/tests/triangular_solve_test.cc b/xla/tests/triangular_solve_test.cc index 3bbe5ca227c07..a2e6334f69f99 100644 --- a/xla/tests/triangular_solve_test.cc +++ b/xla/tests/triangular_solve_test.cc @@ -24,8 +24,8 @@ limitations under the License. #include "xla/hlo/builder/lib/math.h" #include "xla/hlo/builder/lib/matrix.h" #include "xla/hlo/builder/xla_builder.h" +#include "xla/hlo/testlib/test.h" #include "xla/literal.h" -#include "xla/test.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" diff --git a/xla/tests/tuple_test.cc b/xla/tests/tuple_test.cc index 5cc7f7b1bb9d1..2c9e6ed0073cb 100644 --- a/xla/tests/tuple_test.cc +++ b/xla/tests/tuple_test.cc @@ -22,9 +22,9 @@ limitations under the License. #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" #include "xla/hlo/parser/hlo_parser.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/literal_util.h" #include "xla/shape_util.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/hlo_test_base.h" #include "xla/tests/literal_test_util.h" diff --git a/xla/tests/value_inference_test.cc b/xla/tests/value_inference_test.cc index 5ac2f038f6718..661ff06b44075 100644 --- a/xla/tests/value_inference_test.cc +++ b/xla/tests/value_inference_test.cc @@ -28,11 +28,11 @@ limitations under the License. #include "xla/hlo/builder/lib/prng.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test.h" #include "xla/layout_util.h" #include "xla/literal.h" #include "xla/shape_util.h" #include "xla/status_macros.h" -#include "xla/test.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h" #include "xla/tests/test_utils.h" diff --git a/xla/tests/vector_ops_simple_test.cc b/xla/tests/vector_ops_simple_test.cc index eb67f886d6254..a9705b0c61f28 100644 --- a/xla/tests/vector_ops_simple_test.cc +++ b/xla/tests/vector_ops_simple_test.cc @@ -26,8 +26,8 @@ limitations under the License. #include "xla/hlo/builder/lib/arithmetic.h" #include "xla/hlo/builder/xla_builder.h" #include "xla/hlo/builder/xla_computation.h" +#include "xla/hlo/testlib/test_helpers.h" #include "xla/shape_util.h" -#include "xla/test_helpers.h" #include "xla/tests/client_library_test_base.h" #include "xla/tests/literal_test_util.h" #include "xla/tests/test_macros.h"