Commit b3e34e04 authored by Artem Dergachev's avatar Artem Dergachev
Browse files

[analyzer] Drop the logic for collapsing the state if it's same as in preds.

One of the first attempts to reduce the size of the exploded graph dumps
was to skip the state dump as long as the state is the same as in all of
the predecessor nodes. With all the new facilities in place (node joining,
diff dumps), this feature doesn't do much, and when it does,
it's more harmful than useful. Let's remove it.

llvm-svn: 375280
parent d93b810c
Loading
Loading
Loading
Loading
+1 −10
Original line number Diff line number Diff line
@@ -3083,16 +3083,7 @@ struct DOTGraphTraits<ExplodedGraph*> : public DefaultDOTGraphTraits {
    Out << "\\l"; // Adds a new-line to the last program point.
    Indent(Out, Space, IsDot) << "],\\l";

    bool SameAsAllPredecessors =
        std::all_of(N->pred_begin(), N->pred_end(), [&](const ExplodedNode *P) {
          return P->getState() == State;
        });

    if (!SameAsAllPredecessors) {
    State->printDOT(Out, N->getLocationContext(), Space);
    } else {
      Indent(Out, Space, IsDot) << "\"program_state\": null";
    }

    Out << "\\l}\\l";
    return Out.str();
+2 −0
Original line number Diff line number Diff line
@@ -48,3 +48,5 @@ int foo() {
// CHECK: \"pretty\": \"'\\\\x13'\"

// CHECK: \"has_report\": 1

// CHECK-NOT: \"program_state\": null