diff options
author | Nicolas Setton <setton@adacore.com> | 2008-06-06 21:36:28 +0000 |
---|---|---|
committer | Olivier Hainque <hainque@gcc.gnu.org> | 2008-06-06 21:36:28 +0000 |
commit | 081a52ed5221b9fe0280f80b3646c6118eb3ed1c (patch) | |
tree | 92a62fd35271bf3f29e34745397c5bfee0abfb25 /gcc/ada/misc.c | |
parent | e919209b4eb54e6f731510475c4b8ed64c23140e (diff) | |
download | gcc-081a52ed5221b9fe0280f80b3646c6118eb3ed1c.zip gcc-081a52ed5221b9fe0280f80b3646c6118eb3ed1c.tar.gz gcc-081a52ed5221b9fe0280f80b3646c6118eb3ed1c.tar.bz2 |
ada-tree.h (DECL_PARALLEL_TYPE): New language specific attribute...
2008-06-06 Nicolas Setton <setton@adacore.com>
Olivier Hainque <hainque@adacore.com>
* ada-tree.h (DECL_PARALLEL_TYPE): New language specific
attribute, parallel descriptive type attached to another type
for debug info generation purposes.
* utils.c (add_parallel_type): New function, register parallel
type to be attached to a type.
(get_parallel_type): New function, fetch a registered parallel
type, if any.
(rest_of_record_type_compilation): Register the parallel type we
make for variable size records.
* gigi.h (add_parallel_type, get_parallel_type): Declare.
* decl.c (gnat_to_gnu_entity, maybe_pad_type): Register the
parallel debug types we make.
* trans.c (extract_encoding, decode_name): New functions.
(gigi): If the DWARF attribute extensions are available, setup
to use them.
* lang.opt: Register language specific processing request
for -gdwarf+.
* misc.c (gnat_dwarf_extensions): New global variable. How much
do we want of our DWARF extensions. 0 by default.
(gnat_handle_option) <OPT_gdwarf_>: Increment gnat_dwarf_extensions.
(gnat_post_options): Map gnat_dwarf_extensions to the common
use_gnu_debug_info_extensions for later processing.
Co-Authored-By: Olivier Hainque <hainque@adacore.com>
From-SVN: r136506
Diffstat (limited to 'gcc/ada/misc.c')
-rw-r--r-- | gcc/ada/misc.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/ada/misc.c b/gcc/ada/misc.c index a4dd99c..9ee90dd 100644 --- a/gcc/ada/misc.c +++ b/gcc/ada/misc.c @@ -199,6 +199,13 @@ const char *const tree_code_name[] = { }; #undef DEFTREECODE +/* 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 and used in back_end.adb */ @@ -334,6 +341,10 @@ gnat_handle_option (size_t scode, const char *arg, int value) gnat_argc++; break; + case OPT_gdwarf_: + gnat_dwarf_extensions ++; + break; + default: gcc_unreachable (); } @@ -383,6 +394,11 @@ gnat_post_options (const char **pfilename ATTRIBUTE_UNUSED) 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; + return false; } |