Skip to content

Commit e9349f8

Browse files
committed
Reformat src
1 parent aed3c25 commit e9349f8

File tree

1,207 files changed

+5811
-59145
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,207 files changed

+5811
-59145
lines changed

src/analyses/ai.cpp

Lines changed: 23 additions & 257 deletions
Large diffs are not rendered by default.

src/analyses/ai.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ Author: Daniel Kroening, [email protected]
66
77
\*******************************************************************/
88

9+
/// \file
10+
/// Abstract Interpretation
11+
912
#ifndef CPROVER_ANALYSES_AI_H
1013
#define CPROVER_ANALYSES_AI_H
1114

src/analyses/call_graph.cpp

Lines changed: 3 additions & 84 deletions
Original file line numberDiff line numberDiff line change
@@ -6,39 +6,18 @@ Author: Daniel Kroening, [email protected]
66
77
\*******************************************************************/
88

9+
/// \file
10+
/// Function Call Graphs
11+
912
#include <util/std_expr.h>
1013
#include <util/xml.h>
1114

1215
#include "call_graph.h"
1316

14-
/*******************************************************************\
15-
16-
Function: call_grapht::call_grapht
17-
18-
Inputs:
19-
20-
Outputs:
21-
22-
Purpose:
23-
24-
\*******************************************************************/
25-
2617
call_grapht::call_grapht()
2718
{
2819
}
2920

30-
/*******************************************************************\
31-
32-
Function: call_grapht::call_grapht
33-
34-
Inputs:
35-
36-
Outputs:
37-
38-
Purpose:
39-
40-
\*******************************************************************/
41-
4221
call_grapht::call_grapht(const goto_functionst &goto_functions)
4322
{
4423
forall_goto_functions(f_it, goto_functions)
@@ -48,18 +27,6 @@ call_grapht::call_grapht(const goto_functionst &goto_functions)
4827
}
4928
}
5029

51-
/*******************************************************************\
52-
53-
Function: call_grapht::add
54-
55-
Inputs:
56-
57-
Outputs:
58-
59-
Purpose:
60-
61-
\*******************************************************************/
62-
6330
void call_grapht::add(
6431
const irep_idt &function,
6532
const goto_programt &body)
@@ -75,37 +42,13 @@ void call_grapht::add(
7542
}
7643
}
7744

78-
/*******************************************************************\
79-
80-
Function: call_grapht::add
81-
82-
Inputs:
83-
84-
Outputs:
85-
86-
Purpose:
87-
88-
\*******************************************************************/
89-
9045
void call_grapht::add(
9146
const irep_idt &caller,
9247
const irep_idt &callee)
9348
{
9449
graph.insert(std::pair<irep_idt, irep_idt>(caller, callee));
9550
}
9651

97-
/*******************************************************************\
98-
99-
Function: call_grapht::output_dot
100-
101-
Inputs:
102-
103-
Outputs:
104-
105-
Purpose:
106-
107-
\*******************************************************************/
108-
10952
void call_grapht::output_dot(std::ostream &out) const
11053
{
11154
out << "digraph call_graph {\n";
@@ -121,18 +64,6 @@ void call_grapht::output_dot(std::ostream &out) const
12164
out << "}\n";
12265
}
12366

124-
/*******************************************************************\
125-
126-
Function: call_grapht::output
127-
128-
Inputs:
129-
130-
Outputs:
131-
132-
Purpose:
133-
134-
\*******************************************************************/
135-
13667
void call_grapht::output(std::ostream &out) const
13768
{
13869
for(const auto &edge : graph)
@@ -141,18 +72,6 @@ void call_grapht::output(std::ostream &out) const
14172
}
14273
}
14374

