-
Notifications
You must be signed in to change notification settings - Fork 26
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
Disable interprocedural optimization for VTR #272
Conversation
@mithro the binaries from VTR package are needed in yosys-f4pga-plugins. LTO is enabled by default and creates issues when linking with other projects. |
Do you have more information about the LTO issues? |
As an example when linking yosys-f4pga-plugins with the binaries from VTR package (litex-hub) the following error pops out:
Perhaps the problem is from the compiler versions. I think the best solution is to disable LTO for VTR package and according to the VTR documentation, it only improves the performance and disabling should cause no harm. |
Also, when the VTR binaries are built on the same machine that the linking is being performed later, there are no issues since the compilers are of the exact same version (and the system architectures are the same) . I'm no expert but AFAIK LTO depends on the compiler version and system architecture. |
@mithro Do we need any changes? |
@poname - I think the error points out there is something going wrong with the compiler toolchain being used. The fix is to understand that problem rather than disabling LTO. |
@mithro I am usin the default compiler toolchain in yosys-f4pga-plugins build and I think resolvig the LTO version issue requires changing the compiler there, which is unlikely to be accepted. Instead of changing the main |
@poname - I'm pretty sure the |
from the while the I am closing this PR to keep other packages intact and a new PR will be added to introduce a new package named |
@poname - If these are building against |
@mithro Yes,the Since playing with build flags would solve the problem, if it is OK from your side we can have a new mini package of vtr binaries and use it without touching anything else. |
@poname - I think we need to chat with |
@poname - Can you point out where you think they are not using the conda compilers? |
@mithro check here: https://github.com/chipsalliance/yosys-f4pga-plugins/blob/main/.github/workflows/ci.yml they are using
|
By default the
CMAKE_INTERPROCEDURAL_OPTIMIZATION
flag is on for VTR, this may causeLTO
version incompatibility when using the binaries out ofVTR
scope in other projects.Thir PR disables
INTERPROCEDURAL_OPTIMIZATION
forVTR
package while installing by turning off theVTR_IPO_BUILD
flag in the build script.