Patch: Remove non-mapped location support

Tom Tromey tromey@redhat.com
Mon Feb 25 17:41:00 GMT 2008


In 4.3 we changed the default location representation to "mapped
locations".  The old representation was deprecated at that point.

This patch removes the old, deprecated location code.  By and large
this is a mechanical patch.  There are a few details worth mentioning:

* I poisoned 'USE_MAPPED_LOCATION' to prevent regressions due to
  merges.  I think there's no point in poisoning the other deleted
  input.h things; a merge would run into other errors if those are
  used.

* java/java-tree.h still mentions USE_MAPPED_LOCATION in a comment.
  This is a reminder to me to look into this -- the comment is for a
  field which is apparently never set.  I will fix this separately.

* input.h used to claim that location_t was a deprecated typedef.  I
  think that removing this is not very important and I "un-deprecated"
  it.

* The Makefile.in change is needed to make gengtype work properly now
  that I've deleted the input.h-related special case.

* There are a few places that had odd comments related to mapped
  locations, e.g. look at cp/decl2.c.  I left the "???" comments
  (slightly modified) for language maintainers to look at.  They don't
  seem to cause any problems with the test suite -- and anyway 4.3 is
  already running this branch of the conditionals...

* tree-vectorizer.h defines shorthand for various input.h-defined
  things.  In general I think this is not the best thing to do; it is
  better, in my view, for all the code in GCC to use a single API,
  rather than having modules defining idiosyncractic variants.  I did
  not change this.

Bootstrapped and regtested C, C++, ObjC, ObjC++, Ada, Fortran, Java,
and Treelang on x86 FC-6.  Ok?

Tom

ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* 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.

java/ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* 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.

objc/ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* objc-act.c (objc_init): Remove old location code.

cp/ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* 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.

ada/ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* 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.

fortran/ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* 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.

treelang/ChangeLog:
2008-02-24  Tom Tromey  <tromey@redhat.com>

	* 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.

Index: tree-pretty-print.c
===================================================================
--- tree-pretty-print.c	(revision 132558)
+++ tree-pretty-print.c	(working copy)
@@ -1,5 +1,5 @@
 /* Pretty formatting of GENERIC trees in C syntax.
-   Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Adapted from c-pretty-print.c by Diego Novillo <dnovillo@redhat.com>
 
@@ -3112,20 +3112,10 @@
     {
       INDENT (indent);
 
-      if ((flags & TDF_LINENO)
-#ifdef USE_MAPPED_LOCATION
-	  && e->goto_locus != UNKNOWN_LOCATION
-#else
-	  && e->goto_locus
-#endif
-	  )
+      if ((flags & TDF_LINENO) && e->goto_locus != UNKNOWN_LOCATION)
 	{
 	  expanded_location goto_xloc;
-#ifdef USE_MAPPED_LOCATION
 	  goto_xloc = expand_location (e->goto_locus);
-#else
-	  goto_xloc = *e->goto_locus;
-#endif
 	  pp_character (buffer, '[');
 	  if (goto_xloc.file)
 	    {
Index: gengtype.c
===================================================================
--- gengtype.c	(revision 132558)
+++ gengtype.c	(working copy)
@@ -1,5 +1,5 @@
 /* Process source files and output type information.
-   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
    This file is part of GCC.
@@ -521,16 +521,11 @@
 {
   pair_p p;
 
-  /* temporary kludge - gengtype doesn't handle conditionals or macros.
-     Ignore any attempt to typedef CUMULATIVE_ARGS, location_t,
-     expanded_location, or source_locus, unless it is coming from
-     this file (main() sets them up with safe dummy definitions).  */
-  if ((!strcmp (s, "CUMULATIVE_ARGS")
-       || !strcmp (s, "location_t")
-       || !strcmp (s, "source_locus")
-       || !strcmp (s, "source_location")
-       || !strcmp (s, "expanded_location"))
-      && pos->file != this_file)
+  /* temporary kludge - gengtype doesn't handle conditionals or
+     macros.  Ignore any attempt to typedef CUMULATIVE_ARGS, unless it
+     is coming from this file (main() sets them up with safe dummy
+     definitions).  */
+  if (!strcmp (s, "CUMULATIVE_ARGS") && pos->file != this_file)
     return;
 
   for (p = typedefs; p != NULL; p = p->next)
@@ -3478,36 +3473,6 @@
   do_typedef (astratname, new_structure (astratname, 0, pos, field, 0), pos);
 }
 
-/* Yet more temporary kludge since gengtype doesn't understand conditionals.
-   This must be kept in sync with input.h.  */
-static void
-define_location_structures (void)
-{
-  pair_p fields;
-  type_p locs;
-  static struct fileloc pos = { this_file, __LINE__ };
-  do_scalar_typedef ("source_location", &pos);
-
-#ifdef USE_MAPPED_LOCATION
-    fields = create_field (0, &scalar_nonchar, "column");
-    fields = create_field (fields, &scalar_nonchar, "line");
-    fields = create_field (fields, &string_type, "file");
-    locs = new_structure ("anon:expanded_location", 0, &pos, fields, 0);
-
-    do_typedef ("expanded_location", locs, &pos);
-    do_scalar_typedef ("location_t", &pos);
-    do_scalar_typedef ("source_locus", &pos);
-#else
-    fields = create_field (0, &scalar_nonchar, "line");
-    fields = create_field (fields, &string_type, "file");
-    locs = new_structure ("location_s", 0, &pos, fields, 0);
-
-    do_typedef ("expanded_location", locs, &pos);
-    do_typedef ("location_t", locs, &pos);
-    do_typedef ("source_locus", create_pointer (locs), &pos);
-#endif
-}
-
 
 int
 main (int argc, char **argv)
@@ -3544,7 +3509,6 @@
   do_scalar_typedef ("JCF_u2", &pos); pos.line++;
   do_scalar_typedef ("void", &pos); pos.line++;
   do_typedef ("PTR", create_pointer (resolve_typedef ("void", &pos)), &pos);
-  define_location_structures ();
 
   for (i = 0; i < num_gt_files; i++)
     parse_file (gt_files[i]);
Index: java/class.c
===================================================================
--- java/class.c	(revision 132558)
+++ java/class.c	(working copy)
@@ -1,6 +1,6 @@
 /* Functions related to building classes and their related objects.
    Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -479,10 +479,6 @@
 {
   tree decl, signature;
   location_t saved_loc = input_location;
-#ifndef USE_MAPPED_LOCATION
-  input_filename = "<unknown>";
-  input_line = 0;
-#endif
   CLASS_P (class_type) = 1;
   decl = build_decl (TYPE_DECL, class_name, class_type);
   TYPE_DECL_SUPPRESS_DEBUG (decl) = 1;
Index: java/decl.c
===================================================================
--- java/decl.c	(revision 132558)
+++ java/decl.c	(working copy)
@@ -1,7 +1,7 @@
 /* Process declarations and variables for the GNU compiler for the
    Java(TM) language.
    Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2007,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -1851,12 +1851,7 @@
     set_cfun (DECL_STRUCT_FUNCTION (fndecl));
   else
     allocate_struct_function (fndecl, false);
-#ifdef USE_MAPPED_LOCATION
   cfun->function_end_locus = DECL_FUNCTION_LAST_LINE (fndecl);
-#else
-  cfun->function_end_locus.file = DECL_SOURCE_FILE (fndecl);
-  cfun->function_end_locus.line = DECL_FUNCTION_LAST_LINE (fndecl);
-#endif
 
   /* Defer inlining and expansion to the cgraph optimizers.  */
   cgraph_finalize_function (fndecl, false);
Index: java/jcf-parse.c
===================================================================
--- java/jcf-parse.c	(revision 132558)
+++ java/jcf-parse.c	(working copy)
@@ -1,6 +1,6 @@
 /* Parser for Java(TM) .class files.
    Copyright (C) 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -327,14 +327,7 @@
 	  && strcmp (sfname, old_filename + old_len - new_len) == 0
 	  && (old_filename[old_len - new_len - 1] == '/'
 	      || old_filename[old_len - new_len - 1] == '\\'))
-	{
-#ifndef USE_MAPPED_LOCATION
-	  input_filename = find_sourcefile (input_filename);
-	  DECL_SOURCE_LOCATION (TYPE_NAME (current_class)) = input_location;
-	  file_start_location = input_location;
-#endif
-	  return;
-	}
+	return;
     }
   if (strchr (sfname, '/') == NULL && strchr (sfname, '\\') == NULL)
     {
@@ -364,13 +357,7 @@
     }
       
   sfname = find_sourcefile (sfname);
-#ifdef USE_MAPPED_LOCATION
   line_table->maps[line_table->used-1].to_file = sfname;
-#else
-  input_filename = sfname;
-  DECL_SOURCE_LOCATION (TYPE_NAME (current_class)) = input_location;
-  file_start_location = input_location;
-#endif
   if (current_class == main_class) main_input_filename = sfname;
 }
 
@@ -1205,7 +1192,6 @@
       tree class_name = unmangle_classname ((const char *) JPOOL_UTF_DATA (jcf, j),
 					    JPOOL_UTF_LENGTH (jcf, j));
       this_class = lookup_class (class_name);
-#ifdef USE_MAPPED_LOCATION
       {
       tree source_name = identifier_subst (class_name, "", '.', '/', ".java");
       const char *sfname = IDENTIFIER_POINTER (source_name);
@@ -1216,14 +1202,6 @@
       if (main_input_filename == NULL && jcf == main_jcf)
 	main_input_filename = sfname;
       }
-#else
-     if (! DECL_ARTIFICIAL (TYPE_NAME (this_class)))
-      {
-	input_location = DECL_SOURCE_LOCATION (TYPE_NAME (this_class));
-	if (main_input_filename == NULL && jcf == main_jcf)
-	  main_input_filename = input_filename;
-      }
-#endif
 
       jcf->cpool.data[i].t = this_class;
       JPOOL_TAG (jcf, i) = CONSTANT_ResolvedClass;
@@ -1496,9 +1474,7 @@
   if (TYPE_REFLECTION_DATA (current_class))
     annotation_write_byte (JV_DONE_ATTR);
 
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_LEAVE, false, NULL, 0);
-#endif
 
   /* The fields of class_type_node are already in correct order. */
   if (current_class != class_type_node && current_class != object_type_node)
