OTAWA  2.0
Framework to perform machine analysis and compute WCET.
ClpAnalysis.h
Go to the documentation of this file.
1 /*
2  * $Id$
3  * ClpAnalysis processor interface
4  *
5  * This file is part of OTAWA
6  * Copyright (c) 2011, IRIT UPS.
7  *
8  * OTAWA is free software; you can redistribute it and/or modify
9  * it under the terms of the GNU General Public License as published by
10  * the Free Software Foundation; either version 2 of the License, or
11  * (at your option) any later version.
12  *
13  * OTAWA is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with OTAWA; if not, write to the Free Software
20  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
21  * 02110-1301 USA
22  */
23 
24 #ifndef OTAWA_DATA_CLP_ANALYSIS_H_
25 #define OTAWA_DATA_CLP_ANALYSIS_H_
26 
27 #include <otawa/proc/Processor.h>
29 
30 namespace otawa {
31 
32 namespace hard { class Memory; }
33 
34 namespace clp {
35 
36 class Analysis: public Processor {
37 public:
41  static p::declare reg;
42 
43  Analysis(p::declare& r = reg);
44  void configure(const PropList &props) override;
45 
47  inline clp::STAT_UINT get_nb_inst(void){ return _nb_inst; }
51  inline clp::STAT_UINT get_nb_set(void){ return _nb_set; }
53  inline clp::STAT_UINT get_nb_top_set(void){ return _nb_top_set; }
55  inline clp::STAT_UINT get_nb_store(void){ return _nb_store; }
61  inline clp::STAT_UINT get_nb_load(void){return _nb_load;}
65  inline clp::STAT_UINT get_nb_filters(void){ return _nb_filters; }
69  inline clp::STAT_UINT get_nb_top_load(void) const { return _nb_top_load; }
70 
71 protected:
72  void setup(WorkSpace *ws) override;
73  void processWorkSpace(WorkSpace *ws) override;
75 private:
76  const hard::Memory *mem;
88  bool verbose;
89 };
90 
91 } } // otawa::clp
92 
93 #endif /* OTAWA_DATA_CLP_ANALYSIS_H_ */
otawa::clp::Analysis::get_nb_inst
clp::STAT_UINT get_nb_inst(void)
Definition: ClpAnalysis.h:47
otawa::clp::Analysis::_nb_sem_inst
clp::STAT_UINT _nb_sem_inst
Definition: ClpAnalysis.h:77
otawa::clp::Analysis::_nb_top_filters
clp::STAT_UINT _nb_top_filters
Definition: ClpAnalysis.h:87
otawa::clp::Analysis::get_nb_top_load
clp::STAT_UINT get_nb_top_load(void) const
Definition: ClpAnalysis.h:69
otawa::clp::Analysis::get_nb_top_store_addr
clp::STAT_UINT get_nb_top_store_addr(void)
Definition: ClpAnalysis.h:59
otawa::clp::Analysis::get_nb_top_filters
clp::STAT_UINT get_nb_top_filters(void)
Definition: ClpAnalysis.h:67
Processor.h
otawa::WorkSpace
Definition: WorkSpace.h:71
otawa::clp::Analysis::_nb_top_store_addr
clp::STAT_UINT _nb_top_store_addr
Definition: ClpAnalysis.h:82
otawa::Processor::ws
WorkSpace * ws
Definition: Processor.h:189
otawa::clp::Analysis::verbose
bool verbose
Definition: ClpAnalysis.h:88
otawa::Processor
Definition: Processor.h:50
elm::Pair
otawa::clp::Analysis::inits
Vector< init_t > inits
Definition: ClpAnalysis.h:74
otawa::clp::Analysis::configure
void configure(const PropList &props) override
Build the initial configuration of the Analysis fro a property list.
Definition: clp_analysis.cpp:3532
ClpState.h
otawa::clp::Analysis::get_nb_set
clp::STAT_UINT get_nb_set(void)
Definition: ClpAnalysis.h:51
otawa::clp::Analysis::setup
void setup(WorkSpace *ws) override
This method is called before an anlysis to let the processor do some initialization.
Definition: clp_analysis.cpp:3392
otawa::clp::Analysis::get_nb_filters
clp::STAT_UINT get_nb_filters(void)
Definition: ClpAnalysis.h:65
otawa::clp::Analysis
Definition: ClpAnalysis.h:36
otawa::clp::Analysis::get_nb_store
clp::STAT_UINT get_nb_store(void)
Definition: ClpAnalysis.h:55
otawa::clp::Analysis::_nb_load
clp::STAT_UINT _nb_load
Definition: ClpAnalysis.h:83
otawa::clp::Analysis::get_nb_top_set
clp::STAT_UINT get_nb_top_set(void)
Definition: ClpAnalysis.h:53
otawa::clp::Analysis::reg
static p::declare reg
Definition: ClpAnalysis.h:41
otawa::Identifier
Definition: Identifier.h:50
elm::Vector
otawa::clp::Analysis::_nb_inst
clp::STAT_UINT _nb_inst
Definition: ClpAnalysis.h:77
otawa::clp::Analysis::_nb_filters
clp::STAT_UINT _nb_filters
Definition: ClpAnalysis.h:86
otawa::hard::Memory
Definition: Memory.h:180
otawa::clp::Analysis::_nb_top_store
clp::STAT_UINT _nb_top_store
Definition: ClpAnalysis.h:81
otawa::clp::Analysis::mem
const hard::Memory * mem
Definition: ClpAnalysis.h:76
otawa::clp::Analysis::INITIAL
static Identifier< init_t > INITIAL
Initial state of the analysis.
Definition: ClpAnalysis.h:40
otawa::clp::Analysis::get_nb_load
clp::STAT_UINT get_nb_load(void)
Definition: ClpAnalysis.h:61
otawa::clp::Analysis::_nb_store
clp::STAT_UINT _nb_store
Definition: ClpAnalysis.h:80
otawa::clp::Analysis::_nb_load_top_addr
clp::STAT_UINT _nb_load_top_addr
Definition: ClpAnalysis.h:85
otawa::clp::Analysis::_nb_set
clp::STAT_UINT _nb_set
Definition: ClpAnalysis.h:78
otawa::clp::Analysis::get_nb_top_store
clp::STAT_UINT get_nb_top_store(void)
Definition: ClpAnalysis.h:57
otawa::p::declare
Definition: Registration.h:188
otawa::clp::STAT_UINT
t::uint64 STAT_UINT
Definition: ClpValue.h:38
otawa::clp::Analysis::processWorkSpace
void processWorkSpace(WorkSpace *ws) override
Perform the analysis by processing the workspace.
Definition: clp_analysis.cpp:3401
otawa::clp::Analysis::_nb_top_load
clp::STAT_UINT _nb_top_load
Definition: ClpAnalysis.h:84
otawa::clp::Analysis::_nb_top_set
clp::STAT_UINT _nb_top_set
Definition: ClpAnalysis.h:79
otawa::clp::Analysis::init_t
Pair< const hard::Register *, Address > init_t
Definition: ClpAnalysis.h:38
otawa::PropList
Definition: PropList.h:67
otawa::clp::Analysis::get_nb_load_top_addr
clp::STAT_UINT get_nb_load_top_addr(void)
Definition: ClpAnalysis.h:63
otawa::clp::Analysis::get_nb_sem_inst
clp::STAT_UINT get_nb_sem_inst(void)
Definition: ClpAnalysis.h:49
otawa::clp::Analysis::Analysis
Analysis(p::declare &r=reg)
Definition: clp_analysis.cpp:3371
otawa
Development Note Letting the ToDo / ToDoList class visible in the header is clumsy.
Definition: ArrayStore.h:25