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
build results vary from build machine CPU #1939
Comments
|
@bmwiedemann thanks for working on the openSUSE packages! Perhaps a different |
|
I believe -mtune=generic is the recommended way to produce "code optimized for the most common CPUs at the time the version of gcc was released" |
|
|
Yes, |
|
Close the issue? |
to avoid build-time CPU detection of -mtune=native to get reproducible build results. See https://reproducible-builds.org/ for why this is good. Fixes InsightSoftwareConsortium#1939 This PR was done while working on reproducible builds for openSUSE.
to avoid build-time CPU detection of -mtune=native to get reproducible build results. See https://reproducible-builds.org/ for why this is good. Fixes InsightSoftwareConsortium#1939 This PR was done while working on reproducible builds for openSUSE.
|
-mtune=generic is the least common denominator, which means only use instructions from 20 years ago. |
It is my understanding that this is for the optimization of the instructions ( order, delay etc. ), not which instruction sets used. The |
BUG: Fix issue #1939: Use -mtune=generic
Description
While working on reproducible builds for openSUSE, I found that
our insighttoolkit package varied from the type of build machine CPU
that randomly gets chosen from the pool of build workers.
This is because
InsightToolkit-5.1.0/CMake/ITKSetStandardCompilerFlags.cmakehas-mtune=nativeand dropping this helped to make builds reproducible.
See https://reproducible-builds.org/ for why this matters.
Steps to Reproduce
Expected behavior
It should be possible to get bit-identical build results on different build machines.
May be triggered via a cmake flag or the
SOURCE_DATE_EPOCHenvironment variableActual behavior
build results vary from build machine CPU
Reproducibility
100%
Versions
5.1
Environment
openSUSE-Tumbleweed-20200728
Additional Information
This PR was done while working on reproducible builds for openSUSE.
The text was updated successfully, but these errors were encountered: