lyra.engine package

Submodules

Backward Analysis Engine

Author:Caterina Urban
class lyra.engine.backward.BackwardInterpreter(cfg, semantics: lyra.semantics.backward.BackwardSemantics, widening, precursory=None)[source]

Bases: lyra.engine.interpreter.Interpreter

Backward control flow graph interpreter.

analyze(initial: lyra.abstract_domains.state.State) → lyra.engine.result.AnalysisResult[source]
semantics

Forward Analysis Engine

Author:Caterina Urban
class lyra.engine.forward.ForwardInterpreter(cfg, semantics: lyra.semantics.forward.ForwardSemantics, widening, precursory=None)[source]

Bases: lyra.engine.interpreter.Interpreter

Forward control flow graph interpreter.

analyze(initial: lyra.abstract_domains.state.State) → lyra.engine.result.AnalysisResult[source]

Analysis Engine

Author:Caterina Urban
class lyra.engine.interpreter.Interpreter(cfg: lyra.core.cfg.ControlFlowGraph, semantics, widening, precursory=None)[source]

Bases: object

analyze(initial: lyra.abstract_domains.state.State) → lyra.engine.result.AnalysisResult[source]

Run the analysis.

Parameters:initial – initial analysis state
Returns:result of the analysis
cfg
precursory
result
semantics
widening
class lyra.engine.result.AnalysisResult(cfg: lyra.core.cfg.ControlFlowGraph)[source]

Bases: object

cfg
get_node_result(node: lyra.core.cfg.Node) → typing.List[lyra.abstract_domains.state.State][source]

Get the analysis result for a node.

Parameters:node – analyzed node
Returns:list of states representing the result of the analysis for the block
result
set_node_result(node: lyra.core.cfg.Node, states: typing.List[lyra.abstract_domains.state.State]) → None[source]

Set the analysis result for a node.

Parameters:
  • node – analyzed node
  • states – list of states representing the result of the analysis for the block

Program Analysis

Author:Caterina Urban
class lyra.engine.runner.Runner[source]

Bases: object

Analysis runner.

cfg
interpreter()[source]

Control flow graph interpreter.

main(path)[source]
path
render(result)[source]
run() → lyra.engine.result.AnalysisResult[source]
source
state()[source]

Initial analysis state.

tree
variables