public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r12-7695] analyzer: fixes to -fdump-analyzer-state-purge
@ 2022-03-17 22:39 David Malcolm
  0 siblings, 0 replies; only message in thread
From: David Malcolm @ 2022-03-17 22:39 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:79e210f0c8e1fad875333e93b5ae2fe9b4879b7a

commit r12-7695-g79e210f0c8e1fad875333e93b5ae2fe9b4879b7a
Author: David Malcolm <dmalcolm@redhat.com>
Date:   Thu Mar 17 16:08:59 2022 -0400

    analyzer: fixes to -fdump-analyzer-state-purge
    
    gcc/analyzer/ChangeLog:
            * state-purge.cc (state_purge_annotator::add_node_annotations):
            Avoid duplicate before-supernode annotations when returning from
            an interprocedural call.  Show after-supernode annotations.
    
    Signed-off-by: David Malcolm <dmalcolm@redhat.com>

Diff:
---
 gcc/analyzer/state-purge.cc | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/gcc/analyzer/state-purge.cc b/gcc/analyzer/state-purge.cc
index e99c9cb593e..c37234ff16a 100644
--- a/gcc/analyzer/state-purge.cc
+++ b/gcc/analyzer/state-purge.cc
@@ -499,11 +499,12 @@ state_purge_annotator::add_node_annotations (graphviz_out *gv,
    /* Different in-edges mean different names need purging.
       Determine which points to dump.  */
    auto_vec<function_point> points;
-   if (n.entry_p ())
+   if (n.entry_p () || n.m_returning_call)
      points.safe_push (function_point::before_supernode (&n, NULL));
    else
      for (auto inedge : n.m_preds)
        points.safe_push (function_point::before_supernode (&n, inedge));
+   points.safe_push (function_point::after_supernode (&n));
 
    for (auto & point : points)
      {


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-03-17 22:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-17 22:39 [gcc r12-7695] analyzer: fixes to -fdump-analyzer-state-purge David Malcolm

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).