144-
/*******************************************************************\
145-
146-
Function: call_grapht::output_xml
147-
148-
Inputs:
149-
150-
Outputs:
151-
152-
Purpose:
153-
154-
\*******************************************************************/
155-
15675
void call_grapht::output_xml(std::ostream &out) const
15776
{
15877
for(const auto &edge : graph)

src/analyses/call_graph.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ Author: Daniel Kroening, [email protected]
66
77
\*******************************************************************/
88

9+
/// \file
10+
/// Function Call Graphs
11+
912
#ifndef CPROVER_ANALYSES_CALL_GRAPH_H
1013
#define CPROVER_ANALYSES_CALL_GRAPH_H
1114

src/analyses/cfg_dominators.h

Lines changed: 11 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ Author: Georg Weissenbacher, [email protected]
66
77
\*******************************************************************/
88

9+
/// \file
10+
/// Compute dominators for CFG of goto_function
11+
912
#ifndef CPROVER_ANALYSES_CFG_DOMINATORS_H
1013
#define CPROVER_ANALYSES_CFG_DOMINATORS_H
1114

@@ -44,18 +47,7 @@ class cfg_dominators_templatet
4447
void fixedpoint(P &program);
4548
};
4649

47-
/*******************************************************************\
48-
49-
Function: operator <<
50-
51-
Inputs:
52-
53-
Outputs:
54-
55-
Purpose: Print the result of the dominator computation
56-
57-
\*******************************************************************/
58-
50+
/// Print the result of the dominator computation
5951
template <class P, class T, bool post_dom>
6052
std::ostream &operator << (
6153
std::ostream &out,
@@ -65,55 +57,22 @@ std::ostream &operator << (
6557
return out;
6658
}
6759

68-
/*******************************************************************\
69-
70-
Function: operator ()
71-
72-
Inputs:
73-
74-
Outputs:
75-
76-
Purpose: Compute dominators
77-
78-
\*******************************************************************/
79-
60+
/// Compute dominators
8061
template <class P, class T, bool post_dom>
8162
void cfg_dominators_templatet<P, T, post_dom>::operator()(P &program)
8263
{
8364
initialise(program);
8465
fixedpoint(program);
8566
}
8667

87-
/*******************************************************************\
88-
89-
Function: cfg_dominators_templatet::initialise
90-
91-
Inputs:
92-
93-
Outputs:
94-
95-
Purpose: Initialises the elements of the fixed point analysis
96-
97-
\*******************************************************************/
98-
68+
/// Initialises the elements of the fixed point analysis
9969
template <class P, class T, bool post_dom>
10070
void cfg_dominators_templatet<P, T, post_dom>::initialise(P &program)
10171
{
10272
cfg(program);
10373
}
10474

105-
/*******************************************************************\
106-
107-
Function: cfg_dominators_templatet::fixedpoint
108-
109-
Inputs:
110-
111-
Outputs:
112-
113-
Purpose: Computes the MOP for the dominator analysis
114-
115-
\*******************************************************************/
116-
75+
/// Computes the MOP for the dominator analysis
11776
template <class P, class T, bool post_dom>
11877
void cfg_dominators_templatet<P, T, post_dom>::fixedpoint(P &program)
11978
{
@@ -205,19 +164,9 @@ void cfg_dominators_templatet<P, T, post_dom>::fixedpoint(P &program)
205164
}
206165
}
207166

208-
/*******************************************************************\
209-
210-
Function: dominators_pretty_print_node
211-
212-
Inputs: `node` to print and stream `out` to pretty-print it to
213-
214-
Outputs:
215-
216-
Purpose: Pretty-print a single node in the dominator tree.
217-
Supply a specialisation if operator<< is not sufficient.
218-
219-
\*******************************************************************/
220-
167+
/// Pretty-print a single node in the dominator tree. Supply a specialisation if
168+
/// operator<< is not sufficient.
169+
/// \par parameters: `node` to print and stream `out` to pretty-print it to
221170
template <class T>
222171
void dominators_pretty_print_node(const T &node, std::ostream &out)
223172
{
@@ -231,18 +180,7 @@ inline void dominators_pretty_print_node(
231180
out << target->code.pretty();
232181
}
233182

234-
/*******************************************************************\
235-
236-
Function: cfg_dominators_templatet::output
237-
238-
Inputs:
239-
240-
Outputs:
241-
242-
Purpose: Print the result of the dominator computation
243-
244-
\*******************************************************************/
245-
183+
/// Print the result of the dominator computation
246184
template <class P, class T, bool post_dom>
247185
void cfg_dominators_templatet<P, T, post_dom>::output(std::ostream &out) const
248186
{

0 commit comments

Comments
 (0)