@@ -1531,13 +1507,8 @@
 duplicate_class_warning (const char *filename)
 {
   location_t warn_loc;
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_RENAME, 0, filename, 0);
   warn_loc = linemap_line_start (line_table, 0, 1);
-#else
-  warn_loc.file = filename;
-  warn_loc.line = 0;
-#endif
   warning (0, "%Hduplicate class will only be compiled once", &warn_loc);
 }
 
@@ -1586,13 +1557,11 @@
   java_layout_seen_class_methods ();
 
   input_location = DECL_SOURCE_LOCATION (TYPE_NAME (current_class));
-#ifdef USE_MAPPED_LOCATION
   {
     /* Re-enter the current file.  */
     expanded_location loc = expand_location (input_location);
     linemap_add (line_table, LC_ENTER, 0, loc.file, loc.line);
   }
-#endif
   file_start_location = input_location;
   (*debug_hooks->start_source_file) (input_line, input_filename);
 
@@ -1657,13 +1626,8 @@
 	      if (min_line == 0 || line < min_line)
 		min_line = line;
 	    }
-#ifdef USE_MAPPED_LOCATION
 	  if (min_line != 0)
 	    input_location = linemap_line_start (line_table, min_line, 1);
-#else
-	  if (min_line != 0)
-	    input_line = min_line;
-#endif
 	}
       else
 	{
@@ -1934,18 +1898,14 @@
 	  JCF_ZERO (main_jcf);
 	  main_jcf->read_state = finput;
 	  main_jcf->filbuf = jcf_filbuf_from_stdio;
-#ifdef USE_MAPPED_LOCATION
 	  linemap_add (line_table, LC_ENTER, false, filename, 0);
 	  input_location = linemap_line_start (line_table, 0, 1);
-#endif
 	  if (open_in_zip (main_jcf, filename, NULL, 0) <  0)
 	    fatal_error ("bad zip/jar file %s", filename);
 	  localToFile = SeenZipFiles;
 	  /* Register all the classes defined there.  */
 	  process_zip_dir (main_jcf->read_state);
-#ifdef USE_MAPPED_LOCATION
 	  linemap_add (line_table, LC_LEAVE, false, NULL, 0);
-#endif
 	  parse_zip_file_entries ();
 	}
       else if (magic == (JCF_u4) ZIPEMPTYMAGIC)
@@ -1962,10 +1922,8 @@
 	  parse_source_file_1 (real_file, filename, finput);
 	  java_parser_context_restore_global ();
 	  java_pop_parser_context (1);
-#ifdef USE_MAPPED_LOCATION
 	  linemap_add (line_table, LC_LEAVE, false, NULL, 0);
 #endif
-#endif
 	}
     }
 
Index: java/expr.c
===================================================================
--- java/expr.c	(revision 132558)
+++ java/expr.c	(working copy)
@@ -1,6 +1,6 @@
 /* Process expressions for the GNU compiler for the Java(TM) language.
    Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -3218,11 +3218,7 @@
 	      if (pc == PC)
 		{
 		  int line = GET_u2 (linenumber_pointer - 2);
-#ifdef USE_MAPPED_LOCATION
 		  input_location = linemap_line_start (line_table, line, 1);
-#else
-		  input_location.line = line;
-#endif
 		  if (!(instruction_bits[PC] & BCODE_HAS_MULTI_LINENUMBERS))
 		    break;
 		}
Index: java/lang.c
===================================================================
--- java/lang.c	(revision 132558)
+++ java/lang.c	(working copy)
@@ -1,6 +1,6 @@
 /* Java(TM) language-specific utility routines.
    Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -655,10 +655,8 @@
 	    }
 	}
     }
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_ENTER, false, filename, 0);
   linemap_add (line_table, LC_RENAME, false, "<built-in>", 0);
-#endif
 
   /* Initialize the compiler back end.  */
   return false;
Index: c-lex.c
===================================================================
--- c-lex.c	(revision 132558)
+++ c-lex.c	(working copy)
@@ -1,6 +1,6 @@
 /* Mainly the interface between cpplib and the C front ends.
    Copyright (C) 1987, 1988, 1989, 1992, 1994, 1995, 1996, 1997
-   1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007
+   1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -190,15 +190,7 @@
 		int parsing_args)
 {
   if (token->type != CPP_EOF && !parsing_args)
-#ifdef USE_MAPPED_LOCATION
     input_location = token->src_loc;
-#else
-    {
-      source_location loc = token->src_loc;
-      const struct line_map *map = linemap_lookup (line_table, loc);
-      input_line = SOURCE_LINE (map, loc);
-    }
-#endif
 }
 
 void
@@ -213,17 +205,10 @@
 	 we already did in compile_file.  */
       if (!MAIN_FILE_P (new_map))
 	{
-#ifdef USE_MAPPED_LOCATION
 	  int included_at = LAST_SOURCE_LINE_LOCATION (new_map - 1);
 
 	  input_location = included_at;
 	  push_srcloc (new_map->start_location);
-#else
-	  int included_at = LAST_SOURCE_LINE (new_map - 1);
-
-	  input_line = included_at;
-	  push_srcloc (new_map->to_file, 1);
-#endif
 	  (*debug_hooks->start_source_file) (included_at, new_map->to_file);
 #ifndef NO_IMPLICIT_EXTERN_C
 	  if (c_header_level)
@@ -253,12 +238,7 @@
 
   update_header_times (new_map->to_file);
   in_system_header = new_map->sysp != 0;
-#ifdef USE_MAPPED_LOCATION
   input_location = new_map->start_location;
-#else
-  input_filename = new_map->to_file;
-  input_line = new_map->to_line;
-#endif
 }
 
 static void
