Details
-
Bug
-
Resolution: Fixed
-
Minor
-
None
-
None
-
Clang 15.0.6
-
3
-
9223372036854775807
Description
I've been experimenting with using Clang 15.0.6 to compile Lustre. The compiler runs into a number of build issues. Clang seems to be stricter than GCC in a few cases. Lustre can still be compiled by disabling the errors [1], but a first glance the errors seem legitimate. I'm making this ticket because I have a patch to fix some of the failures.
It seems like some Clang-based static analyzers were used in the past [2], although I'm not sure if compiling Lustre with Clang is super common. I think it could be useful to have Clang as an option for development purposes, along the lines of ClangBuiltLinux [3]. It's seems like some kind of plugin [4] was developed at some point. It would be for an old (3.0) Clang, but it could be interesting to look at.
[1] Errors that needed to be disabled:
-Wno-error=enum-conversion -Wno-error=unused-but-set-variable -Wno-error=uninitialized -Wno-error=format -Wno-error=strncat-size -Wno-error=switch -Wno-error=strlcpy-strlcat-size -Wno-error=unneeded-internal-declaration -Wno-error=self-assign -Wno-error=tautological-constant-out-of-range-compare -Wno-error=constant-logical-operand -Wno-error=pointer-bool-conversion -Wno-error=unused-function -Wno-error=parentheses-equality -Wno-error=deprecated-non-prototype
[2] Old Clang tickets:
https://jira.whamcloud.com/browse/LU-871
https://jira.whamcloud.com/browse/LU-2675
[3] Clang/Linux: https://clangbuiltlinux.github.io/
[4] Plugin: https://wiki.whamcloud.com/pages/viewpage.action?pageId=18645101
Attachments
Issue Links
- is related to
-
LU-16961 Clang plugin build system integration
- Resolved