diff options
author | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-02-26 16:05:24 +0000 |
---|---|---|
committer | tromey <tromey@138bc75d-0d04-0410-961f-82ee72b054a4> | 2008-02-26 16:05:24 +0000 |
commit | 9c85a98a2b03f3bacaba6103c8112066d0d272bb (patch) | |
tree | f43ad37c53fe9e709732439c80643fe626116583 /gcc/tree-cfg.c | |
parent | c039429494a2dec15ad4bf0b4a6d2fcc13ce8298 (diff) | |
download | gcc-9c85a98a2b03f3bacaba6103c8112066d0d272bb.tar.gz |
gcc
* system.h (USE_MAPPED_LOCATION): Poison.
* Makefile.in (GTFILES): Put CPP_ID_DATA_H first.
* tree-cfg.c (make_cond_expr_edges): Remove old location code.
(make_goto_expr_edges): Likewise.
(remove_bb): Likewise.
(execute_warn_function_return): Likewise.
* basic-block.h (struct edge_def) <goto_locus>: Change type to
location_t.
* c-common.c (fname_decl): Remove old location code.
* tree-vect-transform.c (vect_finish_stmt_generation): Remove old
location code.
* rtl.h (ASM_OPERANDS_SOURCE_LOCATION): Remove old-location
variant.
(ASM_INPUT_SOURCE_LOCATION): Likewise.
(gen_rtx_ASM_INPUT): Likewise.
(gen_rtx_ASM_INPUT_loc): Likewise.
(get_rtx_asm_OPERANDS): Remove.
* cfglayout.c (insn_locators_alloc): Remove old location code.
(set_curr_insn_source_location): Likewise.
(curr_insn_locator): Likewise.
* print-tree.c (print_node): Remove old location code.
* tree-mudflap.c (mf_varname_tree): Remove old location code.
(mf_file_function_line_tree): Remove test of USE_MAPPED_LOCATION.
* cfgexpand.c (expand_gimple_cond_expr): Don't use
location_from_locus.
(construct_exit_block): Remove old location code.
* emit-rtl.c (force_next_line_note): Remove old location code.
* profile.c (branch_prob): Remove old location code.
* tree-vectorizer.h (LOC, UNKNOWN_LOC, EXPR_LOC, LOC_FILE,
LOC_LINE): Remove old-location variants.
* langhooks.c (lhd_print_error_function): Remove old location
code.
* configure, config.in: Rebuilt.
* configure.ac (--enable-mapped-location): Remove.
* c-decl.c (c_init_decl_processing): Remove old location code.
(finish_function): Likewise.
* recog.c (decode_asm_operands): Remove old location code.
* c-pch.c (c_common_read_pch): Remove old location code.
* rtl.def (ASM_INPUT, ASM_OPERANDS): Remove old location
variants.
* gimple-low.c (lower_function_body): Remove old location code.
* toplev.c (unknown_location): Remove.
(push_srcloc): Remove old-location variant.
(process_options): Remove old location code.
(lang_dependent_init): Likewise.
* input.h (UNKNOWN_LOCATION): Move definition.
(location_t): Undeprecate.
(source_locus): Remove.
(location_from_locus): Remove.
(struct location_s): Remove.
Remove all old-location code.
(input_line, input_filename): Remove.
* final.c (final_scan_insn): Remove old location code.
* diagnostic.c (diagnostic_build_prefix): Remove
USE_MAPPED_LOCATION test.
* tree.h (gimple_stmt) <locus>: Now a location_t.
(tree_exp) <locus>: Likewise.
(DECL_IS_BUILTIN): Remove old-location variant.
(annotate_with_file_line, annotate_with_locus): Likewise.
(expr_locus, set_expr_locus): Update.
* tree.c (build1_stat): Remove old location code.
(last_annotated_node): Remove.
(annotate_with_file_line): Remove old-location variant.
(annotate_with_locus): Likewise.
(expr_location): Remove old location code.
(set_expr_location): Likewise.
(expr_has_location): Likewise.
(expr_locus): Likewise.
(set_expr_locus): Likewise.
(expr_filename): Don't use location_from_locus.
(expr_lineno): Likewise.
* rtl-error.c (location_for_asm): Remove old location code.
* c-lex.c (cb_line_change): Remove old location code.
(fe_file_change): Likewise.
(cb_def_pragma): Likewise.
(c_lex_with_flags): Likewise.
* gengtype.c (do_typedef): Don't special-case location types.
(define_location_structures): Remove.
(main): Don't call define_location_structures.
* tree-pretty-print.c (dump_implicit_edges): Remove old location
code.
gcc/ada
* misc.c (internal_error_function): Remove test of
USE_MAPPED_LOCATION.
* trans.c (gigi): Remove test of USE_MAPPED_LOCATION.
(Sloc_to_locus): Remove old location code.
gcc/cp
* parser.c (eof_token): Remove old location code.
(check_empty_body): Remove test of USE_MAPPED_LOCATION.
* decl2.c (generate_ctor_or_dtor_function): Remove old location
code.
(cp_write_global_declarations): Likewise.
* lex.c (cxx_init): Remove old location code.
(handle_pragma_implementation): Remove test of
USE_MAPPED_LOCATION.
* pt.c (tsubst): Remove old location code.
* error.c (cp_print_error_function): Remove test of
USE_MAPPED_LOCATION.
* decl.c (pop_label): Remove old location code.
(finish_function): Likewise.
gcc/fortran
* trans-io.c (set_error_locus): Remove old location code.
* trans-decl.c (gfc_set_decl_location): Remove old location code.
* f95-lang.c (gfc_init): Remove test of USE_MAPPED_LOCATION.
* scanner.c (gfc_gobble_whitespace): Remove old location code.
(get_file): Likewise.
(preprocessor_line): Likewise.
(load_file): Likewise.
(gfc_new_file): Likewise.
* trans.c (gfc_trans_runtime_check): Remove old location code.
(gfc_get_backend_locus): Likewise.
(gfc_set_backend_locus): Likewise.
* data.c (gfc_assign_data_value): Remove old location code.
* error.c (show_locus): Remove old location code.
* gfortran.h (gfc_linebuf): Remove old location code.
(gfc_linebuf_linenum): Remove old-location variant.
gcc/java
* lang.c (java_post_options): Remove conditional.
* expr.c (expand_byte_code): Remove old location code.
* jcf-parse.c (set_source_filename): Remove old location code.
(give_name_to_class): Likewise.
(jcf_parse): Likewise.
(duplicate_class_warning): Likewise.
(parse_class_file): Likewise.
(java_parse_file): Likewise.
* decl.c (finish_method): Remove old location code.
* class.c (push_class): Remove old location code.
gcc/objc
* objc-act.c (objc_init): Remove old location code.
gcc/treelang
* tree1.c (treelang_init): Remove old location code.
(treelang_parse_file): Likewise.
* lex.l (LINEMAP_POSITION_FOR_COLUMN): Remove.
(update_lineno_charno): Remove old location code.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@132679 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/tree-cfg.c')
-rw-r--r-- | gcc/tree-cfg.c | 57 |
1 files changed, 1 insertions, 56 deletions
diff --git a/gcc/tree-cfg.c b/gcc/tree-cfg.c index ffb4983744e..6d848a0c2d8 100644 --- a/gcc/tree-cfg.c +++ b/gcc/tree-cfg.c @@ -628,20 +628,10 @@ make_cond_expr_edges (basic_block bb) else_bb = label_to_block (else_label); e = make_edge (bb, then_bb, EDGE_TRUE_VALUE); -#ifdef USE_MAPPED_LOCATION e->goto_locus = EXPR_LOCATION (COND_EXPR_THEN (entry)); -#else - e->goto_locus = EXPR_LOCUS (COND_EXPR_THEN (entry)); -#endif e = make_edge (bb, else_bb, EDGE_FALSE_VALUE); if (e) - { -#ifdef USE_MAPPED_LOCATION - e->goto_locus = EXPR_LOCATION (COND_EXPR_ELSE (entry)); -#else - e->goto_locus = EXPR_LOCUS (COND_EXPR_ELSE (entry)); -#endif - } + e->goto_locus = EXPR_LOCATION (COND_EXPR_ELSE (entry)); /* We do not need the gotos anymore. */ COND_EXPR_THEN (entry) = NULL_TREE; @@ -835,11 +825,7 @@ make_goto_expr_edges (basic_block bb) { tree dest = GOTO_DESTINATION (goto_t); edge e = make_edge (bb, label_to_block (dest), EDGE_FALLTHRU); -#ifdef USE_MAPPED_LOCATION e->goto_locus = EXPR_LOCATION (goto_t); -#else - e->goto_locus = EXPR_LOCUS (goto_t); -#endif bsi_remove (&last, true); return; } @@ -1993,11 +1979,7 @@ static void remove_bb (basic_block bb) { block_stmt_iterator i; -#ifdef USE_MAPPED_LOCATION source_location loc = UNKNOWN_LOCATION; -#else - source_locus loc = 0; -#endif if (dump_file) { @@ -2065,15 +2047,8 @@ remove_bb (basic_block bb) program that are indeed unreachable. */ if (TREE_CODE (stmt) != GOTO_EXPR && EXPR_HAS_LOCATION (stmt) && !loc) { -#ifdef USE_MAPPED_LOCATION if (EXPR_HAS_LOCATION (stmt)) loc = EXPR_LOCATION (stmt); -#else - source_locus t; - t = EXPR_LOCUS (stmt); - if (t && LOCATION_LINE (*t) > 0) - loc = t; -#endif } } } @@ -2082,13 +2057,8 @@ remove_bb (basic_block bb) block is unreachable. We walk statements backwards in the loop above, so the last statement we process is the first statement in the block. */ -#ifdef USE_MAPPED_LOCATION if (loc > BUILTINS_LOCATION && LOCATION_LINE (loc) > 0) warning (OPT_Wunreachable_code, "%Hwill never be executed", &loc); -#else - if (loc) - warning (OPT_Wunreachable_code, "%Hwill never be executed", loc); -#endif remove_phi_nodes_and_edges_for_unreachable_block (bb); bb->il.tree = NULL; @@ -6990,11 +6960,7 @@ gimplify_build1 (block_stmt_iterator *bsi, enum tree_code code, tree type, static unsigned int execute_warn_function_return (void) { -#ifdef USE_MAPPED_LOCATION source_location location; -#else - location_t *locus; -#endif tree last; edge e; edge_iterator ei; @@ -7003,31 +6969,17 @@ execute_warn_function_return (void) if (TREE_THIS_VOLATILE (cfun->decl) && EDGE_COUNT (EXIT_BLOCK_PTR->preds) > 0) { -#ifdef USE_MAPPED_LOCATION location = UNKNOWN_LOCATION; -#else - locus = NULL; -#endif FOR_EACH_EDGE (e, ei, EXIT_BLOCK_PTR->preds) { last = last_stmt (e->src); if (TREE_CODE (last) == RETURN_EXPR -#ifdef USE_MAPPED_LOCATION && (location = EXPR_LOCATION (last)) != UNKNOWN_LOCATION) -#else - && (locus = EXPR_LOCUS (last)) != NULL) -#endif break; } -#ifdef USE_MAPPED_LOCATION if (location == UNKNOWN_LOCATION) location = cfun->function_end_locus; warning (0, "%H%<noreturn%> function does return", &location); -#else - if (!locus) - locus = &cfun->function_end_locus; - warning (0, "%H%<noreturn%> function does return", locus); -#endif } /* If we see "return;" in some basic block, then we do reach the end @@ -7044,17 +6996,10 @@ execute_warn_function_return (void) && TREE_OPERAND (last, 0) == NULL && !TREE_NO_WARNING (last)) { -#ifdef USE_MAPPED_LOCATION location = EXPR_LOCATION (last); if (location == UNKNOWN_LOCATION) location = cfun->function_end_locus; warning (OPT_Wreturn_type, "%Hcontrol reaches end of non-void function", &location); -#else - locus = EXPR_LOCUS (last); - if (!locus) - locus = &cfun->function_end_locus; - warning (OPT_Wreturn_type, "%Hcontrol reaches end of non-void function", locus); -#endif TREE_NO_WARNING (cfun->decl) = 1; break; } |