Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[XLA:CPU] Enable XLA on Windows #11299

Closed
wants to merge 12 commits into from

Conversation

mraunak
Copy link
Contributor

@mraunak mraunak commented Apr 8, 2024

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

  1. Changed the .bazelrc file to use the correct toolchain and platform
    This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

  2. Added conditions to a few test cases to successfully run on the Windows platform
    These test cases check the exit/termination status of a process
    WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform

@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 8, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 8, 2024
Copy link
Member

@penpornk penpornk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR!

@@ -58,8 +58,13 @@ TEST(InteractiveGraphviz, CPU) {

int status = proc.Communicate(&in, &out, &err);
EXPECT_TRUE(WIFEXITED(status));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since WIFEXITED doesn't exist on Windows, please move it inside #else as well. Same for other places.

Comment on lines 62 to 63
EXPECT_TRUE(status==0);
EXPECT_EQ(0, status);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Both of these are equivalent. Maybe remove EXPECT_TRUE?

xla/tools/interactive_graphviz_bin_test.cc Outdated Show resolved Hide resolved
xla/tools/run_hlo_module_bin_test.cc Outdated Show resolved Hide resolved
.bazelrc Outdated
Comment on lines 440 to 441
build:win_clang --extra_execution_platforms=//tools/toolchains/win:x64_windows-clang-cl
build:win_clang --host_platform=//tools/toolchains/win:x64_windows-clang-cl
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ddunl Could you please help take a look if these .bazelrc changes are okay?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! :)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

On second thought I realized that because we still use TF's bazelrc, we may need to have these under a new config like win_clang_xla. Does that sound ok?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @ddunl, got your point. I will create a pull request to TF and update TF's .bazelrc with win_clang_xla config and revert the changes (back to build:win_clang --extra_execution_platforms=//tensorflow/tools/toolchains/win:x64_windows-clang-cl
) in XLA bazelrc. How often TF bazelrc is merged to XLA bazelrc? Do you have any documentation for XLA where we can update the steps to run XLA on Windows?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can merge the TF change with this change on our end, I just wanted to make sure that we can use a different config for XLA. I think right now we unfortunately just have to have an extra copy like win_clang_xla that has all the same options but just the correct toolchain paths for this repo. If that sounds reasonable then I can do that change with this PR internally.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, that sounds good. Please go ahead and create win_clang_xla with this PR internally

@penpornk penpornk requested a review from ddunl April 8, 2024 10:01
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 10, 2024
Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 10, 2024
mraunak and others added 2 commits April 10, 2024 16:38
Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 10, 2024
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 11, 2024
@mraunak
Copy link
Contributor Author

mraunak commented Apr 12, 2024

Hi @penpornk please review the PR, I have made the changes

Copy link
Member

@penpornk penpornk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the changes!

copybara-service bot pushed a commit to tensorflow/tensorflow that referenced this pull request Apr 12, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

FUTURE_COPYBARA_INTEGRATE_REVIEW=openxla/xla#11299 from Intel-tensorflow:mraunak/xla_windows f9af75677e4663b3348e9e89376262eaff389ea9
PiperOrigin-RevId: 624293815
copybara-service bot pushed a commit to tensorflow/tensorflow that referenced this pull request Apr 16, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

Reverts 94350b8

FUTURE_COPYBARA_INTEGRATE_REVIEW=openxla/xla#11299 from Intel-tensorflow:mraunak/xla_windows f9af75677e4663b3348e9e89376262eaff389ea9
PiperOrigin-RevId: 624293815
@github-actions github-actions bot added the kokoro:force-run Forces CI to rerun label Apr 17, 2024
@kokoro-team kokoro-team removed the kokoro:force-run Forces CI to rerun label Apr 17, 2024
@mraunak
Copy link
Contributor Author

mraunak commented Apr 17, 2024

Thank you @penpornk and @ddunl for the review

copybara-service bot pushed a commit to google/tsl that referenced this pull request Apr 19, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

