[PATCH] D65427: [analyzer] exploded-graph-rewriter: Implement Store pointers.

2019-08-13 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes.
Closed by commit rL368769: [analyzer] exploded-graph-rewriter: Implement 
displaying Store pointers. (authored by dergachev, committed by ).
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Changed prior to commit:
  https://reviews.llvm.org/D65427?vs=212257=214964#toc

Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65427/new/

https://reviews.llvm.org/D65427

Files:
  cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
  cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
  cfe/trunk/utils/analyzer/exploded-graph-rewriter.py


Index: cfe/trunk/utils/analyzer/exploded-graph-rewriter.py
===
--- cfe/trunk/utils/analyzer/exploded-graph-rewriter.py
+++ cfe/trunk/utils/analyzer/exploded-graph-rewriter.py
@@ -644,6 +644,10 @@
 if st is None:
 self._dump(' Nothing!')
 else:
+if self._dark_mode:
+self._dump(' (%s)' % st.ptr)
+else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:
 if s.store.is_different(prev_st):
 self._dump('')
Index: cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
===
--- cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
+++ cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
@@ -4,6 +4,7 @@
 // UNSUPPORTED: system-windows
 
 // CHECK: Store: 
+// CHECK-SAME: (0x2)
 // CHECK-SAME: 
 // CHECK-SAME:   
 // CHECK-SAME: 
