* [PATCH] Fix debug fallout of proposed PR68162 fix
@ 2015-11-18 8:50 Richard Biener
2015-11-18 10:36 ` Marek Polacek
2015-11-26 10:55 ` Richard Biener
0 siblings, 2 replies; 4+ messages in thread
From: Richard Biener @ 2015-11-18 8:50 UTC (permalink / raw)
To: gcc-patches; +Cc: jason, Joseph S. Myers
The following patch makes sure we still emit a DW_TAG_typedef for
the element typedef in gcc.dg/debug/dwarf2/pr47939-4.c after a change
to how the C frontend structures the variant chain of arrays.
It makes dwarf2out _not_ re-build the variant for arrays (like it
does for vectors).
Patch was tested by Joseph (also on gdb testsuite?) and I'm currently
re-testing on x86_64-unknown-linux-gnu.
Ok for trunk and GCC 5 branch?
Thanks,
Richard.
2015-11-18 Richard Biener <rguenther@suse.de>
PR c/68162
* dwarf2out.c (gen_type_die_with_usage): Keep variant types
of arrays.
Index: gcc/dwarf2out.c
===================================================================
--- gcc/dwarf2out.c (revision 230428)
+++ gcc/dwarf2out.c (working copy)
@@ -20784,9 +20784,10 @@ gen_type_die_with_usage (tree type, dw_d
/* We are going to output a DIE to represent the unqualified version
of this type (i.e. without any const or volatile qualifiers) so
get the main variant (i.e. the unqualified version) of this type
- now. (Vectors are special because the debugging info is in the
+ now. (Vectors and arrays are special because the debugging info is in the
cloned type itself). */
- if (TREE_CODE (type) != VECTOR_TYPE)
+ if (TREE_CODE (type) != VECTOR_TYPE
+ && TREE_CODE (type) != ARRAY_TYPE)
type = type_main_variant (type);
/* If this is an array type with hidden descriptor, handle it first. */
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Fix debug fallout of proposed PR68162 fix
2015-11-18 8:50 [PATCH] Fix debug fallout of proposed PR68162 fix Richard Biener
@ 2015-11-18 10:36 ` Marek Polacek
2015-11-26 10:55 ` Richard Biener
1 sibling, 0 replies; 4+ messages in thread
From: Marek Polacek @ 2015-11-18 10:36 UTC (permalink / raw)
To: Richard Biener; +Cc: gcc-patches, jason, Joseph S. Myers
On Wed, Nov 18, 2015 at 09:50:26AM +0100, Richard Biener wrote:
> --- gcc/dwarf2out.c (revision 230428)
> +++ gcc/dwarf2out.c (working copy)
> @@ -20784,9 +20784,10 @@ gen_type_die_with_usage (tree type, dw_d
> /* We are going to output a DIE to represent the unqualified version
> of this type (i.e. without any const or volatile qualifiers) so
> get the main variant (i.e. the unqualified version) of this type
> - now. (Vectors are special because the debugging info is in the
> + now. (Vectors and arrays are special because the debugging info is in the
> cloned type itself). */
> - if (TREE_CODE (type) != VECTOR_TYPE)
> + if (TREE_CODE (type) != VECTOR_TYPE
There's VECTOR_TYPE_P for this if you want to use that.
Marek
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] Fix debug fallout of proposed PR68162 fix
2015-11-18 8:50 [PATCH] Fix debug fallout of proposed PR68162 fix Richard Biener
2015-11-18 10:36 ` Marek Polacek
@ 2015-11-26 10:55 ` Richard Biener
2015-11-29 19:19 ` Jason Merrill
1 sibling, 1 reply; 4+ messages in thread
From: Richard Biener @ 2015-11-26 10:55 UTC (permalink / raw)
To: gcc-patches; +Cc: jason, Joseph S. Myers
On Wed, 18 Nov 2015, Richard Biener wrote:
>
> The following patch makes sure we still emit a DW_TAG_typedef for
> the element typedef in gcc.dg/debug/dwarf2/pr47939-4.c after a change
> to how the C frontend structures the variant chain of arrays.
>
> It makes dwarf2out _not_ re-build the variant for arrays (like it
> does for vectors).
>
> Patch was tested by Joseph (also on gdb testsuite?) and I'm currently
> re-testing on x86_64-unknown-linux-gnu.
>
> Ok for trunk and GCC 5 branch?
Ping?
Thanks,
Richard.
> Thanks,
> Richard.
>
> 2015-11-18 Richard Biener <rguenther@suse.de>
>
> PR c/68162
> * dwarf2out.c (gen_type_die_with_usage): Keep variant types
> of arrays.
>
> Index: gcc/dwarf2out.c
> ===================================================================
> --- gcc/dwarf2out.c (revision 230428)
> +++ gcc/dwarf2out.c (working copy)
> @@ -20784,9 +20784,10 @@ gen_type_die_with_usage (tree type, dw_d
> /* We are going to output a DIE to represent the unqualified version
> of this type (i.e. without any const or volatile qualifiers) so
> get the main variant (i.e. the unqualified version) of this type
> - now. (Vectors are special because the debugging info is in the
> + now. (Vectors and arrays are special because the debugging info is in the
> cloned type itself). */
> - if (TREE_CODE (type) != VECTOR_TYPE)
> + if (TREE_CODE (type) != VECTOR_TYPE
> + && TREE_CODE (type) != ARRAY_TYPE)
> type = type_main_variant (type);
>
> /* If this is an array type with hidden descriptor, handle it first. */
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2015-11-29 19:11 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-18 8:50 [PATCH] Fix debug fallout of proposed PR68162 fix Richard Biener
2015-11-18 10:36 ` Marek Polacek
2015-11-26 10:55 ` Richard Biener
2015-11-29 19:19 ` Jason Merrill
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).