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]

Re: PATCH: [4.0/4.1 Regression] debug info omitted for uninitializedvariables


H. J. Lu wrote:
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.

You should read my comments in the PR. I believe this is compounding the original mistake in Mark Mitchell's patch for PR 18556. I think the proper fix is to find a different solution for PR 18556, by fixing the debug output files instead of the middle end. I haven't yet tried to reproduce PR 18556.


Also, I pointed out in the PR that cgraph_optimize does a garbage collect, and ext_block is an unregistered root. This explains some of the behaviour you are seeing with bad pointers.
--
Jim Wilson, GNU Tools Support, http://www.specifix.com



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