c-opts.c (c_common_parse_file): If start_end_main_source_file, don't call start_source_file debug hook here...

* c-opts.c (c_common_parse_file): If start_end_main_source_file,
	don't call start_source_file debug hook here...
	(finish_options): ... but here, after outputting predefined and
	command line defines and undefs.

From-SVN: r159293
This commit is contained in:
Jakub Jelinek 2010-05-11 21:54:51 +02:00 committed by Jakub Jelinek
parent f6430ea53c
commit 9d000e8300
2 changed files with 20 additions and 5 deletions

View File

@ -1,5 +1,10 @@
2010-05-11 Jakub Jelinek <jakub@redhat.com> 2010-05-11 Jakub Jelinek <jakub@redhat.com>
* c-opts.c (c_common_parse_file): If start_end_main_source_file,
don't call start_source_file debug hook here...
(finish_options): ... but here, after outputting predefined and
command line defines and undefs.
PR middle-end/44071 PR middle-end/44071
* cfglayout.c (fixup_reorder_chain): Allow asm goto to have * cfglayout.c (fixup_reorder_chain): Allow asm goto to have
no fallthru edge. no fallthru edge.

View File

@ -1388,9 +1388,6 @@ c_common_parse_file (int set_yydebug)
i = 0; i = 0;
for (;;) for (;;)
{ {
/* 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 (); finish_options ();
pch_init (); pch_init ();
push_file_scope (); push_file_scope ();
@ -1649,6 +1646,11 @@ finish_options (void)
} }
} }
/* Start the main input file, if the debug writer wants it. */
if (debug_hooks->start_end_main_source_file
&& !flag_preprocess_only)
(*debug_hooks->start_source_file) (0, this_input_filename);
/* Handle -imacros after -D and -U. */ /* Handle -imacros after -D and -U. */
for (i = 0; i < deferred_count; i++) for (i = 0; i < deferred_count; i++)
{ {
@ -1663,8 +1665,16 @@ finish_options (void)
} }
} }
} }
else if (cpp_opts->directives_only) else
cpp_init_special_builtins (parse_in); {
if (cpp_opts->directives_only)
cpp_init_special_builtins (parse_in);
/* Start the main input file, if the debug writer wants it. */
if (debug_hooks->start_end_main_source_file
&& !flag_preprocess_only)
(*debug_hooks->start_source_file) (0, this_input_filename);
}
include_cursor = 0; include_cursor = 0;
push_command_line_include (); push_command_line_include ();