Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Would it be possible to get the following PPC64LE fix in GCC 8.2 of RHEL 8.1?
The bug has been fixed in master and 8.3 branches of GCC.
Copy of initial message of:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88892
---
With gcc-8.2.1-6.fc28.ppc64le, this code
void
f (double d, char *target)
{
float f = d;
__builtin_memcpy (target, &f, sizeof (f));
}
results (with -O2) in (omitting the unwinding information):
f:
stfs 1,0(4)
blr
This is incorrect because stfs rounds to zero. An frsp instruction is missing before the stfs (and would be emitted without the memcpy).
(GCC documents that the default rounding mode “is round-to-zero for all floating point to integer conversions, and round-to-nearest for all other arithmetic truncations”; see -frounding-mode.)
Found by the Python testsuite: https://bugs.python.org/issue35752
---
Links:
* GCC upstream bug (fixed!): https://gcc.gnu.org/bugzilla/show_bug.cgi?id=88892
* Python upstream bug: https://bugs.python.org/issue35752
* Python downstream bug reported in Fedora: https://bugzilla.redhat.com/show_bug.cgi?id=1540995
(In reply to Miro Hrončok from comment #3)
> Is this planned to be backported to RHEL 8.1.0?
Yes. In fact, I'm about to start the build; it should be available today.
Comment 9Alexandra Petlanová Hájková
2019-08-05 20:40:56 UTC
Hello Marek,
there might be some problem,
void
f (double d, char *target)
{
float f = d;
__builtin_memcpy (target, &f, sizeof (f));
}
still results (with -O2) in
stfs 1,0(4)
blr
for both gcc-8.3.1-4.4.el8.ppc64le and gcc-8.3.1-4.5.el8.ppc64le on power9.
I think this is fine. The original bug report says "An frsp instruction is missing before the stfs."
If I use gcc-8.2.1-3.5 (which doesn't have the fix), then compiling the testcase results in:
f:
.LFB0:
.cfi_startproc
stfs 1,0(4)
blr
whereas if I use gcc-8.3.1-4.5 (which has the fix):
f:
.LFB0:
.cfi_startproc
frsp 1,1
stfs 1,0(4)
blr
which has "frsp" before "stfs".
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://access.redhat.com/errata/RHBA-2019:3565