diff mbox

[Ada] Remove support for obsolete switch

Message ID 201010101517.50366.ebotcazou@adacore.com
State New
Headers show

Commit Message

Eric Botcazou Oct. 10, 2010, 1:17 p.m. UTC
This removes the support for the gdwarf+ switch, which was intended to enable 
some GNAT-specific extensions to DWARF.  They are now obsolete except for the 
AT_descriptive_type extension awaiting review at:
  http://gcc.gnu.org/ml/gcc-patches/2010-09/msg00148.html

Tested on i586-suse-linux, applied on the mainline.


2010-10-10  Olivier Hainque  <hainque@adacore.com>
            Eric Botcazou  <ebotcazou@adacore.com>

	* gcc-interface/lang.opt (gdwarf+): Remove.
	* gcc-interface/gigi.h (get_parallel_type): Likewise
	* gcc-interface/misc.c (gnat_dwarf_extensions): Likewise.
	(gnat_handle_option): Remove OPT_gdwarfplus case.
	(gnat_post_options): Remove setting of use_gnu_debug_info_extensions
	from gnat_dwarf_extensions.
	* gcc-interface/trans.c (gigi): Remove -gdwarf+ initializations.
	* gcc-interface/utils.c (get_parallel_type): Remove.

Comments

Joseph Myers Oct. 10, 2010, 2:52 p.m. UTC | #1
On Sun, 10 Oct 2010, Eric Botcazou wrote:

> This removes the support for the gdwarf+ switch, which was intended to enable 
> some GNAT-specific extensions to DWARF.  They are now obsolete except for the 

Then you should also remove the gdwarf+ special case in 
opt-functions.awk:opt_sanitized_name.
diff mbox

Patch

Index: gcc-interface/utils.c
===================================================================
--- gcc-interface/utils.c	(revision 165250)
+++ gcc-interface/utils.c	(working copy)
@@ -963,17 +963,6 @@  add_parallel_type (tree decl, tree paral
   SET_DECL_PARALLEL_TYPE (d, parallel_type);
 }
 
-/* Return the parallel type associated to a type, if any.  */
-
-tree
-get_parallel_type (tree type)
-{
-  if (TYPE_STUB_DECL (type))
-    return DECL_PARALLEL_TYPE (TYPE_STUB_DECL (type));
-  else
-    return NULL_TREE;
-}
-
 /* Utility function of above to merge LAST_SIZE, the previous size of a record
    with FIRST_BIT and SIZE that describe a field.  SPECIAL is true if this
    represents a QUAL_UNION_TYPE in which case we must look for COND_EXPRs and
Index: gcc-interface/lang.opt
===================================================================
--- gcc-interface/lang.opt	(revision 165234)
+++ gcc-interface/lang.opt	(working copy)
@@ -101,10 +101,6 @@  fRTS=
 Ada Joined RejectNegative
 ; Selects the runtime
 
-gdwarf+
-Ada
-; Explicit request for dwarf debug info with GNAT specific extensions.
-
 gant
 Ada Joined Undocumented
 ; Catches typos
Index: gcc-interface/gigi.h
===================================================================
--- gcc-interface/gigi.h	(revision 165250)
+++ gcc-interface/gigi.h	(working copy)
@@ -509,9 +509,6 @@  extern void rest_of_record_type_compilat
 /* Append PARALLEL_TYPE on the chain of parallel types for decl.  */
 extern void add_parallel_type (tree decl, tree parallel_type);
 
-/* Return the parallel type associated to a type, if any.  */
-extern tree get_parallel_type (tree type);
-
 /* Return a FUNCTION_TYPE node.  RETURN_TYPE is the type returned by the
    subprogram.  If it is VOID_TYPE, then we are dealing with a procedure,
    otherwise we are dealing with a function.  PARAM_DECL_LIST is a list of
Index: gcc-interface/trans.c
===================================================================
--- gcc-interface/trans.c	(revision 165253)
+++ gcc-interface/trans.c	(working copy)
@@ -286,18 +286,6 @@  gigi (Node_Id gnat_root, int max_gnat_no
       TYPE_SIZE_UNIT (void_type_node) = size_zero_node;
     }
 
-  /* If the GNU type extensions to DWARF are available, setup the hooks.  */
-#if defined (DWARF2_DEBUGGING_INFO) && defined (DWARF2_GNU_TYPE_EXTENSIONS)
-  /* We condition the name demangling and the generation of type encoding
-     strings on -gdwarf+ and always set descriptive types on.  */
-  if (use_gnu_debug_info_extensions)
-    {
-      dwarf2out_set_type_encoding_func (extract_encoding);
-      dwarf2out_set_demangle_name_func (decode_name);
-    }
-  dwarf2out_set_descriptive_type_func (get_parallel_type);
-#endif
-
   /* Enable GNAT stack checking method if needed */
   if (!Stack_Check_Probes_On_Target)
     set_stack_check_libfunc ("_gnat_stack_check");
Index: gcc-interface/misc.c
===================================================================
--- gcc-interface/misc.c	(revision 165250)
+++ gcc-interface/misc.c	(working copy)
@@ -59,12 +59,6 @@ 
 /* This symbol needs to be defined for the front-end.  */
 void *callgraph_info_file = NULL;
 
-/* How much we want of our DWARF extensions.  Some of our DWARF extensions
-   are incompatible with regular GDB versions, so we must make sure to only
-   produce them on explicit request.  This is eventually reflected into the
-   use_gnu_debug_info_extensions common flag for later processing.  */
-static int gnat_dwarf_extensions = 0;
-
 /* Command-line argc and argv.  These variables are global since they are
    imported in back_end.adb.  */
 unsigned int save_argc;
@@ -139,10 +133,6 @@  gnat_handle_option (size_t scode, const
       flag_eliminate_unused_debug_types = -value;
       break;
 
-    case OPT_gdwarfplus:
-      gnat_dwarf_extensions = 1;
-      break;
-
     case OPT_gant:
       warning (0, "%<-gnat%> misspelled as %<-gant%>");
 
@@ -260,11 +250,6 @@  gnat_post_options (const char **pfilenam
   else
     flag_eliminate_unused_debug_types = 0;
 
-  /* Reflect the explicit request of DWARF extensions into the common
-     flag for use by later passes.  */
-  if (write_symbols == DWARF2_DEBUG)
-    use_gnu_debug_info_extensions = gnat_dwarf_extensions > 0;
-
   optimize = global_options.x_optimize;
   optimize_size = global_options.x_optimize_size;