[Ada] fix -feliminate-unused-debug-types counter-measure

Eric Botcazou ebotcazou@adacore.com
Wed Feb 29 11:56:00 GMT 2012


-feliminate-unused-debug-types will be enabled for Ada as well in GCC 4.7 and 
we have implemented a counter-measure to be able to retain apparently unused 
types in a few specific cases.  But it was inadvertently broken some time ago.

Fixed thusly, tested on i586-suse-linux, applied on the mainline.


I'd like to also apply the following patch:
  http://gcc.gnu.org/ml/gcc-patches/2012-02/msg01349.html
which fixes debug info regressions introduced by the simultaneous introduction 
of DW_AT_GNAT_descriptive_type and -feliminate-unused-debug-types in Ada.  It 
only affects the Ada compiler since only GNAT uses DW_AT_GNAT_descriptive_type 
and sets TYPE_ARTIFICIAL on its types.  OK?


2012-02-29  Eric Botcazou  <ebotcazou@adacore.com>

	* gcc-interface/utils.c (gnat_write_global_declarations): Make sure the
	dummy global built for global types is preserved.


-- 
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-diff
Size: 838 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20120229/dc2c0b30/attachment.bin>


More information about the Gcc-patches mailing list