Red Hat Bugzilla – Bug 465974
[RHEL5.3][gcc-4.3] Fortran DW_TAG_common_block has incorrect placement/scope
Last modified: 2010-10-23 01:02:34 EDT
Created attachment 319648 [details]
Description of problem:
Date problem reported: 10-6-08
Problem: gcc-4.3.2 / gfortran-4.3.2 (in the forthcoming tech-preview for RHEL5.3) appears to also have the "DW_TAG_common_block has incorrect placement/scope" issues listed in the following gcc upstream bug:
What gfortran is doing currently is:
(1) Merges all common blocks into a single one.
(2) Places this single common block into the first subroutine where it was
Jan Kratochvil in BZ 459376, comment #12 noted that these issues are making it so that gcc-gfortran is incompatible with some fixes made to gdb-6.8 (see BZ 459672), which is what we'll be re-basing gdb on when RHEL5.3 ships (Jan is also the reporter of the upstream bug).
What is expected from SEG/Engineering: Need to send this up so we can track possible fixes to gcc-4.3. We need to try and squeeze this one in for RHEL5.3 as well.
Issue escalated to Support Engineering Group by: kbaxley.
kbaxley assigned to issue for LLNL (HPC).
Category set to: Devel Tools::GCC
In BZ 459376 (see comment #12):
engineering noted that there was a gcc bug in gcc-4.3.2 that's making gfortran incompatible with gdb fixes that recently went in. The BZ for the gdb issue is 459762. See comment #8 in that BZ.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
I have attached the two testcases that were used in the gcc-bugzilla, and I can reproduce this on an x86-64 system running the gfortran-4.3 tech preview packages:
Compile the test programs using something like:
gfortran43 -g -o testing2 test2.f90
gfortran43 -g -o testing test.f90
Then run readelf -w against each output file.
Created attachment 319649 [details]
I agree this is fatal enough to need a rebuild, but I'm still waiting for upstream ack on the patch.
This has been in rawhide for a few days, without problems and got even through gdb testing, so I'd like to respin gcc43 now for this.
(In reply to comment #0)
> Jan Kratochvil in BZ 459376, comment #12 noted that these issues are making it
> so that gcc-gfortran is incompatible with some fixes made to gdb-6.8 (see BZ
> 459672), which is what we'll be re-basing gdb on when RHEL5.3 ships (Jan is
> also the reporter of the upstream bug).
This support for GDB exists as a patch now but it is not present in any GDB
release (upstream/rhel/fedora/archer). It is a GDB fix/feature planned for
Still sure the GCC fix makes sense for other non-GDB debuggers.
I can also respin GDB for RHEL-5.3 with the common blocks fix from Bug 459762
but still not all of the other Fortran fixes are done+stable in GDB (all the
GCC Fortran fixes look as done already for 5.3, though).
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 therefore 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.