Skip to content

Commit 5a72338

Browse files
committed
[analyzer] exploded-graph-rewriter: Implement program point tags.
Keep them on a separate line for more visibility. Differential Revision: https://reviews.llvm.org/D63965 llvm-svn: 364864
1 parent fc61db5 commit 5a72338

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

clang/test/Analysis/exploded-graph-rewriter/program_points.dot

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,14 @@ Node0x1 [shape=record,label=
4141
// CHECK-SAME: </td>
4242
// CHECK-SAME: <td>x</td>
4343
// CHECK-SAME: </tr>
44+
// CHECK-SAME: <tr>
45+
// CHECK-SAME: <td width="0">
46+
// CHECK-SAME: </td>
47+
// CHECK-SAME: <td colspan="2" align="left">
48+
// CHECK-SAME: <b>Tag: </b>
49+
// CHECK-SAME: <font color="crimson">ExprEngine : Clean Node</font>
50+
// CHECK-SAME: </td>
51+
// CHECK-SAME: </tr>
4452
// CHECK-SAME: </table>
4553
Node0x2 [shape=record,label=
4654
"{
@@ -56,7 +64,7 @@ Node0x2 [shape=record,label=
5664
"line": 4,
5765
"column": 5
5866
},
59-
"tag": null
67+
"tag": "ExprEngine : Clean Node"
6068
}
6169
]}
6270
\l}"];

clang/utils/analyzer/exploded-graph-rewriter.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -387,6 +387,12 @@ def visit_program_point(self, p):
387387
'<font color="%s">%s</font></td></tr>'
388388
% (color, p.kind))
389389

390+
if p.tag is not None:
391+
self._dump('<tr><td width="0"></td>'
392+
'<td colspan="2" align="left">'
393+
'<b>Tag: </b> <font color="crimson">'
394+
'%s</font></td></tr>' % p.tag)
395+
390396
def visit_environment(self, e, prev_e=None):
391397
self._dump('<table border="0">')
392398

0 commit comments

Comments
 (0)