@@ -271,14 +251,7 @@
     {
       const unsigned char *space, *name;
       const cpp_token *s;
-#ifndef USE_MAPPED_LOCATION
-      location_t fe_loc;
-      const struct line_map *map = linemap_lookup (line_table, loc);
-      fe_loc.file = map->to_file;
-      fe_loc.line = SOURCE_LINE (map, loc);
-#else
       location_t fe_loc = loc;
-#endif
 
       space = name = (const unsigned char *) "";
       s = cpp_get_token (pfile);
@@ -329,12 +302,7 @@
 
   timevar_push (TV_CPP);
  retry:
-#ifdef USE_MAPPED_LOCATION
   tok = cpp_get_token_with_location (parse_in, loc);
-#else
-  tok = cpp_get_token (parse_in);
-  *loc = input_location;
-#endif
   type = tok->type;
 
  retry_after_at:
@@ -381,19 +349,11 @@
       /* An @ may give the next token special significance in Objective-C.  */
       if (c_dialect_objc ())
 	{
-#ifdef USE_MAPPED_LOCATION
 	  location_t atloc = *loc;
 	  location_t newloc;
-#else
-	  location_t atloc = input_location;
-#endif
 
 	retry_at:
-#ifdef USE_MAPPED_LOCATION
 	  tok = cpp_get_token_with_location (parse_in, &newloc);
-#else
-	  tok = cpp_get_token (parse_in);
-#endif
 	  type = tok->type;
 	  switch (type)
 	    {
@@ -417,9 +377,7 @@
 	    default:
 	      /* ... or not.  */
 	      error ("%Hstray %<@%> in program", &atloc);
-#ifdef USE_MAPPED_LOCATION
 	      *loc = newloc;
-#endif
 	      goto retry_after_at;
 	    }
 	  break;
Index: rtl-error.c
===================================================================
--- rtl-error.c	(revision 132558)
+++ rtl-error.c	(working copy)
@@ -1,5 +1,5 @@
 /* RTL specific diagnostic subroutines for GCC
-   Copyright (C) 2001, 2002, 2003, 2004, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2001, 2002, 2003, 2004, 2007, 2008 Free Software Foundation, Inc.
    Contributed by Gabriel Dos Reis <gdr@codesourcery.com>
 
 This file is part of GCC.
@@ -58,14 +58,7 @@
     asmop = NULL;
 
   if (asmop)
-#ifdef USE_MAPPED_LOCATION
     loc = ASM_OPERANDS_SOURCE_LOCATION (asmop);
-#else
-    {
-      loc.file = ASM_OPERANDS_SOURCE_FILE (asmop);
-      loc.line = ASM_OPERANDS_SOURCE_LINE (asmop);
-    }
-#endif
   else
     loc = input_location;
   return loc;
Index: tree.c
===================================================================
--- tree.c	(revision 132558)
+++ tree.c	(working copy)
@@ -1,6 +1,6 @@
 /* Language-independent node constructors for parse phase of GNU compiler.
    Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -3019,11 +3019,7 @@
   TREE_SET_CODE (t, code);
 
   TREE_TYPE (t) = type;
-#ifdef USE_MAPPED_LOCATION
   SET_EXPR_LOCATION (t, UNKNOWN_LOCATION);
-#else
-  SET_EXPR_LOCUS (t, NULL);
-#endif
   TREE_OPERAND (t, 0) = node;
   TREE_BLOCK (t) = NULL_TREE;
   if (node && !TYPE_P (node))
@@ -3385,13 +3381,6 @@
   return block;
 }
 
-#if 1 /* ! defined(USE_MAPPED_LOCATION) */
-/* ??? gengtype doesn't handle conditionals */
-static GTY(()) source_locus last_annotated_node;
-#endif
-
-#ifdef USE_MAPPED_LOCATION
-
 expanded_location
 expand_location (source_location loc)
 {
@@ -3412,53 +3401,6 @@
   return xloc;
 }
 
-#else
-
-/* Record the exact location where an expression or an identifier were
-   encountered.  */
-
-void
-annotate_with_file_line (tree node, const char *file, int line)
-{
-  location_t *new_loc;
-
-  /* Roughly one percent of the calls to this function are to annotate
-     a node with the same information already attached to that node!
-     Just return instead of wasting memory.  */
-  if (EXPR_LOCUS (node)
-      && EXPR_LINENO (node) == line
-      && (EXPR_FILENAME (node) == file
-	  || !strcmp (EXPR_FILENAME (node), file)))
-    {
-      last_annotated_node = EXPR_LOCUS (node);
-      return;
-    }
-
-  /* In heavily macroized code (such as GCC itself) this single
-     entry cache can reduce the number of allocations by more
-     than half.  */
-  if (last_annotated_node
-      && last_annotated_node->line == line
-      && (last_annotated_node->file == file
-	  || !strcmp (last_annotated_node->file, file)))
-    {
-      SET_EXPR_LOCUS (node, last_annotated_node);
-      return;
-    }
-
-  new_loc = GGC_NEW (location_t);
-  new_loc->file = file;
-  new_loc->line = line;
-  SET_EXPR_LOCUS (node, new_loc);
-  last_annotated_node = new_loc;
-}
-
-void
-annotate_with_locus (tree node, location_t locus)
-{
-  annotate_with_file_line (node, locus.file, locus.line);
-}
-#endif
 
 /* Source location accessor functions.  */
 
@@ -3469,71 +3411,39 @@
 location_t
 expr_location (const_tree node)
 {
-#ifdef USE_MAPPED_LOCATION
   if (GIMPLE_STMT_P (node))
     return GIMPLE_STMT_LOCUS (node);
   return EXPR_P (node) ? node->exp.locus : UNKNOWN_LOCATION;
-#else
-  if (GIMPLE_STMT_P (node))
-    return EXPR_HAS_LOCATION (node)
-      ? *GIMPLE_STMT_LOCUS (node) : UNKNOWN_LOCATION;
-  return EXPR_HAS_LOCATION (node) ? *node->exp.locus : UNKNOWN_LOCATION;
-#endif
 }
 
 void
 set_expr_location (tree node, location_t locus)
 {
-#ifdef USE_MAPPED_LOCATION
   if (GIMPLE_STMT_P (node))
     GIMPLE_STMT_LOCUS (node) = locus;
   else
     EXPR_CHECK (node)->exp.locus = locus;
-#else
-      annotate_with_locus (node, locus);
-#endif
 }
 
 bool
 expr_has_location (const_tree node)
 {
-#ifdef USE_MAPPED_LOCATION
   return expr_location (node) != UNKNOWN_LOCATION;
-#else
-  return expr_locus (node) != NULL;
-#endif
 }
 
-#ifdef USE_MAPPED_LOCATION
 source_location *
-#else
-source_locus
-#endif
 expr_locus (const_tree node)
 {
-#ifdef USE_MAPPED_LOCATION
   if (GIMPLE_STMT_P (node))
     return CONST_CAST (source_location *, &GIMPLE_STMT_LOCUS (node));
   return (EXPR_P (node)
 	  ? CONST_CAST (source_location *, &node->exp.locus)
 	  : (source_location *) NULL);
-#else
-  if (GIMPLE_STMT_P (node))
-    return GIMPLE_STMT_LOCUS (node);
-  return EXPR_P (node) ? node->exp.locus : (source_locus) NULL;
-#endif
 }
 
 void
-set_expr_locus (tree node,
-#ifdef USE_MAPPED_LOCATION
-		source_location *loc
-#else
-		source_locus loc
-#endif
-		)
+set_expr_locus (tree node, source_location *loc)
 {
-#ifdef USE_MAPPED_LOCATION
   if (loc == NULL)
     {
       if (GIMPLE_STMT_P (node))
@@ -3548,12 +3458,6 @@
       else
 	EXPR_CHECK (node)->exp.locus = *loc;
     }
-#else
-  if (GIMPLE_STMT_P (node))
-    GIMPLE_STMT_LOCUS (node) = loc;
-  else
-    EXPR_CHECK (node)->exp.locus = loc;
-#endif
 }
 
 /* Return the file name of the location of NODE.  */
@@ -3561,8 +3465,8 @@
 expr_filename (const_tree node)
 {
   if (GIMPLE_STMT_P (node))
-    return LOCATION_FILE (location_from_locus (GIMPLE_STMT_LOCUS (node)));
-  return LOCATION_FILE (location_from_locus (EXPR_CHECK (node)->exp.locus));
+    return LOCATION_FILE (GIMPLE_STMT_LOCUS (node));
+  return LOCATION_FILE (EXPR_CHECK (node)->exp.locus);
 }
 
 /* Return the line number of the location of NODE.  */
@@ -3570,8 +3474,8 @@
 expr_lineno (const_tree node)
 {
   if (GIMPLE_STMT_P (node))
-    return LOCATION_LINE (location_from_locus (GIMPLE_STMT_LOCUS (node)));
-  return LOCATION_LINE (location_from_locus (EXPR_CHECK (node)->exp.locus));
+    return LOCATION_LINE (GIMPLE_STMT_LOCUS (node));
+  return LOCATION_LINE (EXPR_CHECK (node)->exp.locus);
 }
 
 
Index: tree.h
===================================================================
--- tree.h	(revision 132558)
+++ tree.h	(working copy)
@@ -417,7 +417,7 @@
 struct gimple_stmt GTY(())
 {
   struct tree_base base;
-  source_locus locus;
+  location_t locus;
   tree block;
   /* FIXME tuples: Eventually this should be of type ``struct gimple_expr''.  */
   tree GTY ((length ("TREE_CODE_LENGTH (TREE_CODE (&%h))"))) operands[1];
@@ -1841,7 +1841,7 @@
 struct tree_exp GTY(())
 {
   struct tree_common common;
-  source_locus locus;
+  location_t locus;
   tree block;
   tree GTY ((special ("tree_exp"),
 	     desc ("TREE_CODE ((tree) &%0)")))
@@ -2515,12 +2515,8 @@
 #define DECL_SOURCE_LOCATION(NODE) (DECL_MINIMAL_CHECK (NODE)->decl_minimal.locus)
 #define DECL_SOURCE_FILE(NODE) LOCATION_FILE (DECL_SOURCE_LOCATION (NODE))
 #define DECL_SOURCE_LINE(NODE) LOCATION_LINE (DECL_SOURCE_LOCATION (NODE))
-#ifdef USE_MAPPED_LOCATION
 #define DECL_IS_BUILTIN(DECL) \
   (DECL_SOURCE_LOCATION (DECL) <= BUILTINS_LOCATION)
-#else
-#define DECL_IS_BUILTIN(DECL) (DECL_SOURCE_LINE(DECL) == 0)
-#endif
 
 /*  For FIELD_DECLs, this is the RECORD_TYPE, UNION_TYPE, or
     QUAL_UNION_TYPE node that the field is a member of.  For VAR_DECL,
@@ -3999,10 +3995,6 @@
 extern tree build_fn_decl (const char *, tree);
 #define build_decl(c,t,q) build_decl_stat (c,t,q MEM_STAT_INFO)
 extern tree build_block (tree, tree, tree, tree);
-#ifndef USE_MAPPED_LOCATION
-extern void annotate_with_file_line (tree, const char *, int);
-extern void annotate_with_locus (tree, location_t);
-#endif
 extern tree build_empty_stmt (void);
 extern tree build_omp_clause (enum omp_clause_code);
 
@@ -4935,13 +4927,8 @@
 extern void set_expr_location (tree, location_t);
 extern bool expr_has_location (const_tree);
 
-#ifdef USE_MAPPED_LOCATION
-extern source_locus *expr_locus (const_tree);
+extern location_t *expr_locus (const_tree);
 extern void set_expr_locus (tree, source_location *);
-#else
-extern source_locus expr_locus (const_tree);
-extern void set_expr_locus (tree, source_locus loc);
-#endif
 extern const char *expr_filename (const_tree);
 extern int expr_lineno (const_tree);
 
Index: diagnostic.c
===================================================================
--- diagnostic.c	(revision 132558)
+++ diagnostic.c	(working copy)
@@ -1,5 +1,5 @@
 /* Language-independent diagnostic subroutines for the GNU Compiler Collection
-   Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Gabriel Dos Reis <gdr@codesourcery.com>
 
@@ -157,10 +157,8 @@
   return
     (s.file == NULL
      ? build_message_string ("%s: %s", progname, text)
-#ifdef USE_MAPPED_LOCATION
      : flag_show_column && s.column != 0
      ? build_message_string ("%s:%d:%d: %s", s.file, s.line, s.column, text)
-#endif
      : build_message_string ("%s:%d: %s", s.file, s.line, text));
 }
 
Index: final.c
===================================================================
--- final.c	(revision 132558)
+++ final.c	(working copy)
@@ -1,6 +1,6 @@
 /* Convert RTL to assembler code and output it, for GNU compiler.
    Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997,
-   1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -2192,12 +2192,7 @@
 		    fputs (ASM_APP_ON, file);
 		    app_on = 1;
 		  }
-#ifdef USE_MAPPED_LOCATION
 		loc = expand_location (ASM_INPUT_SOURCE_LOCATION (body));
-#else
-		loc.file = ASM_INPUT_SOURCE_FILE (body);
-		loc.line = ASM_INPUT_SOURCE_LINE (body);
-#endif
 		if (*loc.file && loc.line)
 		  fprintf (asm_out_file, "%s %i \"%s\" 1\n",
 			   ASM_COMMENT_START, loc.line, loc.file);
Index: input.h
===================================================================
--- input.h	(revision 132558)
+++ input.h	(working copy)
@@ -1,6 +1,6 @@
 /* Declarations for variables relating to reading the source file.
    Used by parsers, lexical analyzers, and error message routines.
-   Copyright (C) 1993, 1997, 1998, 2000, 2003, 2004, 2007
+   Copyright (C) 1993, 1997, 1998, 2000, 2003, 2004, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -23,17 +23,16 @@
 #define GCC_INPUT_H
 
 #include "line-map.h"
+
 extern GTY(()) struct line_maps *line_table;
 
+/* A value which will never be used to represent a real location.  */
+#define UNKNOWN_LOCATION ((source_location) 0)
+
 /* The location for declarations in "<built-in>" */
 #define BUILTINS_LOCATION ((source_location) 2)
 
-/* Note: if any of the types defined inside this #ifdef are changed,
-   gengtype.c:define_location_structures must be updated to match.  */
-
-#ifdef USE_MAPPED_LOCATION
-
-typedef struct
+typedef struct GTY (())
 {
   /* The name of the source file involved.  */
   const char *file;
@@ -46,35 +45,10 @@
 
 extern expanded_location expand_location (source_location);
 
-#define UNKNOWN_LOCATION ((source_location) 0)
-typedef source_location location_t; /* deprecated typedef */
-typedef source_location source_locus; /* to be removed */
+/* Historically GCC used location_t, while cpp used source_location.
+   This could be removed but it hardly seems worth the effort.  */
+typedef source_location location_t;
 
-#define location_from_locus(LOCUS) (LOCUS)
-
-#else /* ! USE_MAPPED_LOCATION */
-
-struct location_s GTY(())
-{
-  /* The name of the source file involved.  */
-  const char *file;
-
-  /* The line-location in the source file.  */
-  int line;
-};
-
-typedef struct location_s expanded_location;
-typedef struct location_s location_t;
-typedef location_t *source_locus;
-
-#define expand_location(FILELINE) (FILELINE)
-extern location_t unknown_location;
-#define UNKNOWN_LOCATION unknown_location
-
-#define location_from_locus(LOCUS) (* (LOCUS))
-
-#endif /* ! USE_MAPPED_LOCATION */
-
 struct file_stack
 {
   struct file_stack *next;
@@ -85,19 +59,15 @@
 extern const char *main_input_filename;
 
 extern location_t input_location;
-#ifdef USE_MAPPED_LOCATION
 extern void push_srcloc (location_t);
-#else /* ! USE_MAPPED_LOCATION */
-extern void push_srcloc (const char *name, int line);
-#endif /* ! USE_MAPPED_LOCATION */
 extern void pop_srcloc (void);
 extern void restore_input_file_stack (int);
 
 #define LOCATION_FILE(LOC) ((expand_location (LOC)).file)
 #define LOCATION_LINE(LOC) ((expand_location (LOC)).line)
 
-#define input_line LOCATION_LINE(input_location)
-#define input_filename LOCATION_FILE(input_location)
+#define input_line LOCATION_LINE (input_location)
+#define input_filename LOCATION_FILE (input_location)
 
 /* Stack of currently pending input files.
    The line member is not accurate for the innermost file on the stack.  */
Index: objc/objc-act.c
===================================================================
--- objc/objc-act.c	(revision 132558)
+++ objc/objc-act.c	(working copy)
@@ -1,6 +1,6 @@
 /* Implement classes and message passing for Objective C.
    Copyright (C) 1992, 1993, 1994, 1995, 1997, 1998, 1999, 2000,
-   2001, 2002, 2003, 2004, 2005, 2007 Free Software Foundation, Inc.
+   2001, 2002, 2003, 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
    Contributed by Steve Naroff.
 
 This file is part of GCC.
@@ -484,13 +484,6 @@
 #endif
     return false;
 
-#ifndef USE_MAPPED_LOCATION
-  /* Force the line number back to 0; check_newline will have
-     raised it to 1, which will make the builtin functions appear
-     not to be built in.  */
-  input_line = 0;
-#endif
-
   /* If gen_declaration desired, open the output file.  */
   if (flag_gen_declaration)
     {
Index: toplev.c
===================================================================
--- toplev.c	(revision 132558)
+++ toplev.c	(working copy)
@@ -1,6 +1,6 @@
 /* Top level of GCC compilers (cc1, cc1plus, etc.)
    Copyright (C) 1987, 1988, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -134,10 +134,6 @@
 
 const char *main_input_filename;
 
-#ifndef USE_MAPPED_LOCATION
-location_t unknown_location = { NULL, 0 };
-#endif
-
 /* Used to enable -fvar-tracking, -fweb and -frename-registers according
    to optimize and default_debug_hooks in process_options ().  */
 #define AUTODETECT_VALUE 2
@@ -962,11 +958,7 @@
    INPUT_LOCATION accordingly.  */
 
 void
-#ifdef USE_MAPPED_LOCATION
 push_srcloc (location_t fline)
-#else
-push_srcloc (const char *file, int line)
-#endif
 {
   struct file_stack *fs;
 
@@ -977,12 +969,7 @@
   fs = XNEW (struct file_stack);
   fs->location = input_location;
   fs->next = input_file_stack;
-#ifdef USE_MAPPED_LOCATION
   input_location = fline;
-#else
-  input_filename = file;
-  input_line = line;
-#endif
   input_file_stack = fs;
   input_file_stack_tick++;
   VEC_safe_push (fs_p, heap, input_file_stack_history, input_file_stack);
@@ -1732,9 +1719,6 @@
      sets the original filename if appropriate (e.g. foo.i -> foo.c)
      so we can correctly initialize debug output.  */
   no_backend = lang_hooks.post_options (&main_input_filename);
-#ifndef USE_MAPPED_LOCATION
-  input_filename = main_input_filename;
-#endif
 
 #ifdef OVERRIDE_OPTIONS
   /* Some machines may reject certain combinations of options.  */
@@ -2121,12 +2105,7 @@
     dump_base_name = name && name[0] ? name : "gccdump";
 
   /* Other front-end initialization.  */
-#ifdef USE_MAPPED_LOCATION
   input_location = BUILTINS_LOCATION;
-#else
-  input_filename = "<built-in>";
-  input_line = 0;
-#endif
   if (lang_hooks.init () == 0)
     return 0;
   input_location = save_loc;
Index: cp/decl.c
===================================================================
--- cp/decl.c	(revision 132558)
+++ cp/decl.c	(working copy)
@@ -357,12 +357,7 @@
 	  location_t location;
 
 	  error ("label %q+D used but not defined", label);
-#ifdef USE_MAPPED_LOCATION
 	  location = input_location; /* FIXME want (input_filename, (line)0) */
-#else
-	  location.file = input_filename;
-	  location.line = 0;
-#endif
 	  /* Avoid crashing later.  */
 	  define_label (location, DECL_NAME (label));
 	}
@@ -11806,14 +11801,10 @@
 	  /* Hack.  We don't want the middle-end to warn that this
 	     return is unreachable, so put the statement on the
 	     special line 0.  */
-#ifdef USE_MAPPED_LOCATION
 	  {
 	    location_t linezero = linemap_line_start (line_table, 0, 1);
 	    SET_EXPR_LOCATION (stmt, linezero);
 	  }
-#else
-	  annotate_with_file_line (stmt, input_filename, 0);
-#endif
 	}
 
       if (use_eh_spec_block (current_function_decl))
Index: cp/error.c
===================================================================
--- cp/error.c	(revision 132558)
+++ cp/error.c	(working copy)
@@ -2468,14 +2468,12 @@
 		  pp_base_newline (context->printer);
 		  if (s.file != NULL)
 		    {
-#ifdef USE_MAPPED_LOCATION
 		      if (flag_show_column && s.column != 0)
 			pp_printf (context->printer,
 				   "    inlined from %qs at %s:%d:%d",
 				   cxx_printable_name (fndecl, 2),
 				   s.file, s.line, s.column);
 		      else
-#endif
 			pp_printf (context->printer,
 				   "    inlined from %qs at %s:%d",
 				   cxx_printable_name (fndecl, 2),
Index: cp/pt.c
===================================================================
--- cp/pt.c	(revision 132558)
+++ cp/pt.c	(working copy)
@@ -9156,13 +9156,7 @@
 	       message to avoid spewing a ton of messages during a
 	       single bad template instantiation.  */
 	    if (complain & tf_error
-#ifdef USE_MAPPED_LOCATION
-		&& last_loc != input_location
-#else
-		&& (last_loc.line != input_line
-		    || last_loc.file != input_filename)
-#endif
-		  )
+		&& last_loc != input_location)
 	      {
 		if (TREE_CODE (type) == VOID_TYPE)
 		  error ("forming reference to void");
Index: cp/lex.c
===================================================================
--- cp/lex.c	(revision 132558)
+++ cp/lex.c	(working copy)
@@ -1,6 +1,6 @@
 /* Separate lexical analyzer for GNU C++.
    Copyright (C) 1987, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
    Free Software Foundation, Inc.
    Hacked by Michael Tiemann (tiemann@cygnus.com)
 
@@ -385,14 +385,7 @@
   for (i = 0; i < ARRAY_SIZE (stmt_codes); i++)
     statement_code_p[stmt_codes[i]] = true;
 
-  /* We cannot just assign to input_filename because it has already
-     been initialized and will be used later as an N_BINCL for stabs+
-     debugging.  */
-#ifdef USE_MAPPED_LOCATION
   push_srcloc (BUILTINS_LOCATION);
-#else
-  push_srcloc ("<built-in>", 0);
-#endif
 
   init_reswords ();
   init_tree ();
@@ -572,17 +565,9 @@
   else
     {
       filename = ggc_strdup (TREE_STRING_POINTER (fname));
-#ifdef USE_MAPPED_LOCATION
-      /* We currently cannot give this diagnostic, as we reach this point
-	 only after cpplib has scanned the entire translation unit, so
-	 cpp_included always returns true.  A plausible fix is to compare
-	 the current source-location cookie with the first source-location
-	 cookie (if any) of the filename, but this requires completing the
-	 --enable-mapped-location project first.  See PR 17577.  */
       if (cpp_included_before (parse_in, filename, input_location))
 	warning (0, "#pragma implementation for %qs appears after "
 		 "file is included", filename);
-#endif
     }
 
   for (; ifiles; ifiles = ifiles->next)
Index: cp/decl2.c
===================================================================
--- cp/decl2.c	(revision 132558)
+++ cp/decl2.c	(working copy)
@@ -1,6 +1,6 @@
 /* Process declarations and variables for C++ compiler.
    Copyright (C) 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007  Free Software Foundation, Inc.
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008  Free Software Foundation, Inc.
    Hacked by Michael Tiemann (tiemann@cygnus.com)
 
 This file is part of GCC.
@@ -2995,11 +2995,8 @@
   size_t i;
 
   input_location = *locus;
-#ifdef USE_MAPPED_LOCATION
   /* ??? */
-#else
-  locus->line++;
-#endif
+  /* Was: locus->line++; */
 
   /* We use `I' to indicate initialization and `D' to indicate
      destruction.  */
@@ -3179,13 +3176,7 @@
   if (pch_file)
     c_common_write_pch ();
 
-#ifdef USE_MAPPED_LOCATION
-  /* FIXME - huh? */
-#else
-  /* Otherwise, GDB can get confused, because in only knows
-     about source for LINENO-1 lines.  */
-  input_line -= 1;
-#endif
+  /* FIXME - huh?  was  input_line -= 1;*/
 
   /* We now have to write out all the stuff we put off writing out.
      These include:
@@ -3318,11 +3309,7 @@
 	     instantiations, etc.  */
 	  reconsider = true;
 	  ssdf_count++;
-#ifdef USE_MAPPED_LOCATION
-	  /* ??? */
-#else
-	  locus.line++;
-#endif
+	  /* ??? was:  locus.line++; */
 	}
 
       /* Go through the set of inline functions whose bodies have not
Index: cp/parser.c
===================================================================
--- cp/parser.c	(revision 132558)
+++ cp/parser.c	(working copy)
@@ -100,11 +100,7 @@
 static cp_token eof_token =
 {
   CPP_EOF, RID_MAX, 0, PRAGMA_NONE, 0, 0, false, 0, { NULL },
-#if USE_MAPPED_LOCATION
   0
-#else
-  {0, 0}
-#endif
 };
 
 /* The cp_lexer structure represents the C++ lexer.  It is responsible
@@ -7206,10 +7202,7 @@
 
   semi_loc =  expand_location (token->location);
   if (close_loc.line == semi_loc.line
-#ifdef USE_MAPPED_LOCATION
-      && close_loc.column+1 == semi_loc.column
-#endif
-      )
+      && close_loc.column+1 == semi_loc.column)
     warning (OPT_Wempty_body,
 	     "suggest a space before %<;%> or explicit braces around empty "
 	     "body in %<%s%> statement",
Index: gimple-low.c
===================================================================
--- gimple-low.c	(revision 132558)
+++ gimple-low.c	(working copy)
@@ -1,6 +1,6 @@
 /* Tree lowering pass.  Lowers GIMPLE into unstructured form.
 
-   Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -108,11 +108,7 @@
 	 It now fills in for many such returns.  Failure to remove this
 	 will result in incorrect results for coverage analysis.  */
       x = TREE_VALUE (t);
-#ifdef USE_MAPPED_LOCATION
       SET_EXPR_LOCATION (x, UNKNOWN_LOCATION);
-#else
-      SET_EXPR_LOCUS (x, NULL);
-#endif
       tsi_link_after (&i, x, TSI_CONTINUE_LINKING);
     }
 
Index: rtl.def
===================================================================
--- rtl.def	(revision 132558)
+++ rtl.def	(working copy)
@@ -2,7 +2,7 @@
    Register Transfer Expressions (rtx's) that make up the
    Register Transfer Language (rtl) used in the Back End of the GNU compiler.
    Copyright (C) 1987, 1988, 1992, 1994, 1995, 1997, 1998, 1999, 2000, 2004,
-   2005, 2006, 2007
+   2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -159,7 +159,6 @@
 /* Several operations to be done in parallel (perhaps under COND_EXEC).  */
 DEF_RTL_EXPR(PARALLEL, "parallel", "E", RTX_EXTRA)
 
-#ifdef USE_MAPPED_LOCATION
 /* A string that is passed through to the assembler as input.
      One can obviously pass comments through by using the
      assembler comment syntax.
@@ -180,30 +179,7 @@
      and whose mode indicates the mode of the input operand.
    6th is the source line number.  */
 DEF_RTL_EXPR(ASM_OPERANDS, "asm_operands", "ssiEEi", RTX_EXTRA)
-#else
-/* A string that is passed through to the assembler as input.
-     One can obviously pass comments through by using the
-     assembler comment syntax.
-     These occur in an insn all by themselves as the PATTERN.
-     They also appear inside an ASM_OPERANDS
-     as a convenient way to hold a string.  */
-DEF_RTL_EXPR(ASM_INPUT, "asm_input", "ssi", RTX_EXTRA)
 
-/* An assembler instruction with operands.
-   1st operand is the instruction template.
-   2nd operand is the constraint for the output.
-   3rd operand is the number of the output this expression refers to.
-     When an insn stores more than one value, a separate ASM_OPERANDS
-     is made for each output; this integer distinguishes them.
-   4th is a vector of values of input operands.
-   5th is a vector of modes and constraints for the input operands.
-     Each element is an ASM_INPUT containing a constraint string
-     and whose mode indicates the mode of the input operand.
-   6th is the name of the containing source file.
-   7th is the source line number.  */
-DEF_RTL_EXPR(ASM_OPERANDS, "asm_operands", "ssiEEsi", RTX_EXTRA)
-#endif
-
 /* A machine-specific operation.
    1st operand is a vector of operands being used by the operation so that
      any needed reloads can be done.
Index: config.in
===================================================================
--- config.in	(revision 132558)
+++ config.in	(working copy)
@@ -1448,12 +1448,6 @@
 #endif
 
 
-/* Define if location_t is fileline integer cookie. */
-#ifndef USED_FOR_TARGET
-#undef USE_MAPPED_LOCATION
-#endif
-
-
 /* Define to be the last component of the Windows registry key under which to
    look for installation paths. The full key used will be
    HKEY_LOCAL_MACHINE/SOFTWARE/Free Software Foundation/{WIN32_REGISTRY_KEY}.
Index: c-pch.c
===================================================================
--- c-pch.c	(revision 132558)
+++ c-pch.c	(working copy)
@@ -1,5 +1,5 @@
 /* Precompiled header implementation for the C languages.
-   Copyright (C) 2000, 2002, 2003, 2004, 2005, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2000, 2002, 2003, 2004, 2005, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -409,16 +409,7 @@
     }
 
   /* Save the location and then restore it after reading the PCH.  */
-#ifdef USE_MAPPED_LOCATION
   saved_loc = expand_location (line_table->highest_line);
-#else
-  {
-    const struct line_map *map = linemap_lookup (line_table,
-						 line_table->highest_line);
-    saved_loc.file = map->to_file;
-    saved_loc.line = SOURCE_LINE (map, line_table->highest_line);
-  }
-#endif
 
   cpp_prepare_state (pfile, &smd);
 
Index: recog.c
===================================================================
--- recog.c	(revision 132558)
+++ recog.c	(working copy)
@@ -1,6 +1,6 @@
 /* Subroutines used by or related to instruction recognition.
    Copyright (C) 1987, 1988, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -1490,14 +1490,7 @@
     }
 
   if (loc)
-    {
-#ifdef USE_MAPPED_LOCATION
-      *loc = ASM_OPERANDS_SOURCE_LOCATION (asmop);
-#else
-      loc->file = ASM_OPERANDS_SOURCE_FILE (asmop);
-      loc->line = ASM_OPERANDS_SOURCE_LINE (asmop);
-#endif
-    }
+    *loc = ASM_OPERANDS_SOURCE_LOCATION (asmop);
 
   return ASM_OPERANDS_TEMPLATE (asmop);
 }
Index: ada/trans.c
===================================================================
--- ada/trans.c	(revision 132558)
+++ ada/trans.c	(working copy)
@@ -244,7 +244,6 @@
 
   type_annotate_only = (gigi_operating_mode == 1);
 
-#ifdef USE_MAPPED_LOCATION
   for (i = 0; i < number_files; i++)
     {
       /* Use the identifier table to make a permanent copy of the filename as
@@ -268,7 +267,6 @@
       linemap_position_for_column (line_table, 252 - 1);
       linemap_add (line_table, LC_LEAVE, 0, NULL, 0);
     }
-#endif
 
   /* Initialize ourselves.  */
   init_code_table ();
@@ -6650,7 +6648,6 @@
     return false;
 
   if (Sloc <= Standard_Location)
-#ifdef USE_MAPPED_LOCATION
     {
       *locus = BUILTINS_LOCATION;
       return false;
@@ -6667,23 +6664,7 @@
 		+ ((line - map->to_line) << map->column_bits)
 		+ (column & ((1 << map->column_bits) - 1));
     }
-#else
-  return false;
 
-  /* Use the identifier table to make a hashed, permanent copy of the filename,
-     since the name table gets reallocated after Gigi returns but before all
-     the debugging information is output. The __gnat_to_canonical_file_spec
-     call translates filenames from pragmas Source_Reference that contain host
-     style syntax not understood by gdb. */
-  locus->file
-    = IDENTIFIER_POINTER
-      (get_identifier
-       (__gnat_to_canonical_file_spec
-	(Get_Name_String (Full_Debug_Name (Get_Source_File_Index (Sloc))))));
-
-  locus->line = Get_Logical_Line_Number (Sloc);
-#endif
-
   ref_filename
     = IDENTIFIER_POINTER
       (get_identifier
Index: ada/misc.c
===================================================================
--- ada/misc.c	(revision 132558)
+++ ada/misc.c	(working copy)
@@ -412,11 +412,9 @@
   fp.Array = buffer;
 
   s = expand_location (input_location);
-#ifdef USE_MAPPED_LOCATION
   if (flag_show_column && s.column != 0)
     asprintf (&loc, "%s:%d:%d", s.file, s.line, s.column);
   else
-#endif
     asprintf (&loc, "%s:%d", s.file, s.line);
   temp_loc.Low_Bound = 1;
   temp_loc.High_Bound = strlen (loc);
Index: c-decl.c
===================================================================
--- c-decl.c	(revision 132558)
+++ c-decl.c	(working copy)
@@ -2760,12 +2760,7 @@
   /* Declarations from c_common_nodes_and_builtins must not be associated
      with this input file, lest we get differences between using and not
      using preprocessed headers.  */
-#ifdef USE_MAPPED_LOCATION
   input_location = BUILTINS_LOCATION;
-#else
-  input_location.file = "<built-in>";
-  input_location.line = 0;
-#endif
 
   build_common_tree_nodes (flag_signed_char, false);
 
@@ -6726,7 +6721,6 @@
 	  if (flag_isoc99)
 	    {
 	      tree stmt = c_finish_return (integer_zero_node);
-#ifdef USE_MAPPED_LOCATION
 	      /* Hack.  We don't want the middle-end to warn that this return
 		 is unreachable, so we mark its location as special.  Using
 		 UNKNOWN_LOCATION has the problem that it gets clobbered in
@@ -6734,12 +6728,6 @@
 		 ensure ! should_carry_locus_p (stmt), but that needs a flag.
 	      */
 	      SET_EXPR_LOCATION (stmt, BUILTINS_LOCATION);
-#else
-	      /* Hack.  We don't want the middle-end to warn that this
-		 return is unreachable, so put the statement on the
-		 special line 0.  */
-	      annotate_with_file_line (stmt, input_filename, 0);
-#endif
 	    }
 	}
     }
Index: fortran/gfortran.h
===================================================================
--- fortran/gfortran.h	(revision 132558)
+++ fortran/gfortran.h	(working copy)
@@ -1,5 +1,5 @@
 /* gfortran header file
-   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Andy Vaught
 
@@ -713,11 +713,7 @@
 
 typedef struct gfc_linebuf
 {
-#ifdef USE_MAPPED_LOCATION
   source_location location;
-#else
-  int linenum;
-#endif
   struct gfc_file *file;
   struct gfc_linebuf *next;
 
@@ -729,11 +725,7 @@
 
 #define gfc_linebuf_header_size (offsetof (gfc_linebuf, line))
 
-#ifdef USE_MAPPED_LOCATION
 #define gfc_linebuf_linenum(LBUF) (LOCATION_LINE ((LBUF)->location))
-#else
-#define gfc_linebuf_linenum(LBUF) ((LBUF)->linenum)
-#endif
 
 typedef struct
 {
Index: fortran/error.c
===================================================================
--- fortran/error.c	(revision 132558)
+++ fortran/error.c	(working copy)
@@ -1,5 +1,5 @@
 /* Handle errors.
-   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Andy Vaught & Niels Kristian Bech Jensen
 
@@ -182,11 +182,7 @@
   error_string (f->filename);
   error_char (':');
     
-#ifdef USE_MAPPED_LOCATION
   error_integer (LOCATION_LINE (lb->location));
-#else
-  error_integer (lb->linenum);
-#endif
 
   if ((c1 > 0) || (c2 > 0))
     error_char ('.');
Index: fortran/data.c
===================================================================
--- fortran/data.c	(revision 132558)
+++ fortran/data.c	(working copy)
@@ -1,5 +1,5 @@
 /* Supporting functions for resolving DATA statement.
-   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Lifang Zeng <zlf605@hotmail.com>
 
@@ -424,14 +424,9 @@
 	  /* Order in which the expressions arrive here depends on whether
 	     they are from data statements or F95 style declarations.
 	     Therefore, check which is the most recent.  */
-#ifdef USE_MAPPED_LOCATION
 	  expr = (LOCATION_LINE (init->where.lb->location)
 		  > LOCATION_LINE (rvalue->where.lb->location))
 	       ? init : rvalue;
-#else
-	  expr = (init->where.lb->linenum > rvalue->where.lb->linenum)
-	       ? init : rvalue;
-#endif
 	  gfc_notify_std (GFC_STD_GNU, "Extension: re-initialization "
 			  "of '%s' at %L", symbol->name, &expr->where);
 	}
Index: fortran/trans.c
===================================================================
--- fortran/trans.c	(revision 132558)
+++ fortran/trans.c	(working copy)
@@ -1,5 +1,5 @@
 /* Code translation -- generate GCC trees from gfc_code.
-   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Free Software
+   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software
    Foundation, Inc.
    Contributed by Paul Brook
 
@@ -382,11 +382,7 @@
 
   if (where)
     {
-#ifdef USE_MAPPED_LOCATION
       line = LOCATION_LINE (where->lb->location);
-#else 
-      line = where->lb->linenum;
-#endif
       asprintf (&message, "At line %d of file %s",  line,
 		where->lb->file->filename);
     }
@@ -937,11 +933,7 @@
 gfc_get_backend_locus (locus * loc)
 {
   loc->lb = gfc_getmem (sizeof (gfc_linebuf));    
-#ifdef USE_MAPPED_LOCATION
   loc->lb->location = input_location;
-#else
-  loc->lb->linenum = input_line;
-#endif
   loc->lb->file = gfc_current_backend_file;
 }
 
@@ -952,12 +944,7 @@
 gfc_set_backend_locus (locus * loc)
 {
   gfc_current_backend_file = loc->lb->file;
-#ifdef USE_MAPPED_LOCATION
   input_location = loc->lb->location;
-#else
-  input_line = loc->lb->linenum;
-  input_filename = loc->lb->file->filename;
-#endif
 }
 
 
Index: fortran/scanner.c
===================================================================
--- fortran/scanner.c	(revision 132558)
+++ fortran/scanner.c	(working copy)
@@ -1,5 +1,5 @@
 /* Character scanner.
-   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Andy Vaught
 
@@ -1064,11 +1064,7 @@
 	 line will be scanned multiple times.  */
       if (!gfc_option.warn_tabs && c == '\t')
 	{
-#ifdef USE_MAPPED_LOCATION
 	  int cur_linenum = LOCATION_LINE (gfc_current_locus.lb->location);
-#else
-	  int cur_linenum = gfc_current_locus.lb->linenum;
-#endif
 	  if (cur_linenum != linenum)
 	    {
 	      linenum = cur_linenum;
@@ -1285,9 +1281,7 @@
   if (current_file != NULL)
     f->inclusion_line = current_file->line;
 
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, reason, false, f->filename, 1);
-#endif
 
   return f;
 }
@@ -1412,10 +1406,8 @@
 
       add_file_change (NULL, line);
       current_file = current_file->up;
-#ifdef USE_MAPPED_LOCATION
       linemap_add (line_table, LC_RENAME, false, current_file->filename,
 		   current_file->line);
-#endif
     }
 
   /* The name of the file can be a temporary file produced by
@@ -1645,12 +1637,8 @@
 
       b = gfc_getmem (gfc_linebuf_header_size + len + 1);
 
-#ifdef USE_MAPPED_LOCATION
       b->location
 	= linemap_line_start (line_table, current_file->line++, 120);
-#else
-      b->linenum = current_file->line++;
-#endif
       b->file = current_file;
       b->truncated = trunc;
       strcpy (b->line, line);
@@ -1674,9 +1662,7 @@
   if (!initial)
     add_file_change (NULL, current_file->inclusion_line + 1);
   current_file = current_file->up;
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_LEAVE, 0, NULL, 0);
-#endif
   return SUCCESS;
 }
 
@@ -1699,13 +1685,8 @@
 #if 0 /* Debugging aid.  */
   for (; line_head; line_head = line_head->next)
     gfc_status ("%s:%3d %s\n",
-#ifdef USE_MAPPED_LOCATION
 		LOCATION_FILE (line_head->location),
 		LOCATION_LINE (line_head->location),
-#else
-		line_head->file->filename, 
-		line_head->linenum,
-#endif
 		line_head->line);
 
   exit (0);
Index: fortran/f95-lang.c
===================================================================
--- fortran/f95-lang.c	(revision 132558)
+++ fortran/f95-lang.c	(working copy)
@@ -1,5 +1,5 @@
 /* gfortran backend interface
-   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Paul Brook.
 
@@ -275,10 +275,8 @@
 static bool
 gfc_init (void)
 {
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_ENTER, false, gfc_source_file, 1);
   linemap_add (line_table, LC_RENAME, false, "<built-in>", 0);
-#endif
 
   /* First initialize the backend.  */
   gfc_init_decl_processing ();
Index: fortran/trans-decl.c
===================================================================
--- fortran/trans-decl.c	(revision 132558)
+++ fortran/trans-decl.c	(working copy)
@@ -1,5 +1,5 @@
 /* Backend function setup
-   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Free Software
+   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software
    Foundation, Inc.
    Contributed by Paul Brook
 
@@ -228,12 +228,7 @@
 void
 gfc_set_decl_location (tree decl, locus * loc)
 {
-#ifdef USE_MAPPED_LOCATION
   DECL_SOURCE_LOCATION (decl) = loc->lb->location;
-#else
-  DECL_SOURCE_LINE (decl) = loc->lb->linenum;
-  DECL_SOURCE_FILE (decl) = loc->lb->file->filename;
-#endif
 }
 
 
Index: fortran/trans-io.c
===================================================================
--- fortran/trans-io.c	(revision 132558)
+++ fortran/trans-io.c	(working copy)
@@ -1,5 +1,5 @@
 /* IO Code translation/library interface
-   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Free Software
+   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software
    Foundation, Inc.
    Contributed by Paul Brook
 
@@ -848,11 +848,7 @@
   str = gfc_build_addr_expr (pchar_type_node, str);
   gfc_add_modify_expr (block, locus_file, str);
 
-#ifdef USE_MAPPED_LOCATION
   line = LOCATION_LINE (where->lb->location);
-#else
-  line = where->lb->linenum;
-#endif
   set_parameter_const (block, var, IOPARM_common_line, line);
 }
 
Index: configure.ac
===================================================================
--- configure.ac	(revision 132558)
+++ configure.ac	(working copy)
@@ -523,15 +523,6 @@
 AC_SUBST(valgrind_path_defines)
 AC_SUBST(valgrind_command)
 
-AC_ARG_ENABLE(mapped-location,
-[  --enable-mapped-location   location_t is fileline integer cookie],,
-enable_mapped_location=yes)
-
-if test "$enable_mapped_location" = yes ; then
-  AC_DEFINE(USE_MAPPED_LOCATION, 1,
-[Define if location_t is fileline integer cookie.])
-fi
-
 # Enable code coverage collection
 AC_ARG_ENABLE(coverage,
 [  --enable-coverage[=LEVEL]
Index: langhooks.c
===================================================================
--- langhooks.c	(revision 132558)
+++ langhooks.c	(working copy)
@@ -1,5 +1,5 @@
 /* Default language-specific hooks.
-   Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Alexandre Oliva  <aoliva@redhat.com>
 
@@ -455,14 +455,12 @@
 		  pp_newline (context->printer);
 		  if (s.file != NULL)
 		    {
-#ifdef USE_MAPPED_LOCATION
 		      if (flag_show_column && s.column != 0)
 			pp_printf (context->printer,
 				   _("    inlined from %qs at %s:%d:%d"),
 				   lang_hooks.decl_printable_name (fndecl, 2),
 				   s.file, s.line, s.column);
 		      else
-#endif
 			pp_printf (context->printer,
 				   _("    inlined from %qs at %s:%d"),
 				   lang_hooks.decl_printable_name (fndecl, 2),
Index: tree-vectorizer.h
===================================================================
--- tree-vectorizer.h	(revision 132558)
+++ tree-vectorizer.h	(working copy)
@@ -1,5 +1,5 @@
 /* Loop Vectorization
-   Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
    Contributed by Dorit Naishlos <dorit@il.ibm.com>
 
 This file is part of GCC.
@@ -21,19 +21,11 @@
 #ifndef GCC_TREE_VECTORIZER_H
 #define GCC_TREE_VECTORIZER_H
 
-#ifdef USE_MAPPED_LOCATION
-  typedef source_location LOC;
-  #define UNKNOWN_LOC UNKNOWN_LOCATION
-  #define EXPR_LOC(e) EXPR_LOCATION(e)
-  #define LOC_FILE(l) LOCATION_FILE (l)
-  #define LOC_LINE(l) LOCATION_LINE (l)
-#else
-  typedef source_locus LOC;
-  #define UNKNOWN_LOC NULL
-  #define EXPR_LOC(e) EXPR_LOCUS(e)
-  #define LOC_FILE(l) (l)->file
-  #define LOC_LINE(l) (l)->line
-#endif
+typedef source_location LOC;
+#define UNKNOWN_LOC UNKNOWN_LOCATION
+#define EXPR_LOC(e) EXPR_LOCATION(e)
+#define LOC_FILE(l) LOCATION_FILE (l)
+#define LOC_LINE(l) LOCATION_LINE (l)
 
 /* Used for naming of new temporaries.  */
 enum vect_var_kind {
Index: profile.c
===================================================================
--- profile.c	(revision 132558)
+++ profile.c	(working copy)
@@ -1,6 +1,6 @@
 /* Calculate branch probabilities, and basic block execution counts.
    Copyright (C) 1990, 1991, 1992, 1993, 1994, 1996, 1997, 1998, 1999,
-   2000, 2001, 2002, 2003, 2004, 2005, 2007
+   2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by James E. Wilson, UC Berkeley/Cygnus Support;
    based on some ideas from Dain Samples of UC Berkeley.
@@ -814,15 +814,10 @@
 	  if (last && EXPR_LOCUS (last)
 	      && e->goto_locus
 	      && !single_succ_p (bb)
-#ifdef USE_MAPPED_LOCATION
 	      && (LOCATION_FILE (e->goto_locus)
 	          != LOCATION_FILE (EXPR_LOCATION  (last))
 		  || (LOCATION_LINE (e->goto_locus)
 		      != LOCATION_LINE (EXPR_LOCATION  (last)))))
-#else
-	      && (e->goto_locus->file != EXPR_LOCUS (last)->file
-		  || (e->goto_locus->line != EXPR_LOCUS (last)->line)))
-#endif
 	    {
 	      basic_block new = split_edge (e);
 	      single_succ_edge (new)->goto_locus = e->goto_locus;
@@ -1020,16 +1015,10 @@
 	     CFG.  */
 	  if (single_succ_p (bb) && single_succ_edge (bb)->goto_locus)
 	    {
-	      /* ??? source_locus type is marked deprecated in input.h.  */
-	      source_locus curr_location = single_succ_edge (bb)->goto_locus;
+	      location_t curr_location = single_succ_edge (bb)->goto_locus;
 	      /* ??? The FILE/LINE API is inconsistent for these cases.  */
-#ifdef USE_MAPPED_LOCATION 
 	      output_location (LOCATION_FILE (curr_location),
 			       LOCATION_LINE (curr_location), &offset, bb);
-#else
-	      output_location (curr_location->file, curr_location->line,
-			       &offset, bb);
-#endif
 	    }
 
 	  if (offset)
Index: treelang/lex.l
===================================================================
--- treelang/lex.l	(revision 132558)
+++ treelang/lex.l	(working copy)
@@ -5,7 +5,7 @@
    ---------------------------------------------------------------------
 
    Copyright (C) 1986, 87, 89, 92-96, 1997, 1999, 2000, 2001, 2002, 2003,
-   2004, 2005, 2007 Free Software Foundation, Inc.
+   2004, 2005, 2007, 2008 Free Software Foundation, Inc.
    
    This program is free software; you can redistribute it and/or modify it 
    under the terms of the GNU General Public License as published by the
@@ -59,10 +59,6 @@
    {fprintf (stderr, "\nlexer returning"); dump_lex_value (a);} return a;}
 #define NOT_RETURN(a) {update_yylval (a); if (option_lexer_trace)\
    {fprintf (stderr, "\nlexer swallowing"); dump_lex_value (a);}}
-#ifndef USE_MAPPED_LOCATION
-#undef LINEMAP_POSITION_FOR_COLUMN
-#define LINEMAP_POSITION_FOR_COLUMN(INPUT, LINETABLE, COL)
-#endif
 %}
 
 %option nostack
@@ -242,13 +238,9 @@
       {
          if ( yytext[yyl] == '\n' ) 
             {
-#ifdef USE_MAPPED_LOCATION
 	      source_location s = linemap_line_start (line_table, ++lineno,
 						      80);
 	      input_location = s;
-#else
-	      input_line = ++lineno;
-#endif
 	      next_tree_charno = 1;
             } 
          else 
Index: treelang/tree1.c
===================================================================
--- treelang/tree1.c	(revision 132558)
+++ treelang/tree1.c	(working copy)
@@ -2,7 +2,7 @@
    Called by GCC's toplev.c
 
    Copyright (C) 1986, 87, 89, 92-96, 1997, 1999, 2000, 2001, 2002, 2003, 2004,
-   2007  Free Software Foundation, Inc.
+   2007, 2008  Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -139,11 +139,7 @@
 bool
 treelang_init (void)
 {
-#ifndef USE_MAPPED_LOCATION
-  input_filename = main_input_filename;
-#else
   linemap_add (line_table, LC_ENTER, false, main_input_filename, 1);
-#endif
 
   /* This error will not happen from GCC as it will always create a
      fake input file.  */
@@ -165,10 +161,8 @@
       exit (1);
     }
 
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_RENAME, false, "<built-in>", 1);
   linemap_line_start (line_table, 0, 1);
-#endif
 
   /* Init decls, etc.  */
   treelang_init_decl_processing ();
@@ -189,21 +183,15 @@
 void
 treelang_parse_file (int debug_flag ATTRIBUTE_UNUSED)
 {
-#ifdef USE_MAPPED_LOCATION
   source_location s;
   linemap_add (line_table, LC_RENAME, false, main_input_filename, 1);
   s = linemap_line_start (line_table, 1, 80);
   input_location = s;
-#else
-  input_line = 1;
-#endif
 
   treelang_debug ();
   yyparse ();
   cgraph_finalize_compilation_unit ();
-#ifdef USE_MAPPED_LOCATION
   linemap_add (line_table, LC_LEAVE, false, NULL, 0);
-#endif
   cgraph_optimize ();
 }
 
Index: emit-rtl.c
===================================================================
--- emit-rtl.c	(revision 132558)
+++ emit-rtl.c	(working copy)
@@ -1,6 +1,6 @@
 /* Emit RTL for the GCC expander.
    Copyright (C) 1987, 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -4533,11 +4533,7 @@
 void
 force_next_line_note (void)
 {
-#ifdef USE_MAPPED_LOCATION
   last_location = -1;
-#else
-  last_location.line = -1;
-#endif
 }
 
 /* Place a note of KIND on insn INSN with DATUM as the datum. If a
Index: cfgexpand.c
===================================================================
--- cfgexpand.c	(revision 132558)
+++ cfgexpand.c	(working copy)
@@ -1,5 +1,5 @@
 /* A pass for lowering trees to RTL.
-   Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -1316,7 +1316,7 @@
       add_reg_br_prob_note (last, true_edge->probability);
       maybe_dump_rtl_for_tree_stmt (stmt, last);
       if (true_edge->goto_locus)
-  	set_curr_insn_source_location (location_from_locus (true_edge->goto_locus));
+  	set_curr_insn_source_location (true_edge->goto_locus);
       false_edge->flags |= EDGE_FALLTHRU;
       return NULL;
     }
@@ -1326,7 +1326,7 @@
       add_reg_br_prob_note (last, false_edge->probability);
       maybe_dump_rtl_for_tree_stmt (stmt, last);
       if (false_edge->goto_locus)
-  	set_curr_insn_source_location (location_from_locus (false_edge->goto_locus));
+  	set_curr_insn_source_location (false_edge->goto_locus);
       true_edge->flags |= EDGE_FALLTHRU;
       return NULL;
     }
@@ -1357,7 +1357,7 @@
   maybe_dump_rtl_for_tree_stmt (stmt, last2);
 
   if (false_edge->goto_locus)
-    set_curr_insn_source_location (location_from_locus (false_edge->goto_locus));
+    set_curr_insn_source_location (false_edge->goto_locus);
 
   return new_bb;
 }
@@ -1624,7 +1624,7 @@
     {
       emit_jump (label_rtx_for_bb (e->dest));
       if (e->goto_locus)
-        set_curr_insn_source_location (location_from_locus (e->goto_locus));
+        set_curr_insn_source_location (e->goto_locus);
       e->flags &= ~EDGE_FALLTHRU;
     }
 
@@ -1724,11 +1724,7 @@
 
   /* Make sure the locus is set to the end of the function, so that
      epilogue line numbers and warnings are set properly.  */
-#ifdef USE_MAPPED_LOCATION
   if (cfun->function_end_locus != UNKNOWN_LOCATION)
-#else
-  if (cfun->function_end_locus.file)
-#endif
     input_location = cfun->function_end_locus;
 
   /* The following insns belong to the top scope.  */
Index: tree-mudflap.c
===================================================================
--- tree-mudflap.c	(revision 132558)
+++ tree-mudflap.c	(working copy)
@@ -1,5 +1,5 @@
 /* Mudflap: narrow-pointer bounds-checking by tree rewriting.
-   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
    Contributed by Frank Ch. Eigler <fche@redhat.com>
    and Graydon Hoare <graydon@redhat.com>
@@ -121,9 +121,7 @@
     const char *sourcefile;
     unsigned sourceline = xloc.line;
     unsigned sourcecolumn = 0;
-#ifdef USE_MAPPED_LOCATION
     sourcecolumn = xloc.column;
-#endif
     sourcefile = xloc.file;
     if (sourcefile == NULL && current_function_decl != NULL_TREE)
       sourcefile = DECL_SOURCE_FILE (current_function_decl);
@@ -214,11 +212,9 @@
 
   if (xloc.line > 0)
     {
-#ifdef USE_MAPPED_LOCATION
       if (xloc.column > 0)
         sprintf (linecolbuf, "%d:%d", xloc.line, xloc.column);
       else
-#endif
         sprintf (linecolbuf, "%d", xloc.line);
       colon = ":";
       line = linecolbuf;
Index: print-tree.c
===================================================================
--- print-tree.c	(revision 132558)
+++ print-tree.c	(working copy)
@@ -1,6 +1,6 @@
 /* Prints out tree in human readable form - GCC
    Copyright (C) 1990, 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-   2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -442,10 +442,8 @@
 
 
       xloc = expand_location (DECL_SOURCE_LOCATION (node));
-      fprintf (file, " file %s line %d", xloc.file, xloc.line);
-#ifdef USE_MAPPED_LOCATION
-      fprintf (file, " col %d", xloc.column);
-#endif
+      fprintf (file, " file %s line %d col %d", xloc.file, xloc.line,
+	       xloc.column);
 
       if (CODE_CONTAINS_STRUCT (code, TS_DECL_COMMON))
 	{	  
@@ -949,10 +947,7 @@
     {
       expanded_location xloc = expand_location (EXPR_LOCATION (node));
       indent_to (file, indent+4);
-      fprintf (file, "%s:%d", xloc.file, xloc.line);
-#ifdef USE_MAPPED_LOCATION
-      fprintf (file, ":%d", xloc.column);
-#endif
+      fprintf (file, "%s:%d:%d", xloc.file, xloc.line, xloc.column);
     }
 
   fprintf (file, ">");
Index: cfglayout.c
===================================================================
--- cfglayout.c	(revision 132558)
+++ cfglayout.c	(working copy)
@@ -1,5 +1,5 @@
 /* Basic block reordering routines for the GNU compiler.
-   Copyright (C) 2000, 2001, 2003, 2004, 2005, 2006, 2007
+   Copyright (C) 2000, 2001, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -255,13 +255,8 @@
   locations_locators_locs = VEC_alloc (int, heap, 32);
   locations_locators_vals = VEC_alloc (location_t, heap, 32);
 
-#ifdef USE_MAPPED_LOCATION
   last_location = -1;
   curr_location = -1;
-#else
-  last_location.line = -1;
-  curr_location.line = -1;
-#endif
   curr_block = NULL;
   last_block = NULL;
   curr_rtl_loc = 0;
@@ -284,15 +279,8 @@
      time locators are not initialized.  */
   if (curr_rtl_loc == -1)
     return;
-#ifdef USE_MAPPED_LOCATION
   if (location == last_location)
     return;
-#else
-  if (location.file && last_location.file
-      && !strcmp (location.file, last_location.file)
-      && location.line == last_location.line)
-    return;
-#endif
   curr_location = location;
 }
 
@@ -321,12 +309,7 @@
       VEC_safe_push (tree, gc, block_locators_blocks, curr_block);
       last_block = curr_block;
     }
