-
Notifications
You must be signed in to change notification settings - Fork 15.1k
[CI] Update Windows premerge testing to use clang-cl.exe #164900
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
Conversation
Now that the Windows container contains clang, use it for building the premerge tests. Measurements show this is significantly faster than using msvc cl. Note we had to disable two warnings -Wc++98-compat and -Wc++14-compat, to make this work with 'check-mlir' on Windows (clang generates a lot of warnings that msvc cl does not).
|
@llvm/pr-subscribers-infrastructure Author: None (cmtice) ChangesNow that the Windows container contains clang, use it for building the premerge tests. Measurements show this is significantly faster than using msvc cl. Note we had to disable two warnings -Wc++98-compat and -Wc++14-compat, to make this work with 'check-mlir' on Windows (clang generates a lot of warnings that msvc cl does not). Full diff: https://github.com/llvm/llvm-project/pull/164900.diff 1 Files Affected:
diff --git a/.ci/monolithic-windows.sh b/.ci/monolithic-windows.sh
index 219979dd3e36e..89d608d9eb9b7 100755
--- a/.ci/monolithic-windows.sh
+++ b/.ci/monolithic-windows.sh
@@ -23,8 +23,8 @@ runtimes_targets="${4}"
start-group "CMake"
pip install -q -r "${MONOREPO_ROOT}"/.ci/all_requirements.txt
-export CC=cl
-export CXX=cl
+export CC=C:\clang\clang-msvc\bin\clang-cl.exe
+export CXX=C:\clang\clang-msvc\bin\clang-cl.exe
export LD=link
# The CMAKE_*_LINKER_FLAGS to disable the manifest come from research
@@ -49,10 +49,12 @@ cmake -S "${MONOREPO_ROOT}"/llvm -B "${BUILD_DIR}" \
-D CMAKE_EXE_LINKER_FLAGS="/MANIFEST:NO" \
-D CMAKE_MODULE_LINKER_FLAGS="/MANIFEST:NO" \
-D CMAKE_SHARED_LINKER_FLAGS="/MANIFEST:NO" \
+ -D CMAKE_CXX_FLAGS="-Wno-c++98-compat -Wno-c++14-compat" \
-D LLVM_ENABLE_RUNTIMES="${runtimes}"
start-group "ninja"
+
# Targets are not escaped as they are passed as separate arguments.
ninja -C "${BUILD_DIR}" -k 0 ${targets} |& tee ninja.log
cp ${BUILD_DIR}/.ninja_log ninja.ninja_log
|
|
You'll need to relaunch this job to get testing once https://github.com/llvm/llvm-project/actions/runs/18761757077/job/53527832407 finishes uploading the new image. |
Done. |
boomanaiden154
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we also pass -Wno-unsafe-buffer-usage and -Wno-old-style-cast? I'm seeing about 10k instances of each in the logs.
Can you also file a Github issue to track the warning cleanup?
boomanaiden154
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Other than that, LGTM. <60 minutes total for a cold build is pretty sweet.
Done.
Done: #165045 |
Now that the Windows container contains clang, use it for building the premerge tests. Measurements show this is significantly faster than using msvc cl. Note we had to disable four warnings -Wc++98-compat, -Wc++14-compat, -Wunsafe-buffer-usage, and -Wold-style-cast to make this work with 'check-mlir' on Windows (clang generates a lot of warnings that msvc cl does not).
Now that the Windows container contains clang, use it for building the premerge tests. Measurements show this is significantly faster than using msvc cl. Note we had to disable four warnings -Wc++98-compat, -Wc++14-compat, -Wunsafe-buffer-usage, and -Wold-style-cast to make this work with 'check-mlir' on Windows (clang generates a lot of warnings that msvc cl does not).
Now that the Windows container contains clang, use it for building the premerge tests. Measurements show this is significantly faster than using msvc cl. Note we had to disable four warnings -Wc++98-compat, -Wc++14-compat, -Wunsafe-buffer-usage, and -Wold-style-cast to make this work with 'check-mlir' on Windows (clang generates a lot of warnings that msvc cl does not).
Now that the Windows container contains clang, use it for building the premerge tests. Measurements show this is significantly faster than using msvc cl. Note we had to disable two warnings -Wc++98-compat and -Wc++14-compat, to make this work with 'check-mlir' on Windows (clang generates a lot of warnings that msvc cl does not).