mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-02 05:50:26 +08:00
dbxout.c (dbxout_begin_prologue): New function.
* dbxout.c (dbxout_begin_prologue): New function. (dbx_debug_hooks): Use new begin prologue hook. (dbxout_function_end): Emit N_ENSYM. * stab.def (N_BNSYM, N_ENSYM): Define and document these two new stabs. testsuite: gcc.dg/darwin-20040809-2.c: New test. From-SVN: r85908
This commit is contained in:
parent
950a175b04
commit
8fa5469d38
@ -1,3 +1,10 @@
|
||||
2004-08-12 Devang patel <dpatel@apple.com>
|
||||
|
||||
* dbxout.c (dbxout_begin_prologue): New function.
|
||||
(dbx_debug_hooks): Use new begin prologue hook.
|
||||
(dbxout_function_end): Emit N_ENSYM.
|
||||
* stab.def (N_BNSYM, N_ENSYM): Define and document these two new stabs.
|
||||
|
||||
2004-08-12 Janis Johnson <janis187@us.ibm.com>
|
||||
|
||||
* config/rs6000/altivec.h (vec_dst): Fix C++ functions whose first
|
||||
|
18
gcc/dbxout.c
18
gcc/dbxout.c
@ -372,6 +372,7 @@ static void dbxout_handle_pch (unsigned);
|
||||
#if defined (DBX_DEBUGGING_INFO)
|
||||
|
||||
static void dbxout_source_line (unsigned int, const char *);
|
||||
static void dbxout_begin_prologue (unsigned int, const char *);
|
||||
static void dbxout_source_file (FILE *, const char *);
|
||||
static void dbxout_function_end (void);
|
||||
static void dbxout_begin_function (tree);
|
||||
@ -391,8 +392,7 @@ const struct gcc_debug_hooks dbx_debug_hooks =
|
||||
dbxout_end_block,
|
||||
debug_true_tree, /* ignore_block */
|
||||
dbxout_source_line, /* source_line */
|
||||
dbxout_source_line, /* begin_prologue: just output
|
||||
line info */
|
||||
dbxout_begin_prologue, /* begin_prologue */
|
||||
debug_nothing_int_charstar, /* end_prologue */
|
||||
debug_nothing_int_charstar, /* end_epilogue */
|
||||
#ifdef DBX_FUNCTION_FIRST
|
||||
@ -481,6 +481,9 @@ dbxout_function_end (void)
|
||||
assemble_name (asmfile, XSTR (XEXP (DECL_RTL (current_function_decl), 0), 0));
|
||||
fprintf (asmfile, "\n");
|
||||
#endif
|
||||
|
||||
if (!flag_debug_only_used_symbols)
|
||||
fprintf (asmfile, "%s%d,0,0\n", ASM_STABD_OP, N_ENSYM);
|
||||
}
|
||||
#endif /* DBX_DEBUGGING_INFO */
|
||||
|
||||
@ -753,6 +756,17 @@ dbxout_source_file (FILE *file, const char *filename)
|
||||
}
|
||||
}
|
||||
|
||||
/* Output N_BNSYM and line number symbol entry. */
|
||||
|
||||
static void
|
||||
dbxout_begin_prologue (unsigned int lineno, const char *filename)
|
||||
{
|
||||
if (!flag_debug_only_used_symbols)
|
||||
fprintf (asmfile, "%s%d,0,0\n", ASM_STABD_OP, N_BNSYM);
|
||||
|
||||
dbxout_source_line (lineno, filename);
|
||||
}
|
||||
|
||||
/* Output a line number symbol entry for source file FILENAME and line
|
||||
number LINENO. */
|
||||
|
||||
|
10
gcc/stab.def
10
gcc/stab.def
@ -39,6 +39,12 @@ __define_stab (N_STSYM, 0x26, "STSYM")
|
||||
/* BSS-segment variable with internal linkage. Value is its address. */
|
||||
__define_stab (N_LCSYM, 0x28, "LCSYM")
|
||||
|
||||
/* Begin function marker. */
|
||||
__define_stab (N_BNSYM, 0x2e, "BNSYM")
|
||||
|
||||
/* End function marker. */
|
||||
__define_stab (N_ENSYM, 0x4e, "ENSYM")
|
||||
|
||||
/* Name of main routine. Only the name is significant.
|
||||
This is not used in C. */
|
||||
__define_stab (N_MAIN, 0x2a, "MAIN")
|
||||
@ -201,11 +207,11 @@ __define_stab (N_LENG, 0xfe, "LENG")
|
||||
|_______________________________________________|
|
||||
| Debug entries with bit 01 set are unused. |
|
||||
| 20 GSYM | 22 FNAME | 24 FUN | 26 STSYM |
|
||||
| 28 LCSYM | 2A MAIN | 2C | 2E |
|
||||
| 28 LCSYM | 2A MAIN | 2C | 2E BNSYM |
|
||||
| 30 PC | 32 NSYMS | 34 NOMAP | 36 |
|
||||
| 38 OBJ | 3A | 3C OPT | 3E |
|
||||
| 40 RSYM | 42 M2C | 44 SLINE | 46 DSLINE |
|
||||
| 48 BSLINE*| 4A DEFD | 4C | 4E |
|
||||
| 48 BSLINE*| 4A DEFD | 4C | 4E ENSYM |
|
||||
| 50 EHDECL*| 52 | 54 CATCH | 56 |
|
||||
| 58 | 5A | 5C | 5E |
|
||||
| 60 SSYM | 62 | 64 SO | 66 |
|
||||
|
@ -1,3 +1,7 @@
|
||||
2004-08-12 Devang patel <dpatel@apple.com>
|
||||
|
||||
* gcc.dg/darwin-20040809-2.c: New test.
|
||||
|
||||
2004-08-12 Janis Johnson <janis1872us.ibm.com>
|
||||
|
||||
* g++.dg/ext/altivec-12.C: New test.
|
||||
|
15
gcc/testsuite/gcc.dg/darwin-20040809-2.c
Normal file
15
gcc/testsuite/gcc.dg/darwin-20040809-2.c
Normal file
@ -0,0 +1,15 @@
|
||||
/* Test dead code strip support. */
|
||||
/* Contributed by Devang Patel <dpatel@apple.com> */
|
||||
|
||||
/* { dg-do compile { target *-*-darwin* } } */
|
||||
/* { dg-options "-g -fno-eliminate-unused-debug-symbols" } */
|
||||
|
||||
int
|
||||
main ()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
/* { dg-final { scan-assembler ".stabd.46,0,0" } } */
|
||||
/* { dg-final { scan-assembler ".stabd.78,0,0" } } */
|
||||
|
Loading…
x
Reference in New Issue
Block a user