-
Notifications
You must be signed in to change notification settings - Fork 12k
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
Error when compiling with GCC 7 #63843
Comments
@llvm/issue-subscribers-mlir |
@steakhal can you please take a look? |
@Diana-Dubov I left a comment in the revision, this is the most usual way to signal that something is broken. |
I'll look at this on the weekend. |
Here is a partial revert "fix" for the build, by removing the SFINAE constraint and putting back the TODO which was originally there. |
Why not just |
Please reply to the patch. I don't usually monitor Github notifications.
Accommodated the patch according to this. |
It turns out the SFINAE constraint breaks building MLIR using GCC-7, which is an outdated, but supported compiler by llvm-project. I tried to find a solution for fixing it, but I decided to cut branches and just simply remove the SFINAE constraint until we drop GCC-7. It was originally introduced by D152891. Allegedly, GCC-8 and above builds just fine. I tested GCC 8.4.0, and GCC 7.5.0, and now builds fine on both. Differential Revision: https://reviews.llvm.org/D155441 Fixes llvm#63843
Not for this specific instance, but in general I suspect that 7.4 may not be good enough to build llvm-project, and we may require 7.5. |
However, the issue still exists in the KylinV10 system.My gcc version is gcc8.3.0. |
However, the issue still exists in the KylinV10 system.My gcc version is gcc8.3.0. |
Do you imply that we should check |
We have a gcc 7.5 bot here FYI: https://lab.llvm.org/buildbot/#/builders/264 |
Thanks Mehdi! Then it seems like it should build on that version of gcc ( |
My operating system is KylinV10, and my GCC version is 8.5.0. I hope to successfully compile LLVM. |
Please file another bug with detailed instruction on your environment, the sequence of commands you ran, and join the detailed log that lead to the error. |
@joker-eph /home/dongshuai/test/llvm-project/llvm/include/llvm/ADT/iterator_range.h:33:26: error: no matching function for call to ‘llvm::detail::indexed_accessor_range_base<mlir::ValueRange, llvm::PointerUnion<const mlir::Value*, mlir::OpOperand*, mlir::detail::OpResultImpl*>, mlir::Value, mlir::Value, mlir::Value>::iterator::iterator(llvm::detail::indexed_accessor_range_base<mlir::ResultRange, mlir::detail::OpResultImpl*, mlir::OpResult, mlir::OpResult, mlir::OpResult>::iterator)’ |
@loongknown : as instructed above, please open another bug. This bug is closed, and you have a slightly different issue. (also please include the CMake configuration log, and add these logs as textual file attachment instead of plain text in the description). |
Have you tested on GCC 8.3.0? Even after applying this patch, I'm still getting compilation errors. The error message is as follows: /home/dongshuai/test/llvm-project/mlir/lib/Transforms/Utils/CFGToSCF.cpp: In function ‘mlir::FailureOr<llvm::SmallVectormlir::Block* > transformToStructuredCFBranches(mlir::Block*, mlir::function_ref<mlir::Value(unsigned int)>, mlir::function_refmlir::Value(mlir::Type), mlir::CFGToSCFInterface&, mlir::DominanceInfo&)’: |
It turns out the SFINAE constraint breaks building MLIR using GCC-7, which is an outdated, but supported compiler by llvm-project. I tried to find a solution for fixing it, but I decided to cut branches and just simply remove the SFINAE constraint until we drop GCC-7. It was originally introduced by D152891. Allegedly, GCC-8 and above builds just fine. I tested GCC 8.4.0, and GCC 7.5.0, and now builds fine on both. Differential Revision: https://reviews.llvm.org/D155441 Fixes llvm/llvm-project#63843
According to llvm documentation it shall [support GCC 7] (https://llvm.org/docs/GettingStarted.html#host-c-toolchain-both-compiler-and-standard-library).
This commit: [ADT] Add deduction guide for iterator_range breaks it.
Getting this error when compiling with GCC7.4:
It is fixed in GCC8 and later, but the issue at GCC7 exists and breaks the promise to support this version.
Thank you
The text was updated successfully, but these errors were encountered: