[Bug 276961] buildworld artifacts not reproducible between native and cross build
Date: Wed, 31 Jul 2024 07:31:02 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=276961
--- Comment #19 from commit-hook@FreeBSD.org ---
A commit in branch stable/14 references this bug:
URL:
https://cgit.FreeBSD.org/src/commit/?id=96ff33484ee5f44bc3ac743ce235d23495465904
commit 96ff33484ee5f44bc3ac743ce235d23495465904
Author: Dimitry Andric <dim@FreeBSD.org>
AuthorDate: 2024-07-28 11:13:37 +0000
Commit: Dimitry Andric <dim@FreeBSD.org>
CommitDate: 2024-07-31 07:29:47 +0000
Merge commit c80c09f3e380 from llvm-project (by Dimitry Andric):
[CalcSpillWeights] Avoid x87 excess precision influencing weight result
Fixes #99396
The result of `VirtRegAuxInfo::weightCalcHelper` can be influenced by
x87 excess precision, which can result in slightly different register
choices when the compiler is hosted on x86_64 or i386. This leads to
different object file output when cross-compiling to i386, or native.
Similar to 7af3432e22b0, we need to add a `volatile` qualifier to the
local `Weight` variable to force it onto the stack, and avoid the excess
precision. Define `stack_float_t` in `MathExtras.h` for this purpose,
and use it.
This is the version of the fix for PR276961 that landed upstream.
PR: 276961
Reported by: cperciva
MFC after: 3 days
(cherry picked from commit 1a4b8325f6e3a45c77188343da504fe04495cc46)
contrib/llvm-project/llvm/include/llvm/Support/MathExtras.h | 8 ++++++++
contrib/llvm-project/llvm/lib/CodeGen/CalcSpillWeights.cpp | 11 ++++++-----
2 files changed, 14 insertions(+), 5 deletions(-)
--
You are receiving this mail because:
You are the assignee for the bug.