* [Ada] Small debug info tweak
@ 2008-04-18 19:50 Eric Botcazou
0 siblings, 0 replies; only message in thread
From: Eric Botcazou @ 2008-04-18 19:50 UTC (permalink / raw)
To: gcc-patches
[-- Attachment #1: Type: text/plain, Size: 433 bytes --]
The purpose of the XVS parallel types is documented in exp_dbug.ads, but turns
out to be somewhat vague. It appears that they are not needed if the type
has a fixed size. Hence the attached patch.
Tested on i586-suse-linux, applied on the mainline.
2008-04-18 Eric Botcazou <ebotcazou@adacore.com>
* decl.c (maybe_pad_type): Only generate the XVS parallel type if
the padded type has a variable size.
--
Eric Botcazou
[-- Attachment #2: p.diff --]
[-- Type: text/x-diff, Size: 864 bytes --]
Index: decl.c
===================================================================
--- decl.c (revision 134433)
+++ decl.c (working copy)
@@ -5683,11 +5683,12 @@ maybe_pad_type (tree type, tree size, un
/* Unless debugging information isn't being written for the input type,
write a record that shows what we are a subtype of and also make a
- variable that indicates our size, if variable. */
+ variable that indicates our size, if still variable. */
if (TYPE_NAME (record)
&& AGGREGATE_TYPE_P (type)
- && (TREE_CODE (TYPE_NAME (type)) != TYPE_DECL
- || !DECL_IGNORED_P (TYPE_NAME (type))))
+ && TREE_CODE (orig_size) != INTEGER_CST
+ && !(TREE_CODE (TYPE_NAME (type)) == TYPE_DECL
+ && DECL_IGNORED_P (TYPE_NAME (type))))
{
tree marker = make_node (RECORD_TYPE);
tree name = TYPE_NAME (record);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-04-18 18:33 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-04-18 19:50 [Ada] Small debug info tweak Eric Botcazou
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).