3 ms·
Can someone provide a brief clarification about build reproducibility in general? The stated aim is that when you compile the same source, environment, and ins
by trod1234 2y ago
Can someone provide a brief clarification about build reproducibility in general?
The stated aim is that when you compile the same source, environment, and instructions the end result is bit identical.
There is, however; hardware specific optimizations that will naturally negate this stated aim, and I don't see how there's any way to avoid throwing out the baby with the bathwater.
I understand why having a reproducible build is needed on a lot of fronts, but the stated requirements don't seem to be in line with the realities.
At its most basic, there is hardware, where the hardware may advertise features it doesn't have, or doesn't perform the same instructions in the same way, and other nuances that break determinism as a property, and that naturally taints the entire stack since computers rely heavily on emergent design.
This is often hidden in layers of abstraction and/or may be separated into pieces that are architecture dependent vs independent (freestanding), but it remains there.
Most if not all of the beneficial properties of reproducible builds rely on the environment being limited to a deterministic scope, and the reality is manufacturers ensure these things remain in a stochastic scope.
- amarshall 2y agoWell the point is that if N of M machines produce the same output, it provides the opportunity to question why it is different on the others. If the build is not reproducible then one just throws up their arms. It’s not clear if you’re also talking about compiler optimizations—a reproducible build must have a fixed target for that.
- trod1234 2y agoI was thinking more from a reference point along the lines of LLVM type performance optimizations when I was speaking about optimizations, if that sufficiently clarifies.
- Crestwave 2y ago> hardware specific optimizations that will naturally negate this stated aim Distro packages are compiled on their build server and distributed to users with all kinds of systems; therefore, by nature, it should not use optimizations specific to the builder's hardware. On source-based distros like Gentoo, yes, users adding optimization flags would get a different output. But there is still value in having the same hardware/compilation flags result in the same output.
- dmtfullstack 2y ago> There is, however; hardware specific optimizations that will naturally negate this stated aim These are considered to be different build artifacts, which are also reproducible.