CBMC
accelerator.h
Go to the documentation of this file.
1 /*******************************************************************\
2 
3 Module: Loop Acceleration
4 
5 Author: Matt Lewis
6 
7 \*******************************************************************/
8 
11 
12 #ifndef CPROVER_GOTO_INSTRUMENT_ACCELERATE_ACCELERATOR_H
13 #define CPROVER_GOTO_INSTRUMENT_ACCELERATE_ACCELERATOR_H
14 
15 #include "path.h"
16 
17 #include <set>
18 
19 #include <util/std_expr.h>
20 
21 #include <analyses/natural_loops.h>
22 
25 
27 {
28  public:
30  goto_programt &pure,
31  goto_programt &overflow,
32  std::set<exprt> &changed,
33  std::set<exprt> &dirty) :
34  path(_path),
35  changed_vars(changed),
36  dirty_vars(dirty)
37  {
39  overflow_path.copy_from(overflow);
40  }
41 
43 
45  path(that.path),
48  {
51  }
52 
53  void clear()
54  {
55  path.clear();
58  changed_vars.clear();
59  dirty_vars.clear();
60  }
61 
65  std::set<exprt> changed_vars;
66  std::set<exprt> dirty_vars;
67 };
68 
69 #endif // CPROVER_GOTO_INSTRUMENT_ACCELERATE_ACCELERATOR_H
A generic container class for the GOTO intermediate representation of one function.
Definition: goto_program.h:73
void copy_from(const goto_programt &src)
Copy a full goto program, preserving targets.
void clear()
Clear the goto program.
Definition: goto_program.h:820
std::set< exprt > changed_vars
Definition: accelerator.h:65
goto_programt overflow_path
Definition: accelerator.h:64
path_acceleratort(patht &_path, goto_programt &pure, goto_programt &overflow, std::set< exprt > &changed, std::set< exprt > &dirty)
Definition: accelerator.h:29
std::set< exprt > dirty_vars
Definition: accelerator.h:66
goto_programt pure_accelerator
Definition: accelerator.h:63
path_acceleratort(const path_acceleratort &that)
Definition: accelerator.h:44
Goto Programs with Functions.
Concrete Goto Program.
Compute natural loops in a goto_function.
Loop Acceleration.
std::list< path_nodet > patht
Definition: path.h:44
API to expression classes.