-#ifdef USE_MAPPED_LOCATION
   if (last_location != curr_location)
-#else
-  if (last_location.file != curr_location.file
-      || last_location.line != curr_location.line)
-#endif
     {
       curr_rtl_loc++;
       VEC_safe_push (int, heap, locations_locators_locs, curr_rtl_loc);
Index: rtl.h
===================================================================
--- rtl.h	(revision 132558)
+++ rtl.h	(working copy)
@@ -1,6 +1,6 @@
 /* Register Transfer Language (RTL) definitions for GCC
    Copyright (C) 1987, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007
+   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -1114,15 +1114,8 @@
   XSTR (XCVECEXP (RTX, 4, N, ASM_OPERANDS), 0)
 #define ASM_OPERANDS_INPUT_MODE(RTX, N)  \
   GET_MODE (XCVECEXP (RTX, 4, N, ASM_OPERANDS))
-#ifdef USE_MAPPED_LOCATION
 #define ASM_OPERANDS_SOURCE_LOCATION(RTX) XCUINT (RTX, 5, ASM_OPERANDS)
 #define ASM_INPUT_SOURCE_LOCATION(RTX) XCUINT (RTX, 1, ASM_INPUT)
-#else
-#define ASM_OPERANDS_SOURCE_FILE(RTX) XCSTR (RTX, 5, ASM_OPERANDS)
-#define ASM_OPERANDS_SOURCE_LINE(RTX) XCINT (RTX, 6, ASM_OPERANDS)
-#define ASM_INPUT_SOURCE_FILE(RTX) XCSTR (RTX, 1, ASM_INPUT)
-#define ASM_INPUT_SOURCE_LINE(RTX) XCINT (RTX, 2, ASM_INPUT)
-#endif
 
 /* 1 if RTX is a mem that is statically allocated in read-only memory.  */
 #define MEM_READONLY_P(RTX) \
@@ -1892,21 +1885,11 @@
 #ifndef GENERATOR_FILE
 #include "genrtl.h"
 #undef gen_rtx_ASM_INPUT
-#ifdef USE_MAPPED_LOCATION
 #define gen_rtx_ASM_INPUT(MODE, ARG0)				\
   gen_rtx_fmt_si (ASM_INPUT, (MODE), (ARG0), 0)
 #define gen_rtx_ASM_INPUT_loc(MODE, ARG0, LOC)			\
   gen_rtx_fmt_si (ASM_INPUT, (MODE), (ARG0), (LOC))
-#else
-#define gen_rtx_ASM_INPUT(MODE, ARG0)				\
-  gen_rtx_fmt_ssi (ASM_INPUT, (MODE), (ARG0), "", 0)
-#define gen_rtx_ASM_INPUT_loc(MODE, ARG0, LOC)			\
-  gen_rtx_fmt_ssi (ASM_INPUT, (MODE), (ARG0), (LOC).file, (LOC).line)
-#undef gen_rtx_ASM_OPERANDS
-#define gen_rtx_ASM_OPERANDS(MODE, ARG0, ARG1, ARG2, ARG3, ARG4, LOC) \
-  gen_rtx_fmt_ssiEEsi (ASM_OPERANDS, (MODE), (ARG0), (ARG1), (ARG2), (ARG3), (ARG4), (LOC).file, (LOC).line)
 #endif
-#endif
 
 /* There are some RTL codes that require special attention; the
    generation functions included above do the raw handling.  If you
Index: tree-vect-transform.c
===================================================================
--- tree-vect-transform.c	(revision 132558)
+++ tree-vect-transform.c	(working copy)
@@ -1,5 +1,5 @@
 /* Transformation Utilities for Loop Vectorization.
-   Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc.
+   Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
    Contributed by Dorit Naishlos <dorit@il.ibm.com>
 
 This file is part of GCC.
@@ -2111,11 +2111,7 @@
   /* Make sure bsi points to the stmt that is being vectorized.  */
   gcc_assert (stmt == bsi_stmt (*bsi));
 
-#ifdef USE_MAPPED_LOCATION
   SET_EXPR_LOCATION (vec_stmt, EXPR_LOCATION (stmt));
-#else
-  SET_EXPR_LOCUS (vec_stmt, EXPR_LOCUS (stmt));
-#endif
 }
 
 
