Otawa  0.10
ConsBuilder.h
Go to the documentation of this file.
1 /*
2  * ConsBuilder processor interface
3  * Copyright (c) 2011, IRIT UPS.
4  *
5  * This file is part of OTAWA
6  *
7  * OTAWA is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation; either version 2 of the License, or
10  * (at your option) any later version.
11  *
12  * OTAWA is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with OTAWA; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20  */
21 #ifndef BRANCH_CONSBUILDER_H_
22 #define BRANCH_CONSBUILDER_H_
23 
24 #include <otawa/cfg/features.h>
25 #include <otawa/prog/WorkSpace.h>
26 #include <otawa/proc/BBProcessor.h>
27 #include <otawa/cfg/BasicBlock.h>
28 
29 #include "features.h"
30 #include "BranchBuilder.h"
31 
32 namespace otawa { namespace branch {
33 
34 using namespace elm;
35 
36 
37 // OnlyConsBuilder processor
39 public:
40  static p::declare reg;
41  OnlyConsBuilder(p::declare& r = reg);
42  virtual void processBB(otawa::WorkSpace*, CFG *cfg, BasicBlock *bb);
43  virtual void configure(const PropList &props);
44 private:
45  bool _explicit;
46 };
47 
48 // ConsBuilder processor
49 class ConsBuilder: public BBProcessor {
50 public:
51  static p::declare reg;
52  ConsBuilder(p::declare& r = reg);
53  virtual void processBB(otawa::WorkSpace*, CFG *cfg, BasicBlock *bb);
54 };
55 
56 } } // otawa::branch
57 
58 #endif
This processor is dedicated to the basic block process thru proccessBB() method.
Definition: BBProcessor.h:72
static p::declare reg
Definition: ConsBuilder.h:51
This processor add to the current ILP the constraint requires to model the behavior of the BHT...
Definition: ConsBuilder.h:38
Class to declare simple a processor.
Definition: Registration.h:213
bool _explicit
Definition: ConsBuilder.h:45
This processor add to the current ILP the constraint requires to model the behaviour of the BHT...
Definition: ConsBuilder.h:49
dtd::Element bb(dtd::make("bb", _BB).attr(id).attr(address).attr(size))
Control Flow Graph representation.
Definition: CFG.h:42
A workspace represents a program, its run-time and all information about WCET computation or any othe...
Definition: WorkSpace.h:67
dtd::Element cfg(dtd::make("cfg", _CFG).attr(id).content((entry,*bb, exit,*edge)))
This is the minimal definition of a basic block.
Definition: BasicBlock.h:43
This a list of properties.
Definition: PropList.h:63
inst branch(int to)
Definition: inst.h:149
static p::declare reg
Definition: ConsBuilder.h:40