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] Fix bincls


My recent stabs improvement exposed one hidden bug which was there
before I started adding my stabs improvements. After I applied my last patch,
it now causes dejagnu test failures in PCH tests.


GCC emits BINCL stab for main input file which is not required. And on
top of that it does not emit matching EINCL. It is nice that ld does not
freak out when it sees mismatched BINCL/EINCL pair while removing
duplicate BINCL/EINCL pairs. This patch removes extra BINCL.

I see special check for is_main_source file in dwarf2out_start_source_file,
so I would like to get opinion of someone familiar with DWARF.


I did following testing with this patch.

1) Bootstrapped on powerpc-apple-darwin6.4
2) Built on i686-pc-linux-gnu
3) Tested GCC dejagnu test suite on i686-pc-linux-gnu and powerpc-apple-darwin6.4.
In both cases it fixes PCH test failures.
4) I also tested GDB dejagnu test suite on i686-pc-linux-gnu using dwarf and stabs.
4.1) Using dwarf it does not reveal any new regressions
4.2) Using stabs it fixes 7 test failures
4.3) Using stabs with -feliminate-unused-debug-symbols it fixes 7 test failures


OK to commit ?
Thank you,
-Devang


2003-07-03 Devang Patel <dpatel@apple.com>


* c-opts (c_common_parse_file): Remove debug_hooks->start_source_file call.

Index: c-opts.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/c-opts.c,v
retrieving revision 1.65
diff -Idpatel.pbxuser -c -3 -p -r1.65 c-opts.c
*** c-opts.c    30 Jun 2003 19:36:20 -0000      1.65
--- c-opts.c    3 Jul 2003 18:46:06 -0000
*************** c_common_parse_file (int set_yydebug ATT
*** 1183,1189 ****
    warning ("YYDEBUG not defined");
  #endif

-   (*debug_hooks->start_source_file) (input_line, input_filename);
    finish_options();
    pch_init();
    yyparse ();
--- 1183,1188 ----


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