Index: system.h
===================================================================
--- system.h	(revision 132558)
+++ system.h	(working copy)
@@ -1,6 +1,6 @@
 /* Get common system includes and various definitions and declarations based
    on autoconf macros.
-   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007
+   Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
    Free Software Foundation, Inc.
 
 This file is part of GCC.
@@ -744,6 +744,9 @@
 	LANG_HOOKS_MAYBE_BUILD_CLEANUP LANG_HOOKS_UPDATE_DECL_AFTER_SAVING \
 	LANG_HOOKS_POPLEVEL LANG_HOOKS_TRUTHVALUE_CONVERSION
 
+/* Miscellaneous macros that are no longer used.  */
+ #pragma GCC poison USE_MAPPED_LOCATION
+
 /* Libiberty macros that are no longer used in GCC.  */
 #undef ANSI_PROTOTYPES
 #undef PTR_CONST
Index: c-common.c
===================================================================
--- c-common.c	(revision 132558)
+++ c-common.c	(working copy)
@@ -840,11 +840,7 @@
 	 it from appearing in the RTL.  */
       tree stmts;
       location_t saved_location = input_location;
-#ifdef USE_MAPPED_LOCATION
       input_location = UNKNOWN_LOCATION;
-#else
-      input_line = 0;
-#endif
 
       stmts = push_stmt_list ();
       decl = (*make_fname_decl) (id, fname_vars[ix].pretty);
