summaryrefslogtreecommitdiffstats
path: root/gcc/dbxout.c
diff options
context:
space:
mode:
authordpatel <dpatel@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-12 21:32:56 +0000
committerdpatel <dpatel@138bc75d-0d04-0410-961f-82ee72b054a4>2004-08-12 21:32:56 +0000
commit4ec929165e715d09b04b260c16fd58b7f3ccc1dc (patch)
tree85c5760826de54f9a125455e8e36d8ebb96299eb /gcc/dbxout.c
parentdfca499a8fd96b41f52b648ceec82f0710eeb2bd (diff)
downloadppe42-gcc-4ec929165e715d09b04b260c16fd58b7f3ccc1dc.tar.gz
ppe42-gcc-4ec929165e715d09b04b260c16fd58b7f3ccc1dc.zip
* 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. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@85908 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/dbxout.c')
-rw-r--r--gcc/dbxout.c18
1 files changed, 16 insertions, 2 deletions
diff --git a/gcc/dbxout.c b/gcc/dbxout.c
index 9a9e44732d0..55f2275094f 100644
--- a/gcc/dbxout.c
+++ b/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. */
OpenPOWER on IntegriCloud