+2005-03-22 Daniel Berlin <dberlin@dberlin.org>
+
+ * c-opts.c (c_common_parse_file): Only start/end main source file
+ if debug hooks says the writer wants it.
+ * dbxout.c (dbx_debug_hooks): Add start_end_main_source_file
+ member.
+ (xcoff_debug_hooks): Ditto.
+ * debug.c (do_nothing_hooks): Ditto.
+ * debug.h (gcc_debug_hooks): Ditto.
+ * dwarf2out.c (dwarf2_debug_hooks): Ditto.
+ * sdbout.c (sdb_debug_hooks): Ditto.
+ * vmsdbgout.c (vmsdbg_debug_hooks): Ditto.
+
2005-03-22 Mark Mitchell <mark@codesourcery.com>
* doc/extend.texi: Deprecate C++ min/max operators.
i = 0;
for (;;)
{
- /* Start the main input file */
- (*debug_hooks->start_source_file) (0, this_input_filename);
+ /* Start the main input file, if the debug writer wants it. */
+ if (debug_hooks->start_end_main_source_file)
+ (*debug_hooks->start_source_file) (0, this_input_filename);
finish_options ();
pch_init ();
push_file_scope ();
c_parse_file ();
finish_file ();
pop_file_scope ();
- /* And end the main input file. */
- (*debug_hooks->end_source_file) (0);
+ /* And end the main input file, if the debug writer wants it */
+ if (debug_hooks->start_end_main_source_file)
+ (*debug_hooks->end_source_file) (0);
if (++i >= num_in_fnames)
break;
cpp_undef_all (parse_in);
debug_nothing_tree, /* outlining_inline_function */
debug_nothing_rtx, /* label */
dbxout_handle_pch, /* handle_pch */
- debug_nothing_rtx /* var_location */
+ debug_nothing_rtx, /* var_location */
+ 0 /* start_end_main_source_file */
};
#endif /* DBX_DEBUGGING_INFO */
debug_nothing_tree, /* outlining_inline_function */
debug_nothing_rtx, /* label */
dbxout_handle_pch, /* handle_pch */
- debug_nothing_rtx /* var_location */
+ debug_nothing_rtx, /* var_location */
+ 0 /* start_end_main_source_file */
};
#endif /* XCOFF_DEBUGGING_INFO */
\f
debug_nothing_tree, /* outlining_inline_function */
debug_nothing_rtx, /* label */
debug_nothing_int, /* handle_pch */
- debug_nothing_rtx /* var_location */
+ debug_nothing_rtx, /* var_location */
+ 0 /* start_end_main_source_file */
};
/* This file contains implementations of each debug hook that do
/* Called from final_scan_insn for any NOTE_INSN_VAR_LOCATION note. */
void (* var_location) (rtx);
+
+ /* This is 1 if the debug writer wants to see start and end commands for the
+ main source files, and 0 otherwise. */
+ int start_end_main_source_file;
};
extern const struct gcc_debug_hooks *debug_hooks;
dwarf2out_abstract_function, /* outlining_inline_function */
debug_nothing_rtx, /* label */
debug_nothing_int, /* handle_pch */
- dwarf2out_var_location
+ dwarf2out_var_location,
+ 1 /* start_end_main_source_file */
};
#endif
\f
debug_nothing_tree, /* outlining_inline_function */
sdbout_label, /* label */
debug_nothing_int, /* handle_pch */
- debug_nothing_rtx /* var_location */
+ debug_nothing_rtx, /* var_location */
+ 0 /* start_end_main_source_file */
};
/* Return a unique string to name an anonymous type. */
vmsdbgout_abstract_function,
debug_nothing_rtx, /* label */
debug_nothing_int, /* handle_pch */
- debug_nothing_rtx /* var_location */
+ debug_nothing_rtx, /* var_location */
+ 0 /* start_end_main_source_file */
};
/* Definitions of defaults for assembler-dependent names of various