Execution Trace Management to Support Dynamic V&V for Executable - - PowerPoint PPT Presentation

execution trace management to support dynamic v v for
SMART_READER_LITE
LIVE PREVIEW

Execution Trace Management to Support Dynamic V&V for Executable - - PowerPoint PPT Presentation

Introduction Contribution Evaluation Conclusion Execution Trace Management to Support Dynamic V&V for Executable DSMLs Ph.D defense December 3, 2015 Jury Erwan Bousse Prof. Gerti Kappel, TU Wien / rapporteur Prof. Franck Barbier, UPPA /


slide-1
SLIDE 1

Introduction Contribution Evaluation Conclusion

Execution Trace Management to Support Dynamic V&V for Executable DSMLs

Ph.D defense December 3, 2015 Jury

  • Prof. Gerti Kappel, TU Wien / rapporteur
  • Prof. Franck Barbier, UPPA / rapporteur
  • Dr. Julien DeAntoni, UNS / examinateur
  • Prof. Fran¸

cois Ta¨ ıani, UR1 / examinateur

  • Dr. Benoit Baudry, Inria / directeur de th`

ese

  • Dr. Benoit Combemale, Inria – UR1 / co-encadrant

Erwan Bousse

University of Rennes 1

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-2
SLIDE 2

Introduction Contribution Evaluation Conclusion

Increasing complexity of systems

Systems are more and more complex: cyber physical systems, internet of things, massively multiplayer games, . . . One system = diverse and heterogeneous domains ⇒ Many threats to their proper development and functioning

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 1/32

slide-3
SLIDE 3

Introduction Contribution Evaluation Conclusion

Model driven engineering (MDE)

Target system Design model Resulting system

... and many

  • ther models

Separation of concerns through the use of models Using domain specific modeling languages (DSMLs) Enables early verification and validation (early V&V)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 2/32

slide-4
SLIDE 4

Introduction Contribution Evaluation Conclusion

Dynamic V&V of behavioral models

Behavioral models are essential in various domains and in various forms of engineering Dynamic V&V required to check their behavioral properties

– requires models to be executable – requires defining the execution semantics of the DSMLs

Execution semantics are composed of

– definition of the execution state of conforming models – definition of the execution function that changes this state

DSML + execution semantics = executable DSML (xDSML)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 3/32

slide-5
SLIDE 5

Introduction Contribution Evaluation Conclusion

Dynamic V&V of behavioral models

Behavioral models are essential in various domains and in various forms of engineering Dynamic V&V required to check their behavioral properties

– requires models to be executable – requires defining the execution semantics of the DSMLs

Execution semantics are composed of

– definition of the execution state of conforming models – definition of the execution function that changes this state

DSML + execution semantics = executable DSML (xDSML)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 3/32

slide-6
SLIDE 6

Introduction Contribution Evaluation Conclusion

Dynamic V&V of behavioral models

Behavioral models are essential in various domains and in various forms of engineering Dynamic V&V required to check their behavioral properties

– requires models to be executable – requires defining the execution semantics of the DSMLs

Execution semantics are composed of

– definition of the execution state of conforming models – definition of the execution function that changes this state

DSML + execution semantics = executable DSML (xDSML)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 3/32

slide-7
SLIDE 7

Introduction Contribution Evaluation Conclusion

Scope and hypotheses

Modeling languages General-purpose languages (GPLs) Domain-specific languages (DSMLs) . . . Executable DSMLs (xDSMLs) . . . with translational semantics with operational semantics execution concepts in abstract syntax separation of execution concepts

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 4/32

slide-8
SLIDE 8

Introduction Contribution Evaluation Conclusion

Scope and hypotheses

Modeling languages General-purpose languages (GPLs) Domain-specific languages (DSMLs) . . . Executable DSMLs (xDSMLs) . . . with translational semantics with operational semantics execution concepts in abstract syntax separation of execution concepts

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 4/32

slide-9
SLIDE 9

Introduction Contribution Evaluation Conclusion

Scope and hypotheses

Modeling languages General-purpose languages (GPLs) Domain-specific languages (DSMLs) . . . Executable DSMLs (xDSMLs) . . . with translational semantics with operational semantics execution concepts in abstract syntax separation of execution concepts

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 4/32

slide-10
SLIDE 10

Introduction Contribution Evaluation Conclusion

Scope and hypotheses

Modeling languages General-purpose languages (GPLs) Domain-specific languages (DSMLs) . . . Executable DSMLs (xDSMLs) . . . with translational semantics with operational semantics execution concepts in abstract syntax separation of execution concepts

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 4/32

slide-11
SLIDE 11

Introduction Contribution Evaluation Conclusion

Scope and hypotheses

Modeling languages General-purpose languages (GPLs) Domain-specific languages (DSMLs) . . . Executable DSMLs (xDSMLs) . . . with translational semantics with operational semantics execution concepts in abstract syntax separation of execution concepts

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 4/32

slide-12
SLIDE 12

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-13
SLIDE 13

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Petri net model

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-14
SLIDE 14

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Place

+name: string +initialTokens: int

p1 p3 p4 p2

init=1 init=0 init=0 init=1

Petri net model

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-15
SLIDE 15

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Place

+name: string +initialTokens: int

Transition

+name: string

Place

+name: string +initialTokens: int

p1 p3 p4 p2

init=1 init=0 init=0 init=1

t1 t2

Petri net model

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-16
SLIDE 16

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

p1 p3 p4 p2

init=1 init=0 init=0 init=1

t1 t2

Petri net model conforms to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-17
SLIDE 17

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Place

+name: string +initialTokens: int

Transition

+name: string

Place

+name: string +initialTokens: int imports merges Execution Metamodel

Place

+tokens: int Execution transformation rules (summarized) : while there is an enabled transition, fires it. : removes a token from each input Place and adds a token to each output Place. run(Net) fire(Transition)

Transition

+name: string Operational semantics : while there is an enabled transition, fires it. : removes a token from each input Place, and adds a token to each output Place.

p1 p3 p4 p2

init=1 init=0 init=0 init=1

t1 t2

Petri net model conforms to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-18
SLIDE 18

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Place

+name: string +initialTokens: int

Transition

+name: string

Place

+name: string +initialTokens: int imports merges Execution Metamodel

Place

+tokens: int Execution transformation rules (summarized) : while there is an enabled transition, fires it. : removes a token from each input Place and adds a token to each output Place. run(Net) fire(Transition)

Transition

+name: string Operational semantics : while there is an enabled transition, fires it. : removes a token from each input Place, and adds a token to each output Place.

p1 p3 p4 p2

init=1 init=0 init=0 init=1

t1 t2

Petri net model

initialization

− − − − − − − →

p1 p3 p4 p2 t1 t2

Executed model conforms to conforms to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-19
SLIDE 19

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Place

+name: string +initialTokens: int

Transition

+name: string

Place

+name: string +initialTokens: int imports merges Execution Metamodel

Place

+tokens: int Execution transformation rules (summarized) : while there is an enabled transition, fires it. : removes a token from each input Place and adds a token to each output Place. run(Net) fire(Transition)

Transition

+name: string Operational semantics : while there is an enabled transition, fires it. : removes a token from each input Place, and adds a token to each output Place.

p1 p3 p4 p2

init=1 init=0 init=0 init=1

t1 t2

Petri net model

initialization

− − − − − − − →

p1 p3 p4 p2 t1 t2

Executed model

(t1 fired)

conforms to conforms to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-20
SLIDE 20

Introduction Contribution Evaluation Conclusion

Example of Petri net xDSML and model

Abstract Syntax input 1..*

  • utput

1..*

Net Place

+name: string +initialTokens: int

Transition

+name: string transitions * places *

Place

+name: string +initialTokens: int

Transition

+name: string

Place

+name: string +initialTokens: int imports merges Execution Metamodel

Place

+tokens: int Execution transformation rules (summarized) : while there is an enabled transition, fires it. : removes a token from each input Place and adds a token to each output Place. run(Net) fire(Transition)

Transition

+name: string Operational semantics : while there is an enabled transition, fires it. : removes a token from each input Place, and adds a token to each output Place.

p1 p3 p4 p2

init=1 init=0 init=0 init=1

t1 t2

Petri net model

initialization

− − − − − − − →

p1 p3 p4 p2 t1 t2

Executed model

(t1 fired) (t2 fired)

conforms to conforms to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 5/32

slide-21
SLIDE 21

Introduction Contribution Evaluation Conclusion

Representing executions as traces

How to represent executions in order to analyze them? Example of a Petri net execution trace:

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

Execution states, each storing the values of the mutable parts of the model (e.g. tokens) Execution steps, each being the application of a transformation rule of the operational semantics, with:

– small steps in between execution states (e.g. fire) – big steps containing multiple steps (e.g. run)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 6/32

slide-22
SLIDE 22

Introduction Contribution Evaluation Conclusion

Representing executions as traces

How to represent executions in order to analyze them? Example of a Petri net execution trace:

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

Execution states, each storing the values of the mutable parts of the model (e.g. tokens) Execution steps, each being the application of a transformation rule of the operational semantics, with:

– small steps in between execution states (e.g. fire) – big steps containing multiple steps (e.g. run)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 6/32

slide-23
SLIDE 23

Introduction Contribution Evaluation Conclusion

Difficulties in trace management

Execution traces can be large

– Requires large amounts of memory to construct a trace – Impacts processing time during analyses – example: looping small petri net (4 places and 3 transitions), 150 000 states = 130 MB

Many kinds of trace manipulations

– Generic (e.g. amount of steps) – Domain-specific (e.g. number of tokens that traversed a place)

Many possible xDSMLs

– Existing ones (e.g. Petri net, Activity diagrams) – Future ones (cf. language engineering)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 7/32

slide-24
SLIDE 24

Introduction Contribution Evaluation Conclusion

Difficulties in trace management

Execution traces can be large

– Requires large amounts of memory to construct a trace – Impacts processing time during analyses – example: looping small petri net (4 places and 3 transitions), 150 000 states = 130 MB

Many kinds of trace manipulations

– Generic (e.g. amount of steps) – Domain-specific (e.g. number of tokens that traversed a place)

Many possible xDSMLs

– Existing ones (e.g. Petri net, Activity diagrams) – Future ones (cf. language engineering)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 7/32

slide-25
SLIDE 25

Introduction Contribution Evaluation Conclusion

Difficulties in trace management

Execution traces can be large

– Requires large amounts of memory to construct a trace – Impacts processing time during analyses – example: looping small petri net (4 places and 3 transitions), 150 000 states = 130 MB

Many kinds of trace manipulations

– Generic (e.g. amount of steps) – Domain-specific (e.g. number of tokens that traversed a place)

Many possible xDSMLs

– Existing ones (e.g. Petri net, Activity diagrams) – Future ones (cf. language engineering)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 7/32

slide-26
SLIDE 26

Introduction Contribution Evaluation Conclusion

Problem statement How to provide efficient execution trace management facilities for any xDSML?

Three main inter-related challenges:

1 Scalability in memory to construct large traces 2 Scalability in time to process large traces 3 Usability of the execution trace data structure, to cope with

the complexity of data of arbitrarily complex xDSMLs

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 8/32

slide-27
SLIDE 27

Introduction Contribution Evaluation Conclusion

Contributions and applications

Multidimensionnal domain-specific trace metamodel generation [ECMFA’15] Enhanced semantic differencing

applied to

Advanced and efficient

  • mniscient debugging [SLE’15]

applied to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 9/32

Scalable armies of model clones

[MODELS’14]

slide-28
SLIDE 28

Introduction Contribution Evaluation Conclusion

Contributions and applications

Multidimensionnal domain-specific trace metamodel generation [ECMFA’15] Enhanced semantic differencing

applied to

Advanced and efficient

  • mniscient debugging [SLE’15]

applied to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 9/32

slide-29
SLIDE 29

Introduction Contribution Evaluation Conclusion

Contributions and applications

Multidimensionnal domain-specific trace metamodel generation [ECMFA’15] Enhanced semantic differencing

applied to

Advanced and efficient

  • mniscient debugging [SLE’15]

applied to

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 9/32

slide-30
SLIDE 30

Introduction Contribution Evaluation Conclusion

Outline

1 Introduction 2 Contribution 3 Evaluation 4 Conclusion

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

Multidimensionnal domain-specific trace metamodel generation [ECMFA’15]

slide-31
SLIDE 31

Introduction Contribution Evaluation Conclusion

Generic trace management

State of the art: generic trace metamodel [Langer et al.’14]

Trace State Transition Event qualifiedName : String Object

states * transitions * event 1 source 1

  • utgoing

0..1 target 1 incoming 0..1

  • bjects *

{ordered=true}

States are stored in an unique sequence Each state is a snapshot (or clone) of the executed model

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 10/32

slide-32
SLIDE 32

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-33
SLIDE 33

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-34
SLIDE 34

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-35
SLIDE 35

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-36
SLIDE 36

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

for (object : state.getObjects()) { if (object instanceof Place) { Place p = (Place) object; .. } else if (object instanceof Transition) { Transition t = (Transition) object; ... } }

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-37
SLIDE 37

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

for (object : state.getObjects()) { if (object instanceof Place) { Place p = (Place) object; .. } else if (object instanceof Transition) { Transition t = (Transition) object; ... } }

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-38
SLIDE 38

Introduction Contribution Evaluation Conclusion

Example of Petri net generic trace

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4 p1 t1 p3 t2 p4 p2 fire(t1) fire(t2) run()

  • bjects

s2 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 1 : Place name = “p4" tokens = 0

  • bjects

s3 : State : Place name = “p1" tokens = 0 : Place name = “p2" tokens = 0 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 1

  • bjects

s1 : State : Place name = “p1" tokens = 1 : Place name = “p2" tokens = 1 : Place name = “p3" tokens = 0 : Place name = “p4" tokens = 0 : Trace

states

: Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net : Transition name = “t1" : Transition name = “t2" : Net

for (object : state.getObjects()) { if (object instanceof Place) { Place p = (Place) object; .. } else if (object instanceof Transition) { Transition t = (Transition) object; ... } }

Scalability in time problem: need to visit all states Memory problem: redundancy with both immutable and mutable data Usability problem: type checks and casting

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 11/32

slide-39
SLIDE 39

Introduction Contribution Evaluation Conclusion

Approach: generating a domain-specific trace metamodel

To provide usability and scalability in memory

Generative approach to automatically derive a domain-specific trace metamodel for a given xDSML Domain-specific: domain concepts are directly accessible Precise: only concepts related to execution are kept Automated: save language engineers the design of a complex metamodel, which is time-consuming and error-prone

To provide scalability in time

Multidimensional navigation facilities, e.g. browsing a trace according to the values reached by a specific mutable element

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 12/32

slide-40
SLIDE 40

Introduction Contribution Evaluation Conclusion

Overview

Multidimensional domain-specific trace metamodel generator Abstract Syntax xDSML Multidimensional Domain Specific Trace Metamodel imports merges Operational semantics

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 13/32

slide-41
SLIDE 41

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

1

Base classes – small step = standalone transformation rule – big step = rule relying

  • n other rules

2

Reification of rules into step classes

3

Steps made accessible as sequences or as a containment tree

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-42
SLIDE 42

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

1

Base classes – small step = standalone transformation rule – big step = rule relying

  • n other rules

2

Reification of rules into step classes

3

Steps made accessible as sequences or as a containment tree

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-43
SLIDE 43

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

1

Base classes – small step = standalone transformation rule – big step = rule relying

  • n other rules

2

Reification of rules into step classes

3

Steps made accessible as sequences or as a containment tree

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-44
SLIDE 44

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

Step classes are inferred by static analysis of the model transformation. 1 Analysis of the code 2 Creation of a call graph 3 Pre-processing of the call graph (e.g. methods

  • verriding)

4 Discovery of big/small steps

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-45
SLIDE 45

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

Step classes are inferred by static analysis of the model transformation. 1 Analysis of the code 2 Creation of a call graph 3 Pre-processing of the call graph (e.g. methods

  • verriding)

4 Discovery of big/small steps

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-46
SLIDE 46

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

1

Base classes – small step = standalone transformation rule – big step = rule relying

  • n other rules

2

Reification of rules into step classes

3

Steps made accessible as sequences or as a containment tree

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-47
SLIDE 47

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – Steps concepts

Petri net abstract syntax (partial)

Transition

+name: String

Net

Steps <<abstract>>

SmallStep

<<abstract>>

BigStep

<<abstract>>

Step

{ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

{ordered=true} fireSequence * {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

transitions *

1

Base classes – small step = standalone transformation rule – big step = rule relying

  • n other rules

2

Reification of rules into step classes

3

Steps made accessible as sequences or as a containment tree

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 14/32

slide-48
SLIDE 48

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – States concepts

merges Execution Metamodel

Place

+tokens: int Petri net abstract syntax

Place

+name: String +initialTokens: int input 1..*

  • utput

1..*

Transition

+name: String

Net

places * States

TokensValue

+tokens: int

  • riginalObject

1

TracedPlace

parent 1 {ordered=true} tokensSequence 0..*

ExecutionState

states 1..* tokensValues 0..* tracedPlaces * {ordered=true} executionStates 0..*

Trace

transitions *

1

Reification of mutable properies into value classes

2

Values stored as sequences , for each model object

3

Execution state = set of values

4

Can be browsed by states or value sequences

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 15/32

slide-49
SLIDE 49

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – States concepts

merges Execution Metamodel

Place

+tokens: int Petri net abstract syntax

Place

+name: String +initialTokens: int input 1..*

  • utput

1..*

Transition

+name: String

Net

places * States

TokensValue

+tokens: int

  • riginalObject

1

TracedPlace

parent 1 {ordered=true} tokensSequence 0..*

ExecutionState

states 1..* tokensValues 0..* tracedPlaces * {ordered=true} executionStates 0..*

Trace

transitions *

1

Reification of mutable properies into value classes

2

Values stored as sequences , for each model object

3

Execution state = set of values

4

Can be browsed by states or value sequences

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 15/32

slide-50
SLIDE 50

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – States concepts

merges Execution Metamodel

Place

+tokens: int Petri net abstract syntax

Place

+name: String +initialTokens: int input 1..*

  • utput

1..*

Transition

+name: String

Net

places * States

TokensValue

+tokens: int

  • riginalObject

1

TracedPlace

parent 1 {ordered=true} tokensSequence 0..*

ExecutionState

states 1..* tokensValues 0..* tracedPlaces * {ordered=true} executionStates 0..*

Trace

transitions *

1

Reification of mutable properies into value classes

2

Values stored as sequences , for each model object

3

Execution state = set of values

4

Can be browsed by states or value sequences

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 15/32

slide-51
SLIDE 51

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – States concepts

merges Execution Metamodel

Place

+tokens: int Petri net abstract syntax

Place

+name: String +initialTokens: int input 1..*

  • utput

1..*

Transition

+name: String

Net

places * States

TokensValue

+tokens: int

  • riginalObject

1

TracedPlace

parent 1 {ordered=true} tokensSequence 0..*

ExecutionState

states 1..* tokensValues 0..* tracedPlaces * {ordered=true} executionStates 0..*

Trace

transitions *

1

Reification of mutable properies into value classes

2

Values stored as sequences , for each model object

3

Execution state = set of values

4

Can be browsed by states or value sequences

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 15/32

slide-52
SLIDE 52

Introduction Contribution Evaluation Conclusion

Trace metamodel generation – States concepts

merges Execution Metamodel

Place

+tokens: int Petri net abstract syntax

Place

+name: String +initialTokens: int input 1..*

  • utput

1..*

Transition

+name: String

Net

places * States

TokensValue

+tokens: int

  • riginalObject

1

TracedPlace

parent 1 {ordered=true} tokensSequence 0..*

ExecutionState

states 1..* tokensValues 0..* tracedPlaces * {ordered=true} executionStates 0..*

Trace

transitions *

1

Reification of mutable properies into value classes

2

Values stored as sequences , for each model object

3

Execution state = set of values

4

Can be browsed by states or value sequences

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 15/32

slide-53
SLIDE 53

Introduction Contribution Evaluation Conclusion

Resulting Petri net trace metamodel

Petri net abstract syntax

Place

+name: String +initialTokens: int input 1..*

  • utput

1..*

Transition

+name: String

Net

places * transitions * Steps States

TokensValue

+tokens: int

  • riginalObject

1

TracedPlace

parent 1 {ordered=true} tokensSequence 0..*

ExecutionState

+() +() +() +() +() states 1..* tokensValues 0..* {ordered=true} startedSteps 0..* <<abstract>>

SmallStep

<<abstract>>

BigStep

startingState 1 <<abstract>>

Step

+() +() +() +() {ordered=true} endedSteps 0..* endingState 0..1 {ordered=true} /subSteps 0..* /parentStep 0..1 caller 1

FireStep

caller 1 {ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep

tracedPlaces * {ordered=true} fireSequence * {ordered=true} executionStates 0..* {ordered=true} runSequence * {ordered=true} rootSteps 0..*

Trace

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 16/32

slide-54
SLIDE 54

Introduction Contribution Evaluation Conclusion

Example of Petri net trace (states only)

p1 t1 p3 t2 p4 p2 p2 p1 t1 p3 t2 p4

(s0) (s1) (s2)

p1 t1 p3 t2 p4 p2

: Trace s1 : ExecutionState s2 : ExecutionState p1 : TracedPlace p2 : TracedPlace p3 : TracedPlace p4 : TracedPlace : TokensValue tokens = 1 : TokensValue tokens = 0 : TokensValue tokens = 0 : TokensValue tokens = 1 : TokensValue tokens = 0 : TokensValue tokens = 1 : TokensValue tokens = 0 tokens Trace tokens Trace tokens Trace executionState tokensValues executionState tokensValues executionState tokensValues tokens Trace exeTrace tracedPlaces : Place

  • name = "p3"
  • initialTokens = 0

: Place

  • name = "p4"
  • initialTokens = 0

: Place

  • name = "p2"
  • initialTokens = 1

: Place

  • name = "p1"
  • initialTokens = 1
  • riginalObject
  • riginalObject
  • riginalObject
  • riginalObject

: TokensValue tokens = 0 : TokensValue tokens = 1 s0 : ExecutionState

value

  • bject state

model state model element

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 17/32

slide-55
SLIDE 55

Introduction Contribution Evaluation Conclusion

Conclusion

Summary

Precise capture of the domain of the traces of an xDSML Multidimensional navigation facilities to ease queries

Questions

Usability and memory consumption improved with domain-specificness? Processing time reduced thanks to multidimensional navigation? ⇒ Application to two different V&V techniques + measurements

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 18/32

slide-56
SLIDE 56

Introduction Contribution Evaluation Conclusion

Outline

1 Introduction 2 Contribution 3 Evaluation 4 Conclusion

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

Enhanced semantic differencing Advanced and efficient

  • mniscient debugging [SLE’15]
slide-57
SLIDE 57

Introduction Contribution Evaluation Conclusion

Evaluation

Research questions (summarized)

As compared to a generic clone-based trace metamodel: RQ1: Usability of generated trace metamodels RQ2: Scalability in time of trace manipulations RQ3: Scalability in memory of traces

Considered V&V techniques

1 Semantic differencing

– Manually defined trace manipulations – Evaluation of RQ1 and RQ2

2 Omniscient debugging

– Generated trace manipulations – Evaluation of RQ2 and RQ3

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 19/32

slide-58
SLIDE 58

Introduction Contribution Evaluation Conclusion

Evaluation

Research questions (summarized)

As compared to a generic clone-based trace metamodel: RQ1: Usability of generated trace metamodels RQ2: Scalability in time of trace manipulations RQ3: Scalability in memory of traces

Considered V&V techniques

1 Semantic differencing

– Manually defined trace manipulations – Evaluation of RQ1 and RQ2

2 Omniscient debugging

– Generated trace manipulations – Evaluation of RQ2 and RQ3

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 19/32

slide-59
SLIDE 59

Introduction Contribution Evaluation Conclusion

Semantic model differencing

Context

Model differencing: analyzing and understanding the changes made to a model during its development Mostly done syntactically (e.g. version control systems)

The case of xDSMLs

A change in an executable model ≡ a change in its behavior Hence, model differencing must be done semantically One approach: traces comparison before and after a change.

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 20/32

slide-60
SLIDE 60

Introduction Contribution Evaluation Conclusion

Semantic model differencing

Context

Model differencing: analyzing and understanding the changes made to a model during its development Mostly done syntactically (e.g. version control systems)

The case of xDSMLs

A change in an executable model ≡ a change in its behavior Hence, model differencing must be done semantically One approach: traces comparison before and after a change.

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 20/32

slide-61
SLIDE 61

Introduction Contribution Evaluation Conclusion

Existing base approach [Langer et al.’14]

Abstract Syntax Clone-Based Generic Execution Trace Metamodel Model 1 Model 2 conform to Operational Semantics Syntactic Matching Syntactic correspondances Execution Trace 1 Execution Trace 2 Semantic Differencing Semantic differences merges uses 1 2 3 conform to Semantic Match Rules Input Syntactic Match Rules uses

RQ1 RQ2

Requires the manual definition of semantic match rules specific to the xDSML Relies on a generic trace metamodel

– usability (RQ1): match rules are hard to write – scalability in time (RQ2): match rules are long to execute

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 21/32

slide-62
SLIDE 62

Introduction Contribution Evaluation Conclusion

Enhanced approach

Multidimensional Domain-Specific Execution Trace Metamodel Generator (contribution) Abstract Syntax Model 1 Model 2 conform to Operational Semantics Syntactic Matching Syntactic correspondances Execution Trace 1 Execution Trace 2 Semantic Differencing Semantic differences merges uses 1 2 3 conform to Semantic Match Rules Input Syntactic Match Rules uses

RQ1 RQ2

Enhancement

Additional prior step: generation of a domain-specific trace metamodel with our contribution New semantic match rules relying on multiple dimensions What we measure:

– usability (RQ1): complexity of the match rules – scalability in time (RQ2): execution time of the match rules

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 22/32

slide-63
SLIDE 63

Introduction Contribution Evaluation Conclusion

Evaluation results

Case study: fUML xDSML and models from [Maoz et al.’11] Complexity of rules (RQ1)

Elements Generic Domain-specific Lines of code 90 44 Statements 35 16 Operations 8 3 Operation calls 35 24 Loops 5 4 Type checks 4 1 Conditionals 11 3

Rules execution time (RQ2)

400 450 500 550 600 650 700 750 800 1 10 100 1000 10000 100000 generic trace domain-specific trace

number of states matching time (ms) Lg 10^x

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 23/32

slide-64
SLIDE 64

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

slide-65
SLIDE 65

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

slide-66
SLIDE 66

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

slide-67
SLIDE 67

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(1) stepInto

slide-68
SLIDE 68

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(1) stepInto

slide-69
SLIDE 69

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(1) stepInto

slide-70
SLIDE 70

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(1) stepInto

slide-71
SLIDE 71

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(1) stepInto (3) backInto

slide-72
SLIDE 72

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(4) backOut (1) stepInto (3) backInto

slide-73
SLIDE 73

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

(4) backOut (1) stepInto (3) backInto

slide-74
SLIDE 74

Introduction Contribution Evaluation Conclusion

Model omniscient debugging: terminology and scope

Weak omniscient debugging (without any trace) Omniscient debugging (with a partial or complete trace) Multidimensional

  • mniscient debugging

Multidimensional exploration Backward exploration Interactive debugging Deterministic, without engine restart Forward exploration Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 24/32

slide-75
SLIDE 75

Introduction Contribution Evaluation Conclusion

Omniscient debugging for any xDSML?

Generic omniscient debugging possible, based on steps Two key problems: responsiveness and understandability when debugging models from arbitrarily complex xDSML

Approach

1 Efficient generated domain-specific trace management

facilities for responsiveness

– generated trace metamodel (using our contribution) – generated trace manipulations (e.g. “jump back”) – RQ2 and RQ3 can be evaluated

2 Advanced generic multidimensional omniscient

debugging services for understandability

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 25/32

slide-76
SLIDE 76

Introduction Contribution Evaluation Conclusion

Omniscient debugging for any xDSML?

Generic omniscient debugging possible, based on steps Two key problems: responsiveness and understandability when debugging models from arbitrarily complex xDSML

Approach

1 Efficient generated domain-specific trace management

facilities for responsiveness

– generated trace metamodel (using our contribution) – generated trace manipulations (e.g. “jump back”) – RQ2 and RQ3 can be evaluated

2 Advanced generic multidimensional omniscient

debugging services for understandability

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 25/32

slide-77
SLIDE 77

Introduction Contribution Evaluation Conclusion

Advanced omniscient debugging

New advanced debugging services to navigate according to the different dimensions of the model

run(net) p1 p3 p2 p4 p5 t1 t2 t3

A

Model States P1 Values P2 Values P3 Values P4 Values P5 Values

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 26/32

slide-78
SLIDE 78

Introduction Contribution Evaluation Conclusion

Advanced omniscient debugging

New advanced debugging services to navigate according to the different dimensions of the model

p1 p3 p2 p4 p5 t1 t2 t3

B

fire(t1) run(net) p1 p3 p2 p4 p5 t1 t2 t3

A

Model States P1 Values P2 Values P3 Values P4 Values P5 Values

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 26/32

slide-79
SLIDE 79

Introduction Contribution Evaluation Conclusion

Advanced omniscient debugging

New advanced debugging services to navigate according to the different dimensions of the model

p1 p3 p2 p4 p5 t1 t2 t3

B

fire(t1) fire(t2) run(net) p1 p3 p2 p4 p5 t1 t2 t3

A

p1 p3 p2 p4 p5 t1 t2 t3

C

Model States P1 Values P2 Values P3 Values P4 Values P5 Values

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 26/32

slide-80
SLIDE 80

Introduction Contribution Evaluation Conclusion

Advanced omniscient debugging

New advanced debugging services to navigate according to the different dimensions of the model

p1 p3 p2 p4 p5 t1 t2 t3

B

fire(t1) fire(t2) run(net) p1 p3 p2 p4 p5 t1 t2 t3

A

Model States P1 Values P2 Values P3 Values P4 Values P5 Values jump(A)

p1 p3 p2 p4 p5 t1 t2 t3

C Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 26/32

slide-81
SLIDE 81

Introduction Contribution Evaluation Conclusion

Advanced omniscient debugging

New advanced debugging services to navigate according to the different dimensions of the model

p1 p3 p2 p4 p5 t1 t2 t3

B

fire(t1) fire(t2) run(net) p1 p3 p2 p4 p5 t1 t2 t3

A

p1 p3 p2 p4 p5 t1 t2 t3

C

Model States P1 Values P2 Values P3 Values P4 Values P5 Values stepValue(p4.tokens) jump(A)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 26/32

slide-82
SLIDE 82

Introduction Contribution Evaluation Conclusion

Evaluation of responsiveness

Same case study: fUML models from [Maoz et al.’11] Comparison of our advanced debugger with two others: weak (no trace) and clone-based (generic trace) “Jump back” execution time (RQ2)

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 0.1 1 10 100

TIME (MS)

MultiDimDebugger CloneBasedDebugger WeakDebugger

MODEL ID

Memory consumption (RQ3)

200 400 600 800 55 60 65 70 75 80 85 90

  • MEM. USAGE (KB)

NUM STATES TRAVERSED MultiDimDebugger CloneBasedDebugger WeakDebugger Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 27/32

slide-83
SLIDE 83

Introduction Contribution Evaluation Conclusion

Note regarding evaluation of time

RQ2 (time) was evaluated in two different ways: Semantic differencing: the whole trace is read and compared Omniscient debugging: a single state is read to jump back Results are improved in both cases: Thanks to the dimensions when reading the whole trace Thanks to the precise capture of the execution concepts, when reading a single state

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 28/32

slide-84
SLIDE 84

Introduction Contribution Evaluation Conclusion

Outline

1 Introduction 2 Contribution 3 Evaluation 4 Conclusion

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-85
SLIDE 85

Introduction Contribution Evaluation Conclusion

Conclusion

How to provide efficient execution trace management facilities for any xDSML?

Contribution: new generative approach to manage execution traces of any xDSML Validation in a realistic context with applications to two existing V&V techniques using a real-world xDSML Results show that:

– RQ1: Reduces complexity of domain-specific manipulations – RQ2: Reduces processing time by 75% – RQ3: Reduces memory consumption by 75%

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 29/32

slide-86
SLIDE 86

Introduction Contribution Evaluation Conclusion

Short-term perspectives

Customization of generated trace metamodels to better fit expected trace manipulations, e.g. ignore unused parts of the metamodel Represent execution branches sharing a common prefix, within a single execution trace Domain-specific property language to define temporal properties over traces (cf. [Maoz et al.’14]) Domain-specific debugging services using the underlying domain-specific trace metamodel (cf. [Chi¸

s et al.’15])

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 30/32

slide-87
SLIDE 87

Introduction Contribution Evaluation Conclusion

Long-term perspectives

Execution traces as core modeling artifacts

“Live modeling”: instant visualization of the impact of a change in a model regarding its behavior Versionning of the behavior of models: “trace of traces”

Generating everything for an xDSML

Generating domain-specific mutation operators Generating a DSML to define test suites for an xDSML . . .

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 31/32

slide-88
SLIDE 88

Introduction Contribution Evaluation Conclusion

Publications

International conferences:

Model omniscient debugging:

  • E. Bousse, J. Corley, B. Combemale, J. Gray, and B. Baudry.

“Supporting Efficient and Advanced Omniscient Debugging for xDSMLs”. SLE 2015. Trace metamodel generation:

  • E. Bousse, T. Mayerhofer, B. Combemale, and B. Baudry. “A

Generative Approach to Define Rich Domain-Specific Trace Metamodels”. ECMFA 2015. Model cloning:

  • E. Bousse, B. Combemale, and B. Baudry. “Scalable Armies
  • f Model Clones through Data Sharing”. MODELS 2014.

+ 4 international workshops papers

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 32/32

slide-89
SLIDE 89

Appendix

Appendix

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs 33/32

slide-90
SLIDE 90

Appendix

Outline

5 Appendix

Evaluation

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-91
SLIDE 91

Appendix

Types of semantics (I)

a_exe (1) a_exe (2) a_exe (3) A step A step a initialization Execution metamodel

  • f A

Abstract syntax

  • f A

conforms to all conform to

Figure: Operational semantics

b_exe (1) b_exe (2) b_exe (3) B step B step b initialization Execution metamodel

  • f B

Abstract syntax

  • f B

conforms to all conform to a Abstract syntax

  • f A

conforms to A to B transf.

Figure: Translational semantics

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-92
SLIDE 92

Appendix

Types of semantics (II)

a_exe (1) a_exe (2) a_exe (3) A step (indirect) A step (indirect) B to A transf. B to A transf. Execution metamodel

  • f A

b_exe (1) b_exe (i) b_exe (i+n) b_exe (2) a A to B transf. B step B steps Execution metamodel

  • f B

Abstract syntax

  • f A

all conform to conforms to ... b_exe (i+1) B step B steps ... Abstract syntax

  • f B

b conforms to initialization B to A transf. all conform to

Figure: Translational semantics with back-annotation

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-93
SLIDE 93

Appendix

Implicit steps

Figure: Implicit step illustration

<<abstract>>

SmallStep

<<abstract>>

BigStep FireStep

{ordered=true} subSteps 0..* runParentStep 0..1 <<abstract>>

RunSubStep RunStep RunImplicitStep

Figure: Petri net implicit step class

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-94
SLIDE 94

Appendix

State of the art (summary)

Trace data structures Domain-specific structure definition approaches Generative [Meyers et al.’14] Manual [Heged¨ us et al.’10] Domain-specific structures . . . fUML [Mayerhofer et al.’12] Parallel soft. [Eschweiler et al.’11] OO Software [Hamou-Lhadj et al.’10] Generic structures Clone-based [Langer et al.’14] Versioning [Hartmann et al.’14]

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-95
SLIDE 95

Appendix

State of the art (table)

Figure: Execution trace data structures

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-96
SLIDE 96

Appendix

Screenshot GEMOC debugger (during execution)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-97
SLIDE 97

Appendix

Screenshot GEMOC debugger (after jump back)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-98
SLIDE 98

Appendix

fUML case study

fUML xDSML

subset of UML 57 classes

fUML Models

Case study of Maoz et al. to evaluate a semantic differencing

  • perator

Models drawn from industrial sources Multiple sequences of models, each sequence with a change 40 models considered, sizes range from 36 to 51 objects Source: http://www.se-rwth.de/materials/semdiff/

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-99
SLIDE 99

Appendix

Omniscient debugger architecture

Depends on / Uses Conforms to Produces Modifies

Execution Metamodel Operational Semantics xDSML Generators DS Trace Metamodel (generated) DS Trace Manager (generated) Trace Constructor State Manager Generic Trace Metamodel Interface Execution Engine Executable Model Domain- specific (DS) Execution Trace Generic Multidim. Omniscient Debugger

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-100
SLIDE 100

Appendix

Example: a metamodel, a model, and runtime counterparts

:B x = 5 :B x = 7 :A i = 1 j = 2

  • b

* Example of system instance of instance of instance of conforms to b * Metamodel "AB" Model "abb" Runtime representation implements :BImpl x = 5 :BImpl x = 7 :AImpl i = 1 j = 2

A

+i: int +(mut) j: int

B

+x: int representation of <<interface>>

A

+getB(): List<B> +getI(): int +setI(int) +getJ(): int +setJ(int)

AImpl

+i: int +j: int <<interface>>

B

+getX(): int +setX(int)

BImpl

+x: int API

Modeling framework code generation e.g. EMF

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-101
SLIDE 101

Appendix

Example: a model clone obtained using deep cloning

Metamodel "AB" Model "abb" conforms to conforms to cloned from Model "abb_clone" representation of representation of :B x = 5 :B x = 7 :A i = 1 j = 2 :B x = 5 :B x = 7 :A i = 1 j = 5 :BImpl x = 5 :BImpl x = 7 :AImpl i = 1 j = 5 :BImpl x = 5 :BImpl x = 7 :AImpl i = 1 j = 2 Runtime representation of "abb" Runtime representation of "abb_clone" API System Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-102
SLIDE 102

Appendix

Data sharing: existing approaches

Idea for Req #1: considering that only a subset of a model changes during its lifecycle, avoid data redundancy among clones

Dynamically: copy-on-write (aka lazy copy)

Create virtual copies, and create real copies on write accesses. either using a specific API/entry-point, breaks Req#3

  • r in a transparent way, but managing consistency depends on the

implementation language (e.g. Java is pass-by-value) Copies are done during manipulations, may break Req#2

Statically: flyweight design pattern

Objects are designed to be used in multiple contexts. Requires the passing the extrinsic state (ie the mutable part) of the

  • bject as a parameter, for all its operations, breaks Req #3

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-103
SLIDE 103

Appendix

Approach: static identification of safely shareable parts

Operations Metamodel Mutable elements (runtime data, parts to optimize, etc.) Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-104
SLIDE 104

Appendix

Approach: static identification of safely shareable parts

Operations Metamodel Mutable elements (runtime data, parts to optimize, etc.) Metamodel with shareable elements tagged Shareable elements identification of shareable elements Sharing strategy Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-105
SLIDE 105

Appendix

Approach: static identification of safely shareable parts

Operations Metamodel Mutable elements (runtime data, parts to optimize, etc.) Metamodel with shareable elements tagged Shareable elements identification of shareable elements cloning while safely sharing shareable data Shared data (based on shareable elements of the MM) Runtime repr.

  • f a model

Runtime repr.

  • f a clone

In memory Sharing strategy Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-106
SLIDE 106

Appendix

Shareable elements and sharing mechanisms

b * Metamodel "AB"

A

+i: int +(mut) j: int

B

+x: int :AImpl i = 1 j (mut) =2 :AProxy j (mut) =5

  • rigin

Field sharing using a partial proxy (i considered shareable)

:BImpl x = 5 :AImpl :AImpl

Object sharing (B considered shareable)

Req #2 (efficiency) is not satisfied when sharing fields Req #4 (reflective layer) is not satisfied when sharing objects, since it breaks MOF container() operation

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-107
SLIDE 107

Appendix

Data sharing strategies

For design-time, 3 sharing strategies with trade-offs between memory use and satisfaction of Req #2 and Req #4 DeepCloning Nothing is shareable. ShareFieldsOnly Only immutable attributes are shareable. ShareObjOnly Classes that can’t (transitively) access mutable parts are shareable. ShareAll Shareable elements are immutable attributes, classes whose properties are all shareable, and immutable references pointing to shareable classes. For runtime, 1 generic algorithm parameterized by a sharing strategy → 3 data sharing cloning operators.

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-108
SLIDE 108

Appendix

Data sharing strategies: example

C

+c1 (mut): int +c2: boolean

D

+d1: int

E

+e1: int +e2: int d e

F

f

G

+g1: int g

H

h someF (mut)

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-109
SLIDE 109

Appendix

Data sharing strategies: example

C

+c1 (mut): int +c2: boolean

D

+d1: int

E

+e1: int +e2: int d e

F

f

G

+g1: int g

H

h someF (mut) ShareFieldsOnly

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-110
SLIDE 110

Appendix

Data sharing strategies: example

C

+c1 (mut): int +c2: boolean

D

+d1: int

E

+e1: int +e2: int d e

F

f

G

+g1: int g

H

h someF (mut) ShareFieldsOnly ShareObjOnly

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-111
SLIDE 111

Appendix

Data sharing strategies: example

C

+c1 (mut): int +c2: boolean

D

+d1: int

E

+e1: int +e2: int d e

F

f

G

+g1: int g

H

h someF (mut) ShareFieldsOnly ShareObjOnly ShareAll

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-112
SLIDE 112

Appendix

Resulting cloning operators

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-113
SLIDE 113

Appendix

Research questions

RQ#1

Do the new operators reduce the memory footprint of clones, compared to deep cloning?

RQ#2

Can a clone be manip. with the same efficiency as the original ?

RQ#3

Can a clone be manip. using the same generated API ?

RQ#4

Can a clone be manip. using the reflective layer (e.g. as stated in the MOF Reflection package)?

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-114
SLIDE 114

Appendix

Evaluation – RQ#1 and RQ#2

Experiment

data set: 100 randomly generated metamodels memory measures: gain as compared to deep cloning, after cloning the model 1000 times performance measures: loss of time as compared to the

  • riginal model, when navigating 10 000 times through each
  • bject of the model while accessing all properties

Results

memory: the more shareable parts, the more memory gain performance: worst median overhead is 9,5% when manipulating clones with fields sharing

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs

slide-115
SLIDE 115

Appendix

Evaluation – results overview

RQ1: memory RQ2: efficiency RQ3: same API RQ4: reflective layer RQ1 RQ2 RQ3 RQ4 DeepCloning ✪ ✦ ✦ ✦ ShareFieldsOnly +

  • -

✦ ✦ ShareObjOnly ++ ✦ ✦ ✪ ShareAll +++

Erwan Bousse Trace Management for Dynamic V&V for xDSMLs