Skip to content

Commit

Permalink
[HLO Componentization] Create hlo/analysis sub-component (Phase II).
Browse files Browse the repository at this point in the history
This CL takes care of
1. Migrating external projects dependencies from  xla/service --> xla/hlo/analysis

Phase I takes care of
1. Migrating xla/service/<analysis-passes> --> xla/hlo/analysis/<analysis-passes>
2. Setting up build aliases in xla/service ensuring external dependencies are still satisfied.

PiperOrigin-RevId: 687936257
  • Loading branch information
sdasgup3 authored and tensorflower-gardener committed Oct 21, 2024
1 parent 9539c3c commit 7b84693
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 8 deletions.
6 changes: 3 additions & 3 deletions third_party/xla/xla/hlo/experimental/auto_sharding/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ cc_library(
"//xla:status_macros",
"//xla:util",
"//xla:xla_data_proto_cc",
"//xla/hlo/analysis:hlo_alias_analysis",
"//xla/hlo/ir:hlo",
"//xla/hlo/pass:hlo_pass",
"//xla/hlo/transforms:hlo_constant_splitter",
Expand All @@ -62,7 +63,6 @@ cc_library(
"//xla/service:computation_layout",
"//xla/service:dot_as_convolution_util",
"//xla/service:dump",
"//xla/service:hlo_alias_analysis",
"//xla/service:hlo_buffer",
"//xla/service:hlo_cost_analysis",
"//xla/service:hlo_value",
Expand Down Expand Up @@ -295,14 +295,14 @@ cc_library(
"//xla:shape_util",
"//xla:util",
"//xla:xla_data_proto_cc",
"//xla/hlo/analysis:while_loop_analysis",
"//xla/hlo/ir:hlo",
"//xla/hlo/ir:ptrvec",
"//xla/hlo/ir:tile_assignment",
"//xla/hlo/utils:hlo_sharding_util",
"//xla/service:call_graph",
"//xla/service:computation_layout",
"//xla/service:sharding_propagation",
"//xla/service:while_loop_analysis",
"@com_google_absl//absl/algorithm:container",
"@com_google_absl//absl/container:btree",
"@com_google_absl//absl/container:flat_hash_map",
Expand Down Expand Up @@ -382,14 +382,14 @@ xla_cc_test(
":auto_sharding_option",
":auto_sharding_strategy",
":auto_sharding_util",
"//xla/hlo/analysis:hlo_alias_analysis",
"//xla/hlo/ir:hlo",
"//xla/hlo/parser:hlo_parser",
"//xla/hlo/testlib:verified_hlo_module",
"//xla/hlo/transforms:hlo_memory_scheduler",
"//xla/hlo/utils:hlo_live_range",
"//xla/hlo/utils:hlo_matchers",
"//xla/service:buffer_value",
"//xla/service:hlo_alias_analysis",
"//xla/service:hlo_value",
"//xla/tests:hlo_test_base",
"//xla/tests:xla_internal_test_main",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ limitations under the License.
#include "absl/time/clock.h"
#include "absl/time/time.h"
#include "absl/types/span.h"
#include "xla/hlo/analysis/hlo_alias_analysis.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_cost_graph.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_device_mesh.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_memory.h"
Expand Down Expand Up @@ -78,7 +79,6 @@ limitations under the License.
#include "xla/service/call_graph.h"
#include "xla/service/computation_layout.h"
#include "xla/service/dump.h"
#include "xla/service/hlo_alias_analysis.h"
#include "xla/service/hlo_buffer.h"
#include "xla/service/hlo_cost_analysis.h"
#include "xla/service/hlo_value.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ limitations under the License.
#include "absl/status/statusor.h"
#include "absl/strings/string_view.h"
#include "absl/types/span.h"
#include "xla/hlo/analysis/hlo_alias_analysis.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_cost_graph.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_device_mesh.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_option.h"
Expand All @@ -44,7 +45,6 @@ limitations under the License.
#include "xla/hlo/pass/hlo_pass_interface.h"
#include "xla/hlo/utils/hlo_live_range.h"
#include "xla/service/call_graph.h"
#include "xla/service/hlo_alias_analysis.h"
#include "xla/service/hlo_cost_analysis.h"
#include "xla/shape.h"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ struct AutoShardingOption {
// Static estimate for iteration count of a while loop, used in the cost
// model. This estimate is used when we cannot infer an upper bound on the
// number of iterations in the loop (as implemented in
// third_party/tensorflow/compiler/xla/service/while_loop_analysis.h)
// third_party/tensorflow/compiler/xla/hlo/analysis/while_loop_analysis.h)
int64_t loop_iteration_count_estimate = 100;

// Allows the conversion of aliases to followers if their pairwise strategy
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ limitations under the License.
#include "absl/status/status.h"
#include "absl/status/statusor.h"
#include "absl/strings/string_view.h"
#include "xla/hlo/analysis/hlo_alias_analysis.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_cost_graph.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_device_mesh.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_option.h"
Expand All @@ -48,7 +49,6 @@ limitations under the License.
#include "xla/hlo/utils/hlo_live_range.h"
#include "xla/hlo/utils/hlo_matchers.h"
#include "xla/service/buffer_value.h"
#include "xla/service/hlo_alias_analysis.h"
#include "xla/service/hlo_value.h"
#include "xla/tests/hlo_test_base.h"
#include "xla/tsl/lib/core/status_test_util.h"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ limitations under the License.
#include "absl/types/span.h"
#include "json/json.h"
#include "xla/array.h"
#include "xla/hlo/analysis/while_loop_analysis.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_device_mesh.h"
#include "xla/hlo/experimental/auto_sharding/auto_sharding_strategy.h"
#include "xla/hlo/ir/hlo_computation.h"
Expand All @@ -55,7 +56,6 @@ limitations under the License.
#include "xla/service/call_graph.h"
#include "xla/service/computation_layout.h"
#include "xla/service/sharding_propagation.h"
#include "xla/service/while_loop_analysis.h"
#include "xla/shape.h"
#include "xla/shape_layout.h"
#include "xla/shape_tree.h"
Expand Down

0 comments on commit 7b84693

Please sign in to comment.