ExistHitPrevAnalysis.h 1.85 KB
Newer Older
1 2
#ifndef LRUSECURITY_EXIST_HIT_ANALYSIS_H_
#define LRUSECURITY_EXIST_HIT_ANALYSIS_H_
3 4 5 6

#include <otawa/proc/Processor.h>
#include <otawa/icat3/features.h>
#include <otawa/cfg/features.h>
Maeva Ramarjiaona's avatar
Maeva Ramarjiaona committed
7
#include <lrusecurity/ACSSecurity.h>
8
namespace lrusecurity
9 10
{

11
class ExistHitPrevAnalysis: public otawa::Processor
12 13 14
{
public:
	static otawa::p::declare reg;
Maeva Ramarjiaona's avatar
Maeva Ramarjiaona committed
15
	ExistHitPrevAnalysis(otawa::p::declare& r = reg);
16 17 18 19 20 21 22 23 24 25 26

protected:

	void configure(const otawa::PropList& props) override;
	void setup(otawa::WorkSpace* ws) override;
	void processWorkSpace(otawa::WorkSpace* ws) override;
	void destroy(otawa::WorkSpace* ws) override;

private:
	void processSet(int i, otawa::WorkSpace* ws);

27
	const otawa::icat3::Container<ACSSecurity>* _initExistHitPrev;
28 29 30 31 32 33 34
	const otawa::icat3::LBlockCollection* _coll;
	const otawa::CFGCollection* _cfgs;
};

/**
 * Perform the ACS analysis for the Exist-Hit domain. For cache block, it associates an upper bound on block age that holds on at least on path
 * @par Properties
35
 * @li @ref EXIST_HIT_PREV_IN
36 37
 *
 * @par Configuraiton
38
 * @li @ref EXIST_HIT_PREV_INIT
39 40
 *
 * @par Implementation
41
 * @li @ref ExistHitPrevAnalysis
42
 *
43
 * @ingroup lrusecurity
44
 */
45
extern otawa::p::feature EXIST_HIT_PREV_ANALYSIS_FEATURE;
46 47

/**
48
 * ACSSecurity for the Exist-Hit analysis at the entry of the corresponding block or edge.
49 50
 *
 * @par Feature
51
 * @li @ref EXIST_HIT_ANALYSIS_PREV_FEATURE
52 53 54 55 56
 *
 * @par Hooks
 * @li @ref Block
 * @li @ref Edge
 *
57
 * @ingroup lrusecurity
58
 */
59
 extern otawa::p::id<otawa::icat3::Container<ACSSecurity> > EXIST_HIT_PREV_IN;
60 61 62 63 64 65 66 67 68


/**
 * Initial state for Exist-Miss instruction cache analysis.
 *
 * @par Hook
 * @li Feature configuration.
 *
 * @par Feature
69
 * @li @ref EXIST_HIT_ANALYSIS_PREV_FEATURE
70
 *
71
 * @ingroup lrusecurity
72
 */
73
 extern otawa::p::id<otawa::icat3::Container<ACSSecurity> > EXIST_HIT_PREV_INIT;
74

75
}; // namespace lrusecurity
76

77
#endif // LRUSECURITY_EXIST_HIT_ANALYSIS_H_