Title: Resource Interfaces
1Resource Interfaces
- Arindam Chakrabarti Luca de Alfaro
- Thomas A. Henzinger Mariëlle Stoelinga
- arindam,tah_at_eecs.berkeley.edu
- luca,marielle_at_soe.ucsc.edu
2Resource Interfaces
- Correctness of embedded software
- Ensure behavioral correctness
- Satisfy resource-usage constraints
- Resource interfaces Automata-based type system
for compositional state-aware resource-usage
analysis of open systems
3Interfaces
- Static interfaces
- Dynamic interfaces
- Resource interfaces
4A Static Interface
This interface constrains the users data. e.g.
typed programming languages
5Static Interface Compatibility
6Static Interface Compatibility
Input and Output types match ) compatible
7Static Interface Incompatibility
Input Output type mismatch ) not compatible
8Static Interface Composition
9Static Interface Composition
Forget many internal details on composition.
10Static Interface Composition
int
int
int
bool
Just remember interface to external environment.
11A Dynamic Interface
This interface constrains the clients
behavior. eg. our Java extension CHIC (CHecking
Interface Compatibility).
12Dynamic Interface Compatibility
Sequence of inputs and outputs match up )
compatible
13Dynamic Interface Incompatibility
14Dynamic Interface Incompatibility
Output produced but not expected ) not compatible
15Dynamic Interface Composition
16Dynamic Interface Composition
17Dynamic Interface Composition
18Dynamic Interface Composition
19Dynamic Interface Composition
20Interfaces constrain the inputs
Interfaces are Games!
-Player Environment vs. player System. -The
composite interface is the most general strategy
of player Environment to avoid incompatibilities.
21Dynamic Interface Incompatibility
22Resource Interface Incompatibility Node Limit
23Resource Interface Incompatibility Path Limit
24Resource Interface Incompatibility Path Limit
25Resource Interface Incompatibility Path Limit
26Resource Interface Incompatibility Path Limit
27Resource Interface Incompatibility Path Limit
28Resource Interface Composition Node Limit
29Resource Interface Composition Node Limit
30Resource Interface Composition Node Limit
31Resource Interface Composition Node Limit
32Resource Interface Composition Node Limit
33Resource Interface Composition Path Limit
34Resource Interface Composition Path Limit
35Resource Interface Composition Path Limit
36Resource Interface Composition Path Limit
37Resource Interface Composition Path Limit
38Resource Interface Composition Path Limit
39Resource Interface Composition Path Limit
40Resource Interface Composition Path Limit
41Resource Interface Composition Path Limit
42Resource Interface Composition Path Limit
43Resource Interface Composition Path Limit
44Resource Interface Composition Path Limit
45Resource Interface Composition Path Limit
46Motor driver in Lego robot
47Sensornet node with buffer of size 3
48Two classes of Resource Interfaces
Node Limit Resource Interfaces (e.g. mutex,
limited buffer size, limited peak power) Player
Input must forever avoid states that exceed the
Node Limit.
49Two classes of Resource Interfaces
Node Limit Resource Interfaces (e.g. mutex,
limited buffer size, limited peak power) Player
Input must forever avoid states that exceed the
Node Limit. Path Limit Resource Interfaces
(e.g. limited battery capacity) Player Input
must forever avoid paths that exceed the Path
Limit.
50Two synthesis questions
Strategy Synthesis (e.g.
resource scheduler, sensornet routing
algorithm) Given a resource bound, how can
player Input achieve her objective ?
51Two synthesis questions
Strategy Synthesis (e.g.
resource scheduler, sensornet routing
algorithm) Given a resource bound, how can
player Input achieve her objective ? Resource
Synthesis
(e.g. necessary buffer size,
battery capacity) What is the minimum resource
requirement so that player Input can achieve her
objective ? Game algorithms can be generalized
to answer both.
52Efficient algorithms
- Node Limit
- Strategy synthesis
- Resource synthesis
- Path Limit
- Strategy synthesis
- Resource synthesis
53Complexity results
54Complexity results
55Example Applications
- Synthesizing a Scheduling algorithm for a given
set of threads running on a lego robot - Synthesizing a Routing algorithm for a given
sensornet
56Resource interfaces
- Methodology for compositional, state-aware
analysis of resource usage of open systems - Efficient algorithms for finding how a set of
components can be made to work together using the
least amount of a scarce resource - Algorithms implemented in our tool Chic
57Software
CHIC JBuilder/ Ptolemy plugin for defining and
checking dynamic, Node limit, Path limit and
resource interfaces.
58Chic plug-in for JBuilder
59Chic plug-in for Ptolemy(thanks to Eleftherios
Matsikoudis)
60Chic plug-in for Ptolemy(thanks to Eleftherios
Matsikoudis)
61Check out our tool !
- Chic Checking Interface Compatibility
- http//www.eecs.berkeley.edu/tah/chic/
- Thanks for listening ! More Questions ?