LLVM now requires C++14. For IBM XL compilers with C++14 support, this can be done with the GCC-style options. The relevant block in the CMake file is split up into smaller parts as part of this patch to allow the common cases to be shared.
Details
Diff Detail
- Repository
- rL LLVM
- Build Status
Buildable 36797 Build 36796: arc lint + arc unit
Event Timeline
Can XL enable all the same flags which GCC can? There's a lot under that elseif! At that point, isn't XL GCC compatible?
It can except the modules stuff, which should would be detected via the CHECK_CXX_SOURCE_COMPILES.
There's a lot under that elseif!
Most of it is the modules stuff.
At that point, isn't XL GCC compatible?
It isn't, because the object-file generation options (e.g., -fno-unwind-tables) differ.
I guess I should say "default warning" options in the commit message, because the LLVM_ENABLE_WARNINGS and LLVM_ENABLE_PEDANTIC modes aren't enabled with this patch.
I'm worried because this entire section is for "GCC compatible command line stuff". If someone added something new in there, would it inadvertently break XL? Maybe it's better to factor out the bits you want to enable and leave the rest separate from XL?
llvm/trunk/cmake/modules/HandleLLVMOptions.cmake | ||
---|---|---|
435 ↗ | (On Diff #215482) | I'm not sure you needed to wrap everything in this else now, since everything inside is now guarded on LLVM_COMPILER_IS_GCC_COMPATIBLE and if (MSVC) LLVM_COMPILER_IS_GCC_COMPATIBLE=OFF |