Index: Makefile.in
===================================================================
--- Makefile.in	(revision 132558)
+++ Makefile.in	(working copy)
@@ -3087,8 +3087,8 @@
 	$(SHELL) $(srcdir)/../move-if-change tmp-constrs.h tm-constrs.h
 	$(STAMP) s-constrs-h
 
-GTFILES = $(srcdir)/input.h $(srcdir)/coretypes.h \
-  $(CPP_ID_DATA_H) $(host_xm_file_list) \
+GTFILES = $(CPP_ID_DATA_H) $(srcdir)/input.h $(srcdir)/coretypes.h \
+  $(host_xm_file_list) \
   $(tm_file_list) $(HASHTAB_H) $(SPLAY_TREE_H) $(srcdir)/bitmap.h \
   $(srcdir)/alias.h $(srcdir)/coverage.c $(srcdir)/rtl.h \
   $(srcdir)/optabs.h $(srcdir)/tree.h $(srcdir)/function.h $(srcdir)/libfuncs.h $(SYMTAB_H) \
Index: basic-block.h
===================================================================
--- basic-block.h	(revision 132558)
+++ basic-block.h	(working copy)
@@ -1,6 +1,6 @@
 /* Define control and data flow tables, and regsets.
    Copyright (C) 1987, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004,
-   2005, 2006, 2007 Free Software Foundation, Inc.
+   2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -130,7 +130,7 @@
   PTR GTY ((skip (""))) aux;
 
   /* Location of any goto implicit in the edge, during tree-ssa.  */
-  source_locus goto_locus;
+  location_t goto_locus;
 
   /* The index number corresponding to this edge in the edge vector
      dest->preds.  */
Index: tree-cfg.c
===================================================================
--- tree-cfg.c	(revision 132558)
+++ tree-cfg.c	(working copy)
@@ -628,20 +628,10 @@
   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 @@
     {
       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 @@
 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 @@
 	     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 @@
      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 @@
 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 @@
   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 @@
 	      && 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;
 	    }



More information about the Fortran mailing list