Bug 141694 (IT_54408)
Summary: | compiler optimization causes build failure with perl-5.8.5-12 | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 3 | Reporter: | David Lehman <dlehman> | ||||
Component: | gcc | Assignee: | Jakub Jelinek <jakub> | ||||
Status: | CLOSED ERRATA | QA Contact: | |||||
Severity: | medium | Docs Contact: | |||||
Priority: | medium | ||||||
Version: | 3.0 | CC: | jrfuller, tao | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | ia64 | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2005-05-18 13:42:35 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
David Lehman
2004-12-02 23:25:40 UTC
It builds with -O2 -fno-delete-null-pointer-checks for those 3 files, but doesn't with -O2. In pp_hot.c the function that matters seems to be Perl_pp_entersub. Will debug what's going on... Simplified testcase that works with -O1 -or -O2 -fno-delete-null-pointer-checks, but doesn't with -O2: extern void abort (void); extern void exit (int); struct S { void *a; unsigned int b; }; void __attribute__((noinline)) bar (struct S *x) { if (x->b != 2) abort (); } void __attribute__((noinline)) foo (struct S *x) { if (! x->a) { struct S *y, *z; y = x; if (y) ++y->b; z = x; if (z) ++z->b; bar (x); } } int main (void) { struct S s = { 0, 0 }; foo (&s); exit (0); } Created attachment 108995 [details]
Backported PR rtl-optimization/14279 fix that seems to fix this.
Fix for this has been added to gcc-3.2.3-50, for the time being available from: ftp://people.redhat.com/jakub/gcc/3.2.3-50/ An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on the solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2005-258.html |