FUTURE_COPYBARA_INTEGRATE_REVIEW=openxla/xla#11299 from Intel-tensorflow:mraunak/xla_windows f9af75677e4663b3348e9e89376262eaff389ea9
PiperOrigin-RevId: 625468098
copybara-service bot pushed a commit that referenced this pull request Apr 19, 2024
Imported from GitHub PR #11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eef by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c032 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb686 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af756 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

FUTURE_COPYBARA_INTEGRATE_REVIEW=#11299 from Intel-tensorflow:mraunak/xla_windows f9af756
PiperOrigin-RevId: 625468098
copybara-service bot pushed a commit to tensorflow/tensorflow that referenced this pull request Apr 19, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

FUTURE_COPYBARA_INTEGRATE_REVIEW=openxla/xla#11299 from Intel-tensorflow:mraunak/xla_windows f9af75677e4663b3348e9e89376262eaff389ea9
PiperOrigin-RevId: 625468098
copybara-service bot pushed a commit to google/tsl that referenced this pull request Apr 23, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

FUTURE_COPYBARA_INTEGRATE_REVIEW=openxla/xla#11299 from Intel-tensorflow:mraunak/xla_windows f9af75677e4663b3348e9e89376262eaff389ea9
PiperOrigin-RevId: 625468098
copybara-service bot pushed a commit that referenced this pull request Apr 23, 2024
Imported from GitHub PR #11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eef by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c032 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb686 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af756 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

FUTURE_COPYBARA_INTEGRATE_REVIEW=#11299 from Intel-tensorflow:mraunak/xla_windows f9af756
PiperOrigin-RevId: 625468098
copybara-service bot pushed a commit to google/tsl that referenced this pull request Apr 23, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

PiperOrigin-RevId: 627216606
copybara-service bot pushed a commit to tensorflow/tensorflow that referenced this pull request Apr 23, 2024
Imported from GitHub PR openxla/xla#11299

This PR aims to enable the XLA test cases on the Windows Platform. The changes made:

1. Changed the .bazelrc file to use the correct toolchain and platform
This change will allow the user to successfully run XLA tests on the Windows platform using the Clang compiler using '--config=win_clang' in the bazel command

2. Added conditions to a few test cases to successfully run on the Windows platform
These test cases check the exit/termination status of a process
WIFEXITED is typically supported in POSIX-compliant operating systems like Unix and Linux to check if a process has terminated normally. WEXITSTATUS allows examining the termination status of child processes. However, these macros are not Windows compliant, hence the additional condition block was added to check the exit/termination status of process or child process for the Windows platform
Copybara import of the project:

--
ece9eefa224a6d051bcac089fe2a9a393af16a2b by Raunak <mayank.kumar.raunak@intel.com>:

Enable XLA Windows

--
347c0326af8f608047f06345cad4dfbb53a52150 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
2d4a3c2bb2ea23f12029583c53087d8739da0319 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/interactive_graphviz_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
90ad8b2730900d7f82b0fb1a83a73ffa2e452e0e by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc
--
7f31412f6b57e53bd56ba92149b015fcba92b07c by mraunak <83710963+mraunak@users.noreply.github.com>:

Update xla/tools/run_hlo_module_bin_test.cc

Co-authored-by: Penporn Koanantakool <38085909+penpornk@users.noreply.github.com>
--
4d39e35461f6977f36404a435c68b4809fb51a44 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
816b9ae0498831b55139c72d627d07f05e51213b by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
a728fff1aca4258602c3d7c78afcc7d38b545b7a by mraunak <83710963+mraunak@users.noreply.github.com>:

Update hlo_expand_test.cc
--
ffcb6861becf8de7a5c4e64ef0f19d977475d281 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f181497793c2c48079d72b545e6efb837f490504 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update interactive_graphviz_bin_test.cc
--
f9af75677e4663b3348e9e89376262eaff389ea9 by mraunak <83710963+mraunak@users.noreply.github.com>:

Update run_hlo_module_bin_test.cc

Merging this change closes #11299

PiperOrigin-RevId: 627216606
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants