Repository navigation
[libc] Demote compiler check error to a warning - #198033
Merged
Merged
Conversation
|
@llvm/pr-subscribers-libc Author: Joseph Huber (jhuber6) ChangesSummary: 1 Files Affected:
diff --git a/libc/cmake/modules/prepare_libc_gpu_build.cmake b/libc/cmake/modules/prepare_libc_gpu_build.cmake
index 554c6c49b0435..36ab321e4994c 100644
--- a/libc/cmake/modules/prepare_libc_gpu_build.cmake
+++ b/libc/cmake/modules/prepare_libc_gpu_build.cmake
@@ -7,7 +7,7 @@ endif()
set(req_ver "${LLVM_VERSION_MAJOR}.${LLVM_VERSION_MINOR}.${LLVM_VERSION_PATCH}")
if(LLVM_VERSION_MAJOR AND NOT (CMAKE_CXX_COMPILER_ID MATCHES "[Cc]lang" AND
${CMAKE_CXX_COMPILER_VERSION} VERSION_EQUAL "${req_ver}"))
- message(FATAL_ERROR "Cannot build libc for GPU. CMake compiler "
+ message(WARNING "libc for GPU requires an up-to-date clang. CMake compiler "
"'${CMAKE_CXX_COMPILER_ID} ${CMAKE_CXX_COMPILER_VERSION}' "
" is not 'Clang ${req_ver}'.")
endif()
|
ZuseZ4
reviewed
May 15, 2026
| if(LLVM_VERSION_MAJOR AND NOT (CMAKE_CXX_COMPILER_ID MATCHES "[Cc]lang" AND | ||
| ${CMAKE_CXX_COMPILER_VERSION} VERSION_EQUAL "${req_ver}")) | ||
| message(FATAL_ERROR "Cannot build GPU device runtime. CMake compiler " | ||
| message(WARNING "libc for GPU requires an up-to-date clang. CMake compiler " |
Contributor
There was a problem hiding this comment.
That should probably be omp/offload, not libc.
Summary: This check exists to encode the policy that this is only intended to be built with a just-built compiler. In practice it's a little too strict and breaks pretty much every six months when the version bumps or when people try to build a separate patch. Just demote to a warning.
shiltian
approved these changes
May 18, 2026
pedroMVicente
pushed a commit
to pedroMVicente/llvm-project
that referenced
this pull request
May 19, 2026
Summary: This check exists to encode the policy that this is only intended to be built with a just-built compiler. In practice it's a little too strict and breaks pretty much every six months when the version bumps or when people try to build a separate patch. Just demote to a warning.
Contributor
Author
|
/cherry-pick 13da33e |
Member
|
/pull-request #199204 |
c-rhodes
pushed a commit
to llvmbot/llvm-project
that referenced
this pull request
May 26, 2026
Summary: This check exists to encode the policy that this is only intended to be built with a just-built compiler. In practice it's a little too strict and breaks pretty much every six months when the version bumps or when people try to build a separate patch. Just demote to a warning. (cherry picked from commit 13da33e)
daunabomba
pushed a commit
to daunabomba/llvm-project
that referenced
this pull request
Jun 2, 2026
Summary: This check exists to encode the policy that this is only intended to be built with a just-built compiler. In practice it's a little too strict and breaks pretty much every six months when the version bumps or when people try to build a separate patch. Just demote to a warning. (cherry picked from commit 13da33e)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
This check exists to encode the policy that this is only intended to be
built with a just-built compiler. In practice it's a little too strict
and breaks pretty much every six months when the version bumps or when
people try to build a separate patch. Just demote to a warning.