* [PATCH] enhance debug_tree() to print DECL_READ_P flag
@ 2017-05-18 19:49 Martin Sebor
2017-05-19 9:12 ` Richard Biener
0 siblings, 1 reply; 2+ messages in thread
From: Martin Sebor @ 2017-05-18 19:49 UTC (permalink / raw)
To: Gcc Patch List
[-- Attachment #1: Type: text/plain, Size: 143 bytes --]
The debug_tree() function doesn't print the DECL_READ_P flag
for a VAR_DECL or PARM_DECL. The attached two like patch makes
it do so.
Martin
[-- Attachment #2: tree-read.diff --]
[-- Type: text/x-patch, Size: 654 bytes --]
gcc/ChangeLog:
* print-tree.c (print_node): Print DECL_READ_P flag.
/* Bit masks to control dumping. Not all values are applicable to all
diff --git a/gcc/print-tree.c b/gcc/print-tree.c
index fb58be6..388c694 100644
--- a/gcc/print-tree.c
+++ b/gcc/print-tree.c
@@ -400,6 +400,8 @@ print_node (FILE *file, const char *prefix, tree node, int indent,
fputs (" in-constant-pool", file);
if (code == VAR_DECL && DECL_COMMON (node))
fputs (" common", file);
+ if ((code == VAR_DECL || code == PARM_DECL) && DECL_READ_P (node))
+ fputs (" read", file);
if (code == VAR_DECL && DECL_THREAD_LOCAL_P (node))
{
fputs (" ", file);
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] enhance debug_tree() to print DECL_READ_P flag
2017-05-18 19:49 [PATCH] enhance debug_tree() to print DECL_READ_P flag Martin Sebor
@ 2017-05-19 9:12 ` Richard Biener
0 siblings, 0 replies; 2+ messages in thread
From: Richard Biener @ 2017-05-19 9:12 UTC (permalink / raw)
To: Martin Sebor; +Cc: Gcc Patch List
On Thu, May 18, 2017 at 9:05 PM, Martin Sebor <msebor@gmail.com> wrote:
> The debug_tree() function doesn't print the DECL_READ_P flag
> for a VAR_DECL or PARM_DECL. The attached two like patch makes
> it do so.
Ok.
Richard.
> Martin
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-05-19 9:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-18 19:49 [PATCH] enhance debug_tree() to print DECL_READ_P flag Martin Sebor
2017-05-19 9:12 ` Richard Biener
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).