![]() |
OTAWA
2.0
Framework to perform machine analysis and compute WCET.
|
This module aims to make more generic how events (cache hits/misses, branch prediction, etc) are processed to generate block time. More...
Classes | |
class | otawa::etime::AbstractTimeBuilder |
class | otawa::etime::EdgeTimeBuilder |
class | otawa::etime::EdgeTimeGraph |
class | otawa::etime::EventCase |
class | otawa::etime::Factory |
class | otawa::etime::ILPGenerator |
class | otawa::etime::StandardEventBuilder |
class | otawa::etime::StandardFactory |
class | otawa::etime::StandardILPGenerator |
class | otawa::etime::StandardXGraphBuilder |
class | otawa::etime::StepGraphBuilder |
class | otawa::etime::TimeUnitTimer |
class | otawa::etime::Unit |
class | otawa::etime::XGraphBuilder |
class | otawa::etime::XGraphSolver |
Functions | |
p::feature | otawa::etime::EDGE_TIME_FEATURE ("otawa::etime::EDGE_TIME_FEATURE", new Maker< EdgeTimeBuilder >()) |
This feature ensures that block cost has been computed according to the context of edges. More... | |
p::id< int > | otawa::etime::EVENT_THRESHOLD ("otawa::etime::EVENT_THRESHOLD", 15) |
This property is used to configure the EDGE_TIME_FEATURE and determine the maximum number of events to consider to time a block. More... | |
p::feature | otawa::etime::EVENTS_FEATURE ("otawa::etime::EVENTS_FEATURE", new Maker< StandardEventBuilder >()) |
This feature ensures that all timing events on pipeline has been recorded. More... | |
p::id< Pair< ot::time, ilp::Var * > > | otawa::etime::HTS_CONFIG ("otawa::etime::HTS_CONFIG", pair< ot::time, ilp::Var * >(0, nullptr)) |
Produced only if the RECORD_TIME configuration is set, record for each edge a pair(t, x) where (a) t the difference between maximum time of low-time-set and the maximum time of high-time-set (in cycles) (b) x is an ILP variable that represents the occurrences of this time. More... | |
p::id< ot::time > | otawa::etime::LTS_TIME ("otawa::etime::LTS_TIME", -1) |
Produced only if the RECORD_TIME configuration is set, record for each edge the low-time-set maximum time in cycles. More... | |
p::id< bool > | otawa::etime::NO_ILP_OBJECTIVE ("otawa::etime::NO_ILP_OBJECTIVE") |
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed. More... | |
p::id< bool > | otawa::etime::ONLY_START ("otawa::etime::ONLY_START") |
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed. More... | |
p::id< bool > | otawa::etime::PREDUMP ("otawa::etime::PREDUMP", false) |
This property is used to configure the EDGE_TIME_FEATURE and ask to dump the generated execution graphs. More... | |
p::id< bool > | otawa::etime::RECORD_TIME ("otawa::etime::RECORD_TIME", false) |
Configuration property of EDGE_TIME_FEATURE, if true, enable the production of LTS_TIME and HTS_OFFSET on the edge. More... | |
p::feature | otawa::etime::STANDARD_EVENTS_FEATURE ("otawa::etime::STANDARD_EVENTS_FEATURE", new Maker< StandardEventBuilder >()) |
This feature ensures that events of the following analyses has been hooked to the task basic blocks: More... | |
p::id< Unit * > | otawa::etime::TIME_UNIT ("otawa::etime::TIME_UNIT", 0) |
Provides the time unit hooked to a basic block. More... | |
p::feature | otawa::etime::UNIT_FEATURE ("otawa::etime::UNIT_FEATURE", p::make< TimeUnitBuilder >()) |
This feature ensures that the time units has been built for each basic block. More... | |
Variables | |
p::feature | otawa::etime::EDGE_TIME_FEATURE |
This feature ensures that block cost has been computed according to the context of edges. More... | |
p::id< int > | otawa::etime::EVENT_THRESHOLD |
This property is used to configure the EDGE_TIME_FEATURE and determine the maximum number of events to consider to time a block. More... | |
p::feature | otawa::etime::EVENTS_FEATURE |
This feature ensures that all timing events on pipeline has been recorded. More... | |
p::id< Pair< ot::time, ilp::Var * > > | otawa::etime::HTS_CONFIG |
Produced only if the RECORD_TIME configuration is set, record for each edge a pair(t, x) where (a) t the difference between maximum time of low-time-set and the maximum time of high-time-set (in cycles) (b) x is an ILP variable that represents the occurrences of this time. More... | |
p::id< ot::time > | otawa::etime::LTS_TIME |
Produced only if the RECORD_TIME configuration is set, record for each edge the low-time-set maximum time in cycles. More... | |
p::id< bool > | otawa::etime::NO_ILP_OBJECTIVE |
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed. More... | |
p::id< bool > | otawa::etime::ONLY_START |
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed. More... | |
p::id< bool > | otawa::etime::PREDUMP |
This property is used to configure the EDGE_TIME_FEATURE and ask to dump the generated execution graphs. More... | |
p::id< bool > | otawa::etime::RECORD_TIME |
Configuration property of EDGE_TIME_FEATURE, if true, enable the production of LTS_TIME and HTS_OFFSET on the edge. More... | |
p::feature | otawa::etime::STANDARD_EVENTS_FEATURE |
This feature ensures that events of the following analyses has been hooked to the task basic blocks: More... | |
p::id< Unit * > | otawa::etime::TIME_UNIT |
Provides the time unit hooked to a basic block. More... | |
p::feature | otawa::etime::UNIT_FEATURE |
This feature ensures that the time units has been built for each basic block. More... | |
This module aims to make more generic how events (cache hits/misses, branch prediction, etc) are processed to generate block time.
The basic idea is that each analysis contributes to the WCET by defining the events (changes of the execution time) applying to instructions or a blocks. As a result, these events are hooked to the basic block they apply to and defines (a) which instruction is concerned, (b) which part of the instruction execution they apply to (memory access, stage, functional unit, etc) and (c) how they contribute to the time.
In addition, an event may c contribute to the constraints of the ILP system and may be asked to provide an overestimation or an underestimation of their occurrence according to their contribution (worst case time or best case time) to the WCET.
From the events, several policies may be applied to compute the times, to select the granularity and the precision of the computed time or to choose a way to split the CFG into blocks.
The execution times are computed based on a= "time unit". An execution unit is made of a block, for which time is computed, and a prefix (made of 0 or several other blocks). The prefix allows to more precisely take into account the overlap effect of sequential execution of blocks. In the current version, we only support prefixes of 1 block but this may be extended in the next versions of this plugin.
The time unit are stored and built for each basic block by examining the predecessors and counting the occurrences of this time using the corresponding edge. Because of the CFG structure of OTAWA, the following rules are applied to build the prefixes of a basic block v for a predecessor w:
The structure of the CFG and the possible transformations of it does not allow to always get (a) a right prefix and (b) a count of this prefix. Yet, as these cases are so infrequent and as they be replaced by an overestimation of the actual time, they do not represent an issue in the WCET computation.
When building the set of time unit, one has to keep in mind that the sum of the frequency of the time unit edge must be equal to the frequency of the current block!
p::feature otawa::etime::EDGE_TIME_FEATURE | ( | "otawa::etime::EDGE_TIME_FEATURE" | , |
new Maker< EdgeTimeBuilder > | () | ||
) |
This feature ensures that block cost has been computed according to the context of edges.
Basically, this means that both the objective function and the constraint of events has been added to the ILP system.
Configuration
Properties
p::id<int> otawa::etime::EVENT_THRESHOLD | ( | "otawa::etime::EVENT_THRESHOLD" | , |
15 | |||
) |
This property is used to configure the EDGE_TIME_FEATURE and determine the maximum number of events to consider to time a block.
If a value of n is passed, at most 2^n times will be computed and if a block gets a bigger number of events, it will be split.
p::feature otawa::etime::EVENTS_FEATURE | ( | "otawa::etime::EVENTS_FEATURE" | , |
new Maker< StandardEventBuilder > | () | ||
) |
This feature ensures that all timing events on pipeline has been recorded.
p::id<Pair<ot::time, ilp::Var *> > otawa::etime::HTS_CONFIG | ( | "otawa::etime::HTS_CONFIG" | , |
pair< ot::time, ilp::Var * > | 0, nullptr | ||
) |
Produced only if the RECORD_TIME configuration is set, record for each edge a pair(t, x) where (a) t the difference between maximum time of low-time-set and the maximum time of high-time-set (in cycles) (b) x is an ILP variable that represents the occurrences of this time.
If an instruction sequence s with occurrence x_s has too many events, it will split in subsequence and each subsequence will have its own HTS_CONFIG accumulated on the sequence.
Produced only if the RECORD_TIME configuration is set, record for each edge the low-time-set maximum time in cycles.
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed.
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed.
This property is used to configure the EDGE_TIME_FEATURE and ask to dump the generated execution graphs.
Configuration property of EDGE_TIME_FEATURE, if true, enable the production of LTS_TIME and HTS_OFFSET on the edge.
p::feature otawa::etime::STANDARD_EVENTS_FEATURE | ( | "otawa::etime::STANDARD_EVENTS_FEATURE" | , |
new Maker< StandardEventBuilder > | () | ||
) |
This feature ensures that events of the following analyses has been hooked to the task basic blocks:
Provides the time unit hooked to a basic block.
Depending on the number of prefixes to compute the time of a block, the basic block may have zero to several of these annotations tied.
p::feature otawa::etime::UNIT_FEATURE | ( | "otawa::etime::UNIT_FEATURE" | , |
p::make< TimeUnitBuilder > | () | ||
) |
This feature ensures that the time units has been built for each basic block.
p::feature otawa::etime::EDGE_TIME_FEATURE("otawa::etime::EDGE_TIME_FEATURE", new Maker< EdgeTimeBuilder >()) |
This feature ensures that block cost has been computed according to the context of edges.
Basically, this means that both the objective function and the constraint of events has been added to the ILP system.
Configuration
Properties
p::id<int> otawa::etime::EVENT_THRESHOLD("otawa::etime::EVENT_THRESHOLD", 15) |
This property is used to configure the EDGE_TIME_FEATURE and determine the maximum number of events to consider to time a block.
If a value of n is passed, at most 2^n times will be computed and if a block gets a bigger number of events, it will be split.
Referenced by otawa::etime::EdgeTimeBuilder::configure(), otawa::etime::StandardILPGenerator::configure(), and otawa::etime::AbstractTimeBuilder::configure().
p::feature otawa::etime::EVENTS_FEATURE("otawa::etime::EVENTS_FEATURE", new Maker< StandardEventBuilder >()) |
This feature ensures that all timing events on pipeline has been recorded.
p::id<Pair<ot::time, ilp::Var *> > otawa::etime::HTS_CONFIG("otawa::etime::HTS_CONFIG", pair< ot::time, ilp::Var * >(0, nullptr)) |
Produced only if the RECORD_TIME configuration is set, record for each edge a pair(t, x) where (a) t the difference between maximum time of low-time-set and the maximum time of high-time-set (in cycles) (b) x is an ILP variable that represents the occurrences of this time.
If an instruction sequence s with occurrence x_s has too many events, it will split in subsequence and each subsequence will have its own HTS_CONFIG accumulated on the sequence.
Referenced by otawa::etime::EdgeTimeBuilder::contributeSplit(), and otawa::etime::StandardILPGenerator::contributeTime().
Produced only if the RECORD_TIME configuration is set, record for each edge the low-time-set maximum time in cycles.
Referenced by otawa::etime::StandardILPGenerator::contributeBase(), and otawa::etime::EdgeTimeBuilder::contributeSplit().
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed.
Configuration for EDGE_TIME_FEATURE indicating that only the start resource must be computed.
Referenced by otawa::etime::AbstractTimeBuilder::configure().
This property is used to configure the EDGE_TIME_FEATURE and ask to dump the generated execution graphs.
Referenced by otawa::etime::EdgeTimeBuilder::configure(), and otawa::etime::AbstractTimeBuilder::configure().
Configuration property of EDGE_TIME_FEATURE, if true, enable the production of LTS_TIME and HTS_OFFSET on the edge.
Referenced by otawa::etime::EdgeTimeBuilder::configure(), and otawa::etime::AbstractTimeBuilder::configure().
p::feature otawa::etime::STANDARD_EVENTS_FEATURE("otawa::etime::STANDARD_EVENTS_FEATURE", new Maker< StandardEventBuilder >()) |
This feature ensures that events of the following analyses has been hooked to the task basic blocks:
Provides the time unit hooked to a basic block.
Depending on the number of prefixes to compute the time of a block, the basic block may have zero to several of these annotations tied.
p::feature otawa::etime::UNIT_FEATURE("otawa::etime::UNIT_FEATURE", p::make< TimeUnitBuilder >()) |
This feature ensures that the time units has been built for each basic block.