This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

PATCH: [4.0/4.1 Regression] debug info omitted for uninitialized variables


On Tue, Jul 05, 2005 at 08:43:22AM +0200, Jan Hubicka wrote:
> 
> > to fix a serious 4.0/4.1 regression:
> > 
> > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21828
> > 
> > where debug info is omitted for uninitialized variables. It seems that
> > check_global_declarations does the wrong thing on uninitialized
> > variables.
> 
> Hmm, there are quite few nasty bits here.  I think you are right in the
> bug audit trail that check_global_declarations should be reordred after
> cgraph finalization as it checks TREE_ASM_WRITTEN flag that is clearly
> not set in a way it expects.
> 

There are 2 patches here, one for mainline and the other for gcc 4.0.
But I am afraid that the patch for mainline may be time consuming. Also
I am not sure if it handles "BLOCK_VARS (ext_block)" correctly. On
Linux/x86-64, BLOCK_VARS (ext_block) changes after cgraph_optimize. I
have to do "ext_block_vars = BLOCK_VARS (ext_block)" before calling
cgraph_optimize. Otherwise, I got a bad pointer.


H.J.

Attachment: gcc-common-4.patch
Description: Text document

Attachment: gcc-4.0-common-3.patch
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]