Index: cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
===
--- cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
+++ cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
@@ -9,7 +9,7 @@
 // UNSUPPORTED: system-windows
 
 void escapes() {
-  // CHECK: Store: 
+  // CHECK: Store:  (0x{{[0-9a-f]*}})
   // CHECK-SAME: foo0
   // CHECK-SAME: Element\{"foo",0 S64b,char\}
   // CHECK: Environment: 


Index: cfe/trunk/utils/analyzer/exploded-graph-rewriter.py
===
--- cfe/trunk/utils/analyzer/exploded-graph-rewriter.py
+++ cfe/trunk/utils/analyzer/exploded-graph-rewriter.py
@@ -644,6 +644,10 @@
 if st is None:
 self._dump(' Nothing!')
 else:
+if self._dark_mode:
+self._dump(' (%s)' % st.ptr)
+else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:
 if s.store.is_different(prev_st):
 self._dump('')
Index: cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
===
--- cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
+++ cfe/trunk/test/Analysis/exploded-graph-rewriter/store.dot
@@ -4,6 +4,7 @@
 // UNSUPPORTED: system-windows
 
 // CHECK: Store: 
+// CHECK-SAME: (0x2)
 // CHECK-SAME: 
 // CHECK-SAME:   
 // CHECK-SAME: 
Index: cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
===
--- cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
+++ cfe/trunk/test/Analysis/exploded-graph-rewriter/escapes.c
@@ -9,7 +9,7 @@
 // UNSUPPORTED: system-windows
 
 void escapes() {
-  // CHECK: Store: 
+  // CHECK: Store:  (0x{{[0-9a-f]*}})
   // CHECK-SAME: foo0
   // CHECK-SAME: Element\{"foo",0 S64b,char\}
   // CHECK: Environment: 
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D65427: [analyzer] exploded-graph-rewriter: Implement Store pointers.

2019-07-29 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso accepted this revision.
Charusso added a comment.

Oh, of course. Thanks!


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65427/new/

https://reviews.llvm.org/D65427



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D65427: [analyzer] exploded-graph-rewriter: Implement Store pointers.

2019-07-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ marked an inline comment as done.
NoQ added inline comments.



Comment at: clang/utils/analyzer/exploded-graph-rewriter.py:647
 else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:

Charusso wrote:
> Extra space at the start of the string: `' <`.
I'm doing this intentionally because GraphViz's rendering of spaces is pretty 
weird. Without this space the new text gets agglutinated to the "Store:" 
caption.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65427/new/

https://reviews.llvm.org/D65427



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D65427: [analyzer] exploded-graph-rewriter: Implement Store pointers.

2019-07-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 212257.
NoQ added a comment.

Hmm, on second thought...
Make the pointers a bit darker in dark mode.

F9692102: Screen Shot 2019-07-29 at 5.31.14 PM.png 



CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65427/new/

https://reviews.llvm.org/D65427

Files:
  clang/test/Analysis/exploded-graph-rewriter/escapes.c
  clang/test/Analysis/exploded-graph-rewriter/store.dot
  clang/utils/analyzer/exploded-graph-rewriter.py


Index: clang/utils/analyzer/exploded-graph-rewriter.py
===
--- clang/utils/analyzer/exploded-graph-rewriter.py
+++ clang/utils/analyzer/exploded-graph-rewriter.py
@@ -644,6 +644,10 @@
 if st is None:
 self._dump(' Nothing!')
 else:
+if self._dark_mode:
+self._dump(' (%s)' % st.ptr)
+else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:
 if s.store.is_different(prev_st):
 self._dump('')
Index: clang/test/Analysis/exploded-graph-rewriter/store.dot
===
--- clang/test/Analysis/exploded-graph-rewriter/store.dot
+++ clang/test/Analysis/exploded-graph-rewriter/store.dot
@@ -4,6 +4,7 @@
 // UNSUPPORTED: system-windows
 
 // CHECK: Store: 
+// CHECK-SAME: (0x2)
 // CHECK-SAME: 
 // CHECK-SAME:   
 // CHECK-SAME: 
Index: clang/test/Analysis/exploded-graph-rewriter/escapes.c
===
--- clang/test/Analysis/exploded-graph-rewriter/escapes.c
+++ clang/test/Analysis/exploded-graph-rewriter/escapes.c
@@ -9,7 +9,7 @@
 // UNSUPPORTED: system-windows
 
 void escapes() {
-  // CHECK: Store: 
+  // CHECK: Store:  (0x{{[0-9a-f]*}})
   // CHECK-SAME: foo0
   // CHECK-SAME: Element\{"foo",0 S64b,char\}
   // CHECK: Environment: 


Index: clang/utils/analyzer/exploded-graph-rewriter.py
===
--- clang/utils/analyzer/exploded-graph-rewriter.py
+++ clang/utils/analyzer/exploded-graph-rewriter.py
@@ -644,6 +644,10 @@
 if st is None:
 self._dump(' Nothing!')
 else:
+if self._dark_mode:
+self._dump(' (%s)' % st.ptr)
+else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:
 if s.store.is_different(prev_st):
 self._dump('')
Index: clang/test/Analysis/exploded-graph-rewriter/store.dot
===
--- clang/test/Analysis/exploded-graph-rewriter/store.dot
+++ clang/test/Analysis/exploded-graph-rewriter/store.dot
@@ -4,6 +4,7 @@
 // UNSUPPORTED: system-windows
 
 // CHECK: Store: 
+// CHECK-SAME: (0x2)
 // CHECK-SAME: 
 // CHECK-SAME:   
 // CHECK-SAME: 
Index: clang/test/Analysis/exploded-graph-rewriter/escapes.c
===
--- clang/test/Analysis/exploded-graph-rewriter/escapes.c
+++ clang/test/Analysis/exploded-graph-rewriter/escapes.c
@@ -9,7 +9,7 @@
 // UNSUPPORTED: system-windows
 
 void escapes() {
-  // CHECK: Store: 
+  // CHECK: Store:  (0x{{[0-9a-f]*}})
   // CHECK-SAME: foo0
   // CHECK-SAME: Element\{"foo",0 S64b,char\}
   // CHECK: Environment: 
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D65427: [analyzer] exploded-graph-rewriter: Implement Store pointers.

2019-07-29 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso accepted this revision.
Charusso added a comment.
This revision is now accepted and ready to land.

Thanks! Is it working in dark-mode as expected?




Comment at: clang/utils/analyzer/exploded-graph-rewriter.py:647
 else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:

Extra space at the start of the string: `' <`.


Repository:
  rC Clang

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D65427/new/

https://reviews.llvm.org/D65427



___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits


[PATCH] D65427: [analyzer] exploded-graph-rewriter: Implement Store pointers.

2019-07-29 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision.
NoQ added a reviewer: Charusso.
Herald added subscribers: cfe-commits, dkrupp, donat.nagy, Szelethus, 
mikhail.ramalho, a.sidorin, szepet, baloghadamsoftware, xazax.hun.
Herald added a project: clang.

Those are useful for understanding contents of `LazyCompoundVal`s.

F9691913: Screen Shot 2019-07-29 at 5.12.36 PM.png 



Repository:
  rC Clang

https://reviews.llvm.org/D65427

Files:
  clang/test/Analysis/exploded-graph-rewriter/escapes.c
  clang/test/Analysis/exploded-graph-rewriter/store.dot
  clang/utils/analyzer/exploded-graph-rewriter.py


Index: clang/utils/analyzer/exploded-graph-rewriter.py
===
--- clang/utils/analyzer/exploded-graph-rewriter.py
+++ clang/utils/analyzer/exploded-graph-rewriter.py
@@ -644,6 +644,7 @@
 if st is None:
 self._dump(' Nothing!')
 else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:
 if s.store.is_different(prev_st):
 self._dump('')
Index: clang/test/Analysis/exploded-graph-rewriter/store.dot
===
--- clang/test/Analysis/exploded-graph-rewriter/store.dot
+++ clang/test/Analysis/exploded-graph-rewriter/store.dot
@@ -4,6 +4,7 @@
 // UNSUPPORTED: system-windows
 
 // CHECK: Store: 
+// CHECK-SAME: (0x2)
 // CHECK-SAME: 
 // CHECK-SAME:   
 // CHECK-SAME: 
Index: clang/test/Analysis/exploded-graph-rewriter/escapes.c
===
--- clang/test/Analysis/exploded-graph-rewriter/escapes.c
+++ clang/test/Analysis/exploded-graph-rewriter/escapes.c
@@ -9,7 +9,7 @@
 // UNSUPPORTED: system-windows
 
 void escapes() {
-  // CHECK: Store: 
+  // CHECK: Store:  (0x{{[0-9a-f]*}})
   // CHECK-SAME: foo0
   // CHECK-SAME: Element\{"foo",0 S64b,char\}
   // CHECK: Environment: 


Index: clang/utils/analyzer/exploded-graph-rewriter.py
===
--- clang/utils/analyzer/exploded-graph-rewriter.py
+++ clang/utils/analyzer/exploded-graph-rewriter.py
@@ -644,6 +644,7 @@
 if st is None:
 self._dump(' Nothing!')
 else:
+self._dump(' (%s)' % st.ptr)
 if prev_st is not None:
 if s.store.is_different(prev_st):
 self._dump('')
Index: clang/test/Analysis/exploded-graph-rewriter/store.dot
===
--- clang/test/Analysis/exploded-graph-rewriter/store.dot
+++ clang/test/Analysis/exploded-graph-rewriter/store.dot
@@ -4,6 +4,7 @@
 // UNSUPPORTED: system-windows
 
 // CHECK: Store: 
+// CHECK-SAME: (0x2)
 // CHECK-SAME: 
 // CHECK-SAME:   
 // CHECK-SAME: 
Index: clang/test/Analysis/exploded-graph-rewriter/escapes.c
===
--- clang/test/Analysis/exploded-graph-rewriter/escapes.c
+++ clang/test/Analysis/exploded-graph-rewriter/escapes.c
@@ -9,7 +9,7 @@
 // UNSUPPORTED: system-windows
 
 void escapes() {
-  // CHECK: Store: 
+  // CHECK: Store:  (0x{{[0-9a-f]*}})
   // CHECK-SAME: foo0
   // CHECK-SAME: Element\{"foo",0 S64b,char\}
   // CHECK: Environment: 
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits