From d8706290996922a019a5c084b858d4a7cf82cdda Mon Sep 17 00:00:00 2001 From: weiyu Date: Mon, 30 Sep 2019 11:14:07 -0700 Subject: [PATCH] Clear headers --- funcnode.cc | 3 +++ funcnode.h | 7 ++----- history.cc | 9 ++------- history.h | 3 +-- newfuzzer.cc | 9 ++++++--- predicate.cc | 1 + predicate.h | 1 - 7 files changed, 15 insertions(+), 18 deletions(-) diff --git a/funcnode.cc b/funcnode.cc index 8cd81423..af268aad 100644 --- a/funcnode.cc +++ b/funcnode.cc @@ -1,5 +1,8 @@ +#include "action.h" #include "history.h" #include "funcnode.h" +#include "funcinst.h" +#include "predicate.h" #include "concretepredicate.h" FuncNode::FuncNode(ModelHistory * history) : diff --git a/funcnode.h b/funcnode.h index 5773d79d..14b5806a 100644 --- a/funcnode.h +++ b/funcnode.h @@ -1,12 +1,9 @@ #ifndef __FUNCNODE_H__ #define __FUNCNODE_H__ -#include "action.h" -#include "funcinst.h" -#include "hashtable.h" #include "hashset.h" -#include "predicate.h" -#include "history.h" +#include "classlist.h" +#include "threads-model.h" typedef ModelList func_inst_list_mt; diff --git a/history.cc b/history.cc index 568cecb5..4b03e7ff 100644 --- a/history.cc +++ b/history.cc @@ -2,6 +2,7 @@ #include "history.h" #include "action.h" #include "funcnode.h" +#include "funcinst.h" #include "common.h" #include "model.h" @@ -62,7 +63,7 @@ void ModelHistory::enter_function(const uint32_t func_id, thread_id_t tid) /* Add edges between FuncNodes */ if (last_entered_func_id != 0) { FuncNode * last_func_node = func_nodes[last_entered_func_id]; - add_edges_between(last_func_node, func_node); + last_func_node->add_out_edge(func_node); } } @@ -246,12 +247,6 @@ void ModelHistory::set_new_exec_flag() } } -/* Add edges between FuncNodes */ -void ModelHistory::add_edges_between(FuncNode * prev_node, FuncNode * next_node) -{ - prev_node->add_out_edge(next_node); -} - void ModelHistory::dump_func_node_graph() { model_print("digraph func_node_graph {\n"); diff --git a/history.h b/history.h index e85aa81a..51f26304 100644 --- a/history.h +++ b/history.h @@ -3,8 +3,8 @@ #include "stl-model.h" #include "common.h" +#include "classlist.h" #include "hashtable.h" -#include "hashset.h" #include "threads-model.h" class ModelHistory { @@ -59,7 +59,6 @@ private: /* Keeps track of the last function entered by each thread */ SnapVector thrd_last_entered_func; - void add_edges_between(FuncNode * prev_node, FuncNode * next_node); }; #endif /* __HISTORY_H__ */ diff --git a/newfuzzer.cc b/newfuzzer.cc index eefd553e..d5814217 100644 --- a/newfuzzer.cc +++ b/newfuzzer.cc @@ -1,13 +1,16 @@ #include "newfuzzer.h" #include "threads-model.h" -#include "model.h" #include "action.h" -#include "execution.h" #include "history.h" #include "funcnode.h" -#include "schedule.h" +#include "funcinst.h" +#include "predicate.h" #include "concretepredicate.h" +#include "model.h" +#include "schedule.h" +#include "execution.h" + NewFuzzer::NewFuzzer() : thrd_last_read_act(), thrd_curr_pred(), diff --git a/predicate.cc b/predicate.cc index 94eedfd5..fd9e78fa 100644 --- a/predicate.cc +++ b/predicate.cc @@ -1,3 +1,4 @@ +#include "funcinst.h" #include "predicate.h" #include "concretepredicate.h" diff --git a/predicate.h b/predicate.h index 1600cc8a..4c26a9dd 100644 --- a/predicate.h +++ b/predicate.h @@ -1,7 +1,6 @@ #ifndef __PREDICATE_H__ #define __PREDICATE_H__ -#include "funcinst.h" #include "hashset.h" #include "predicatetypes.h" #include "classlist.h" -- 2.34.1