SlideShare a Scribd company logo
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Execution as DPLL Modulo Theories 
Q. Sang Phan 
Queen Mary, University of London 
September 25, 2014 
1 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Outline 
1 Introduction 
2 Background 
3 Symbolic Execution as DPLL(T ) 
4 A lightweight approach for Symbolic Execution 
5 Conclusion 
2 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Outline 
1 Introduction 
2 Background 
3 Symbolic Execution as DPLL(T ) 
4 A lightweight approach for Symbolic Execution 
5 Conclusion 
3 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Execution 
A program analysis technique that has several applications, in particular 
automated test generation. 
Executing programs with symbols instead of concrete inputs. 
4 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Execution 
Academic: 
Imperial: KLEE 
EPFL: S2E 
UC Berkeley: CREST and BitBlaze 
UIUC: Cute, jCute 
. . . 
Industry: 
NASA: Symbolic PathFinder 
Microsoft: Pex, Sage, Yogi 
IBM: Apollo 
. . . 
5 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Satis
ability Modulo Theories 
Decision problem for logical formulas over one or more
rst-order theories 
'  (:(x0  5) _ T1) ^ ((x0  5) _ T2) ^ (:(x0  5) _ (x1 = x0 + 1)) ^ 
(:(x1  3) _ T3) ^ (:(x1  3) _ (x2 = x1  1)) ^ 
((x1  3) _ T4) ^ ((x1  3) _ (y1 = x1 + 1)) 
6 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Satis
ability Modulo Theories 
Decision problem for logical formulas over one or more
rst-order theories 
'  (:(x0  5) _ T1) ^ ((x0  5) _ T2) ^ (:(x0  5) _ (x1 = x0 + 1)) ^ 
(:(x1  3) _ T3) ^ (:(x1  3) _ (x2 = x1  1)) ^ 
((x1  3) _ T4) ^ ((x1  3) _ (y1 = x1 + 1)) 
Tools: 
Microsoft: Z3 
NYU: CVC3 
SRI: Yices 
. . . 
SMT competition: http://www.smtcomp.org/ 
6 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Execution as an SMT solver 
Symbolic Execution can be viewed as an SMT solver 
7 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Outline 
1 Introduction 
2 Background 
3 Symbolic Execution as DPLL(T ) 
4 A lightweight approach for Symbolic Execution 
5 Conclusion 
8 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
DPLL Modulo Theories 
The lazy approach for SMT 
SMT solver = SAT solver + T -solver 
SAT solver: implement DPLL algorithm 
T -solver: check satis
ability of conjunctions of literals 
9 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
DPLL Modulo Theories 
The lazy approach for SMT 
SMT solver = SAT solver + T -solver 
SAT solver: implement DPLL algorithm 
T -solver: check satis
ability of conjunctions of literals 
DPLL-based SAT solver: a depth-
rst search procedure, using three main operations: 
decide: choose a literal l from the formula. 
propagate: remove all the clauses containing l , and deletes all occurrences of :l 
in the formula. 
backtrack: if encounter a con
ict. 
9 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Boolean Abstraction 
'  (:(x0  5) _ T1) ^ ((x0  5) _ T2) ^ (:(x0  5) _ (x1 = x0 + 1)) ^ 
(:(x1  3) _ T3) ^ (:(x1  3) _ (x2 = x1  1)) ^ 
((x1  3) _ T4) ^ ((x1  3) _ (y1 = x1 + 1)) 
(x0  5), (x1 = x0 + 1), . . . : T -atoms 
T1;T2; : : : : Boolean atoms 
10 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Boolean Abstraction 
'  (:(x0  5) _ T1) ^ ((x0  5) _ T2) ^ (:(x0  5) _ (x1 = x0 + 1)) ^ 
(:(x1  3) _ T3) ^ (:(x1  3) _ (x2 = x1  1)) ^ 
((x1  3) _ T4) ^ ((x1  3) _ (y1 = x1 + 1)) 
(x0  5), (x1 = x0 + 1), . . . : T -atoms 
T1;T2; : : : : Boolean atoms 
Boolean abstraction of ': 
'P  (:G1 _ T1) ^ (G1 _ T2) ^ (:G1 _ A1) ^ 
(:G2 _ T3) ^ (:G2 _ A2) ^ 
(G2 _ T4) ^ (G2 _ A3) 
10 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
DPLL-based SAT solver 
'P  (:G1 _ T1) ^ (G1 _ T2) ^ (:G1 _ A1) ^ 
(:G2 _ T3) ^ (:G2 _ A2) ^ 
(G2 _ T4) ^ (G2 _ A3) 
0. P = True 'P 
1. P = G1 'P = (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 
2. P = G1 ^ G2 'P = True ; T -solver() = Inconsistent 
3. P = G1 'P = (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 
4. P = G1 ^ :G2 'P = True ; T -solver() = Consistent 
11 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Execution 
pc ` c : execute the then path 
pc ` :c : execute the else path 
(pc 0 c) ^ (pc 0 :c): execute both paths 
then path: update pc1 = pc ^ c 
else path: update pc2 = pc ^ :c 
Use SMT solver to check satis
ability of path 
conditions 
12 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Execution 
pc ` c : execute the then path 
pc ` :c : execute the else path 
(pc 0 c) ^ (pc 0 :c): execute both paths 
then path: update pc1 = pc ^ c 
else path: update pc2 = pc ^ :c 
Use SMT solver to check satis
ability of path 
conditions 
Observation 
SMT solver is used to solve conjunctions of literals ) the SAT solver is not used 
12 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Implementation of Symbolic Execution 
Symbolic Executor = Boolean Executor + T -solver 
Boolean Executor: A depth-
rst search procedure, using three main operations: 
decide: choose a literal from the condition. 
update: execute block of code on that path. 
backtrack: if reach the leaf of the symbolic execution tree. 
13 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Outline 
1 Introduction 
2 Background 
3 Symbolic Execution as DPLL(T ) 
4 A lightweight approach for Symbolic Execution 
5 Conclusion 
14 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Symbolic Transition System 
A bounded Static Single Assignment program: 
P  (S; I ; G;A;T) 
S: the set of symbolic states 
I  S : the set of initial symbolic states 
G : the set of guards 
A : the set of action 
Actions do not update computer memory: presented by Boolean atoms. 
Actions update computer memory: presented by T -atoms. 
T  S  G  A  S: the transition function 
15 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Program to formula 
tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij 
16 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Program to formula 
tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij 
Encode the transition into a formula: 
tij  gij ! aij or equally tij  :gij _ aij 
16 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Program to formula 
tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij 
Encode the transition into a formula: 
tij  gij ! aij or equally tij  :gij _ aij 
A program trace: 
t01 ^ t12 ^    ^ t(k1)k = (:g01 _ a01) ^ (:g12 _ a12)    ^ (:g(k1)k _ a(k1)k ) 
16 / 25
Introduction 
Background 
Symbolic Execution as DPLL(T ) 
A lightweight approach for Symbolic Execution 
Conclusion 
Program to formula 
tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij 
Encode the transition into a formula: 
tij  gij ! aij or equally tij  :gij _ aij 
A program trace: 
t01 ^ t12 ^    ^ t(k1)k = (:g01 _ a01) ^ (:g12 _ a12)    ^ (:g(k1)k _ a(k1)k ) 
Program semantics: all possible traces 
' = 
^ 
tij2T 
tij = 
^ 
tij2T 
(:gij _ aij ) 
16 / 25

More Related Content

What's hot

Design and Analysis of Algorithms
Design and Analysis of AlgorithmsDesign and Analysis of Algorithms
Design and Analysis of Algorithms
Swapnil Agrawal
 
Dynamic Programming - Part II
Dynamic Programming - Part IIDynamic Programming - Part II
Dynamic Programming - Part II
Amrinder Arora
 
Lecture 5: Asymptotic analysis of algorithms
Lecture 5: Asymptotic analysis of algorithmsLecture 5: Asymptotic analysis of algorithms
Lecture 5: Asymptotic analysis of algorithms
Vivek Bhargav
 
Analysis and design of algorithms part 4
Analysis and design of algorithms part 4Analysis and design of algorithms part 4
Analysis and design of algorithms part 4
Deepak John
 
Dynamic Programming - Part 1
Dynamic Programming - Part 1Dynamic Programming - Part 1
Dynamic Programming - Part 1
Amrinder Arora
 
Algorithm And analysis Lecture 03& 04-time complexity.
 Algorithm And analysis Lecture 03& 04-time complexity. Algorithm And analysis Lecture 03& 04-time complexity.
Algorithm And analysis Lecture 03& 04-time complexity.
Tariq Khan
 
A calculus of mobile Real-Time processes
A calculus of mobile Real-Time processesA calculus of mobile Real-Time processes
A calculus of mobile Real-Time processes
Polytechnique Montréal
 
how to calclute time complexity of algortihm
how to calclute time complexity of algortihmhow to calclute time complexity of algortihm
how to calclute time complexity of algortihmSajid Marwat
 
Asymptotic Notation and Complexity
Asymptotic Notation and ComplexityAsymptotic Notation and Complexity
Asymptotic Notation and Complexity
Rajandeep Gill
 
2010 3-24 cryptography stamatiou
2010 3-24 cryptography stamatiou2010 3-24 cryptography stamatiou
2010 3-24 cryptography stamatiouvafopoulos
 
Time and space complexity
Time and space complexityTime and space complexity
Time and space complexityAnkit Katiyar
 
Time andspacecomplexity
Time andspacecomplexityTime andspacecomplexity
Time andspacecomplexity
LAKSHMITHARUN PONNAM
 
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
sohelranasweet
 
Basic terminologies & asymptotic notations
Basic terminologies & asymptotic notationsBasic terminologies & asymptotic notations
Basic terminologies & asymptotic notations
Rajendran
 
Design & Analysis Of Algorithm
Design & Analysis Of AlgorithmDesign & Analysis Of Algorithm
Design & Analysis Of Algorithm
Computer Hardware & Trouble shooting
 
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
Protap Mondal
 

What's hot (19)

Design and Analysis of Algorithms
Design and Analysis of AlgorithmsDesign and Analysis of Algorithms
Design and Analysis of Algorithms
 
Dynamic Programming - Part II
Dynamic Programming - Part IIDynamic Programming - Part II
Dynamic Programming - Part II
 
Lecture 5: Asymptotic analysis of algorithms
Lecture 5: Asymptotic analysis of algorithmsLecture 5: Asymptotic analysis of algorithms
Lecture 5: Asymptotic analysis of algorithms
 
Analysis and design of algorithms part 4
Analysis and design of algorithms part 4Analysis and design of algorithms part 4
Analysis and design of algorithms part 4
 
Dynamic Programming - Part 1
Dynamic Programming - Part 1Dynamic Programming - Part 1
Dynamic Programming - Part 1
 
Lecture26
Lecture26Lecture26
Lecture26
 
Algorithm And analysis Lecture 03& 04-time complexity.
 Algorithm And analysis Lecture 03& 04-time complexity. Algorithm And analysis Lecture 03& 04-time complexity.
Algorithm And analysis Lecture 03& 04-time complexity.
 
A calculus of mobile Real-Time processes
A calculus of mobile Real-Time processesA calculus of mobile Real-Time processes
A calculus of mobile Real-Time processes
 
how to calclute time complexity of algortihm
how to calclute time complexity of algortihmhow to calclute time complexity of algortihm
how to calclute time complexity of algortihm
 
Asymptotic Notation and Complexity
Asymptotic Notation and ComplexityAsymptotic Notation and Complexity
Asymptotic Notation and Complexity
 
2010 3-24 cryptography stamatiou
2010 3-24 cryptography stamatiou2010 3-24 cryptography stamatiou
2010 3-24 cryptography stamatiou
 
Lecture 1
Lecture 1Lecture 1
Lecture 1
 
Time and space complexity
Time and space complexityTime and space complexity
Time and space complexity
 
Dsp manual
Dsp manualDsp manual
Dsp manual
 
Time andspacecomplexity
Time andspacecomplexityTime andspacecomplexity
Time andspacecomplexity
 
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
 
Basic terminologies & asymptotic notations
Basic terminologies & asymptotic notationsBasic terminologies & asymptotic notations
Basic terminologies & asymptotic notations
 
Design & Analysis Of Algorithm
Design & Analysis Of AlgorithmDesign & Analysis Of Algorithm
Design & Analysis Of Algorithm
 
Asymptotic Notation
Asymptotic NotationAsymptotic Notation
Asymptotic Notation
 

Similar to Symbolic Execution as DPLL Modulo Theories

Towards an SMT-based approach for Quantitative Information Flow
Towards an SMT-based approach for Quantitative Information FlowTowards an SMT-based approach for Quantitative Information Flow
Towards an SMT-based approach for Quantitative Information Flow
Quoc-Sang Phan
 
Queuing theory is a branch of mathematics that studies the behavior of waitin...
Queuing theory is a branch of mathematics that studies the behavior of waitin...Queuing theory is a branch of mathematics that studies the behavior of waitin...
Queuing theory is a branch of mathematics that studies the behavior of waitin...
Sonam704174
 
01 - DAA - PPT.pptx
01 - DAA - PPT.pptx01 - DAA - PPT.pptx
01 - DAA - PPT.pptx
KokilaK25
 
Introduction to Polyhedral Compilation
Introduction to Polyhedral CompilationIntroduction to Polyhedral Compilation
Introduction to Polyhedral Compilation
Akihiro Hayashi
 
5_2019_01_12!09_25_57_AM.ppt
5_2019_01_12!09_25_57_AM.ppt5_2019_01_12!09_25_57_AM.ppt
5_2019_01_12!09_25_57_AM.ppt
aboma2hawi
 
Quantifying Information Leaks via Model Counting Modulo Theories
Quantifying Information Leaks via Model Counting Modulo TheoriesQuantifying Information Leaks via Model Counting Modulo Theories
Quantifying Information Leaks via Model Counting Modulo Theories
Quoc-Sang Phan
 
Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...
Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...
Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...
Michael Lie
 
Deep Learning, Scala, and Spark
Deep Learning, Scala, and SparkDeep Learning, Scala, and Spark
Deep Learning, Scala, and Spark
Oswald Campesato
 
Modelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptx
Modelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptxModelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptx
Modelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptx
KadiriIbrahim2
 
matlab_simulink_for_control082p.pdf
matlab_simulink_for_control082p.pdfmatlab_simulink_for_control082p.pdf
matlab_simulink_for_control082p.pdf
MUHAMMAD FAISAL RASHEED
 
analysis.ppt
analysis.pptanalysis.ppt
analysis.ppt
AarushSharma69
 
Injecting image priors into Learnable Compressive Subsampling
Injecting image priors into Learnable Compressive SubsamplingInjecting image priors into Learnable Compressive Subsampling
Injecting image priors into Learnable Compressive Subsampling
Martino Ferrari
 
smtlecture.5
smtlecture.5smtlecture.5
smtlecture.5
Roberto Bruttomesso
 
Subtle Asynchrony by Jeff Hammond
Subtle Asynchrony by Jeff HammondSubtle Asynchrony by Jeff Hammond
Subtle Asynchrony by Jeff Hammond
Patrick Diehl
 
Time complexity.ppt
Time complexity.pptTime complexity.ppt
Time complexity.ppt
YekoyeTigabuYeko
 
Data Structure: Algorithm and analysis
Data Structure: Algorithm and analysisData Structure: Algorithm and analysis
Data Structure: Algorithm and analysis
Dr. Rajdeep Chatterjee
 

Similar to Symbolic Execution as DPLL Modulo Theories (20)

Towards an SMT-based approach for Quantitative Information Flow
Towards an SMT-based approach for Quantitative Information FlowTowards an SMT-based approach for Quantitative Information Flow
Towards an SMT-based approach for Quantitative Information Flow
 
Queuing theory is a branch of mathematics that studies the behavior of waitin...
Queuing theory is a branch of mathematics that studies the behavior of waitin...Queuing theory is a branch of mathematics that studies the behavior of waitin...
Queuing theory is a branch of mathematics that studies the behavior of waitin...
 
01 - DAA - PPT.pptx
01 - DAA - PPT.pptx01 - DAA - PPT.pptx
01 - DAA - PPT.pptx
 
Introduction to Polyhedral Compilation
Introduction to Polyhedral CompilationIntroduction to Polyhedral Compilation
Introduction to Polyhedral Compilation
 
5_2019_01_12!09_25_57_AM.ppt
5_2019_01_12!09_25_57_AM.ppt5_2019_01_12!09_25_57_AM.ppt
5_2019_01_12!09_25_57_AM.ppt
 
Quantifying Information Leaks via Model Counting Modulo Theories
Quantifying Information Leaks via Model Counting Modulo TheoriesQuantifying Information Leaks via Model Counting Modulo Theories
Quantifying Information Leaks via Model Counting Modulo Theories
 
R Language Introduction
R Language IntroductionR Language Introduction
R Language Introduction
 
Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...
Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...
Time-Series Analysis on Multiperiodic Conditional Correlation by Sparse Covar...
 
Deep Learning, Scala, and Spark
Deep Learning, Scala, and SparkDeep Learning, Scala, and Spark
Deep Learning, Scala, and Spark
 
Modelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptx
Modelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptxModelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptx
Modelling using differnt metods in matlab2 (2) (2) (2) (4) (1) (1).pptx
 
matlab_simulink_for_control082p.pdf
matlab_simulink_for_control082p.pdfmatlab_simulink_for_control082p.pdf
matlab_simulink_for_control082p.pdf
 
analysis.ppt
analysis.pptanalysis.ppt
analysis.ppt
 
Injecting image priors into Learnable Compressive Subsampling
Injecting image priors into Learnable Compressive SubsamplingInjecting image priors into Learnable Compressive Subsampling
Injecting image priors into Learnable Compressive Subsampling
 
smtlecture.5
smtlecture.5smtlecture.5
smtlecture.5
 
MSc_thesis
MSc_thesisMSc_thesis
MSc_thesis
 
Subtle Asynchrony by Jeff Hammond
Subtle Asynchrony by Jeff HammondSubtle Asynchrony by Jeff Hammond
Subtle Asynchrony by Jeff Hammond
 
Time complexity.ppt
Time complexity.pptTime complexity.ppt
Time complexity.ppt
 
Data Structure: Algorithm and analysis
Data Structure: Algorithm and analysisData Structure: Algorithm and analysis
Data Structure: Algorithm and analysis
 
discrete-hmm
discrete-hmmdiscrete-hmm
discrete-hmm
 
residue
residueresidue
residue
 

More from Quoc-Sang Phan

Model-counting Approaches For Nonlinear Numerical Constraints
Model-counting Approaches For Nonlinear Numerical ConstraintsModel-counting Approaches For Nonlinear Numerical Constraints
Model-counting Approaches For Nonlinear Numerical Constraints
Quoc-Sang Phan
 
All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...
All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...
All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...
Quoc-Sang Phan
 
Concurrent Bounded Model Checking
Concurrent Bounded Model CheckingConcurrent Bounded Model Checking
Concurrent Bounded Model CheckingQuoc-Sang Phan
 
Quantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability AnalysisQuantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability AnalysisQuoc-Sang Phan
 
Quantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability AnalysisQuantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability Analysis
Quoc-Sang Phan
 
Self-composition by Symbolic Execution
Self-composition by Symbolic ExecutionSelf-composition by Symbolic Execution
Self-composition by Symbolic Execution
Quoc-Sang Phan
 
Symbolic Quantitative Information Flow
Symbolic Quantitative Information FlowSymbolic Quantitative Information Flow
Symbolic Quantitative Information Flow
Quoc-Sang Phan
 

More from Quoc-Sang Phan (7)

Model-counting Approaches For Nonlinear Numerical Constraints
Model-counting Approaches For Nonlinear Numerical ConstraintsModel-counting Approaches For Nonlinear Numerical Constraints
Model-counting Approaches For Nonlinear Numerical Constraints
 
All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...
All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...
All-Solution Satisfiability Modulo Theories: applications, algorithms and ben...
 
Concurrent Bounded Model Checking
Concurrent Bounded Model CheckingConcurrent Bounded Model Checking
Concurrent Bounded Model Checking
 
Quantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability AnalysisQuantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability Analysis
 
Quantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability AnalysisQuantifying Information Leaks using Reliability Analysis
Quantifying Information Leaks using Reliability Analysis
 
Self-composition by Symbolic Execution
Self-composition by Symbolic ExecutionSelf-composition by Symbolic Execution
Self-composition by Symbolic Execution
 
Symbolic Quantitative Information Flow
Symbolic Quantitative Information FlowSymbolic Quantitative Information Flow
Symbolic Quantitative Information Flow
 

Recently uploaded

Lateral Ventricles.pdf very easy good diagrams comprehensive
Lateral Ventricles.pdf very easy good diagrams comprehensiveLateral Ventricles.pdf very easy good diagrams comprehensive
Lateral Ventricles.pdf very easy good diagrams comprehensive
silvermistyshot
 
general properties of oerganologametal.ppt
general properties of oerganologametal.pptgeneral properties of oerganologametal.ppt
general properties of oerganologametal.ppt
IqrimaNabilatulhusni
 
platelets- lifespan -Clot retraction-disorders.pptx
platelets- lifespan -Clot retraction-disorders.pptxplatelets- lifespan -Clot retraction-disorders.pptx
platelets- lifespan -Clot retraction-disorders.pptx
muralinath2
 
erythropoiesis-I_mechanism& clinical significance.pptx
erythropoiesis-I_mechanism& clinical significance.pptxerythropoiesis-I_mechanism& clinical significance.pptx
erythropoiesis-I_mechanism& clinical significance.pptx
muralinath2
 
Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...
Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...
Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...
muralinath2
 
Body fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptx
Body fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptxBody fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptx
Body fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptx
muralinath2
 
In silico drugs analogue design: novobiocin analogues.pptx
In silico drugs analogue design: novobiocin analogues.pptxIn silico drugs analogue design: novobiocin analogues.pptx
In silico drugs analogue design: novobiocin analogues.pptx
AlaminAfendy1
 
Structures and textures of metamorphic rocks
Structures and textures of metamorphic rocksStructures and textures of metamorphic rocks
Structures and textures of metamorphic rocks
kumarmathi863
 
Cancer cell metabolism: special Reference to Lactate Pathway
Cancer cell metabolism: special Reference to Lactate PathwayCancer cell metabolism: special Reference to Lactate Pathway
Cancer cell metabolism: special Reference to Lactate Pathway
AADYARAJPANDEY1
 
Unveiling the Energy Potential of Marshmallow Deposits.pdf
Unveiling the Energy Potential of Marshmallow Deposits.pdfUnveiling the Energy Potential of Marshmallow Deposits.pdf
Unveiling the Energy Potential of Marshmallow Deposits.pdf
Erdal Coalmaker
 
Comparative structure of adrenal gland in vertebrates
Comparative structure of adrenal gland in vertebratesComparative structure of adrenal gland in vertebrates
Comparative structure of adrenal gland in vertebrates
sachin783648
 
EY - Supply Chain Services 2018_template.pptx
EY - Supply Chain Services 2018_template.pptxEY - Supply Chain Services 2018_template.pptx
EY - Supply Chain Services 2018_template.pptx
AlguinaldoKong
 
filosofia boliviana introducción jsjdjd.pptx
filosofia boliviana introducción jsjdjd.pptxfilosofia boliviana introducción jsjdjd.pptx
filosofia boliviana introducción jsjdjd.pptx
IvanMallco1
 
extra-chromosomal-inheritance[1].pptx.pdfpdf
extra-chromosomal-inheritance[1].pptx.pdfpdfextra-chromosomal-inheritance[1].pptx.pdfpdf
extra-chromosomal-inheritance[1].pptx.pdfpdf
DiyaBiswas10
 
Leaf Initiation, Growth and Differentiation.pdf
Leaf Initiation, Growth and Differentiation.pdfLeaf Initiation, Growth and Differentiation.pdf
Leaf Initiation, Growth and Differentiation.pdf
RenuJangid3
 
Lab report on liquid viscosity of glycerin
Lab report on liquid viscosity of glycerinLab report on liquid viscosity of glycerin
Lab report on liquid viscosity of glycerin
ossaicprecious19
 
Seminar of U.V. Spectroscopy by SAMIR PANDA
 Seminar of U.V. Spectroscopy by SAMIR PANDA Seminar of U.V. Spectroscopy by SAMIR PANDA
Seminar of U.V. Spectroscopy by SAMIR PANDA
SAMIR PANDA
 
role of pramana in research.pptx in science
role of pramana in research.pptx in sciencerole of pramana in research.pptx in science
role of pramana in research.pptx in science
sonaliswain16
 
RNA INTERFERENCE: UNRAVELING GENETIC SILENCING
RNA INTERFERENCE: UNRAVELING GENETIC SILENCINGRNA INTERFERENCE: UNRAVELING GENETIC SILENCING
RNA INTERFERENCE: UNRAVELING GENETIC SILENCING
AADYARAJPANDEY1
 
Richard's entangled aventures in wonderland
Richard's entangled aventures in wonderlandRichard's entangled aventures in wonderland
Richard's entangled aventures in wonderland
Richard Gill
 

Recently uploaded (20)

Lateral Ventricles.pdf very easy good diagrams comprehensive
Lateral Ventricles.pdf very easy good diagrams comprehensiveLateral Ventricles.pdf very easy good diagrams comprehensive
Lateral Ventricles.pdf very easy good diagrams comprehensive
 
general properties of oerganologametal.ppt
general properties of oerganologametal.pptgeneral properties of oerganologametal.ppt
general properties of oerganologametal.ppt
 
platelets- lifespan -Clot retraction-disorders.pptx
platelets- lifespan -Clot retraction-disorders.pptxplatelets- lifespan -Clot retraction-disorders.pptx
platelets- lifespan -Clot retraction-disorders.pptx
 
erythropoiesis-I_mechanism& clinical significance.pptx
erythropoiesis-I_mechanism& clinical significance.pptxerythropoiesis-I_mechanism& clinical significance.pptx
erythropoiesis-I_mechanism& clinical significance.pptx
 
Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...
Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...
Circulatory system_ Laplace law. Ohms law.reynaults law,baro-chemo-receptors-...
 
Body fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptx
Body fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptxBody fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptx
Body fluids_tonicity_dehydration_hypovolemia_hypervolemia.pptx
 
In silico drugs analogue design: novobiocin analogues.pptx
In silico drugs analogue design: novobiocin analogues.pptxIn silico drugs analogue design: novobiocin analogues.pptx
In silico drugs analogue design: novobiocin analogues.pptx
 
Structures and textures of metamorphic rocks
Structures and textures of metamorphic rocksStructures and textures of metamorphic rocks
Structures and textures of metamorphic rocks
 
Cancer cell metabolism: special Reference to Lactate Pathway
Cancer cell metabolism: special Reference to Lactate PathwayCancer cell metabolism: special Reference to Lactate Pathway
Cancer cell metabolism: special Reference to Lactate Pathway
 
Unveiling the Energy Potential of Marshmallow Deposits.pdf
Unveiling the Energy Potential of Marshmallow Deposits.pdfUnveiling the Energy Potential of Marshmallow Deposits.pdf
Unveiling the Energy Potential of Marshmallow Deposits.pdf
 
Comparative structure of adrenal gland in vertebrates
Comparative structure of adrenal gland in vertebratesComparative structure of adrenal gland in vertebrates
Comparative structure of adrenal gland in vertebrates
 
EY - Supply Chain Services 2018_template.pptx
EY - Supply Chain Services 2018_template.pptxEY - Supply Chain Services 2018_template.pptx
EY - Supply Chain Services 2018_template.pptx
 
filosofia boliviana introducción jsjdjd.pptx
filosofia boliviana introducción jsjdjd.pptxfilosofia boliviana introducción jsjdjd.pptx
filosofia boliviana introducción jsjdjd.pptx
 
extra-chromosomal-inheritance[1].pptx.pdfpdf
extra-chromosomal-inheritance[1].pptx.pdfpdfextra-chromosomal-inheritance[1].pptx.pdfpdf
extra-chromosomal-inheritance[1].pptx.pdfpdf
 
Leaf Initiation, Growth and Differentiation.pdf
Leaf Initiation, Growth and Differentiation.pdfLeaf Initiation, Growth and Differentiation.pdf
Leaf Initiation, Growth and Differentiation.pdf
 
Lab report on liquid viscosity of glycerin
Lab report on liquid viscosity of glycerinLab report on liquid viscosity of glycerin
Lab report on liquid viscosity of glycerin
 
Seminar of U.V. Spectroscopy by SAMIR PANDA
 Seminar of U.V. Spectroscopy by SAMIR PANDA Seminar of U.V. Spectroscopy by SAMIR PANDA
Seminar of U.V. Spectroscopy by SAMIR PANDA
 
role of pramana in research.pptx in science
role of pramana in research.pptx in sciencerole of pramana in research.pptx in science
role of pramana in research.pptx in science
 
RNA INTERFERENCE: UNRAVELING GENETIC SILENCING
RNA INTERFERENCE: UNRAVELING GENETIC SILENCINGRNA INTERFERENCE: UNRAVELING GENETIC SILENCING
RNA INTERFERENCE: UNRAVELING GENETIC SILENCING
 
Richard's entangled aventures in wonderland
Richard's entangled aventures in wonderlandRichard's entangled aventures in wonderland
Richard's entangled aventures in wonderland
 

Symbolic Execution as DPLL Modulo Theories

  • 1. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution as DPLL Modulo Theories Q. Sang Phan Queen Mary, University of London September 25, 2014 1 / 25
  • 2. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Outline 1 Introduction 2 Background 3 Symbolic Execution as DPLL(T ) 4 A lightweight approach for Symbolic Execution 5 Conclusion 2 / 25
  • 3. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Outline 1 Introduction 2 Background 3 Symbolic Execution as DPLL(T ) 4 A lightweight approach for Symbolic Execution 5 Conclusion 3 / 25
  • 4. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution A program analysis technique that has several applications, in particular automated test generation. Executing programs with symbols instead of concrete inputs. 4 / 25
  • 5. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution Academic: Imperial: KLEE EPFL: S2E UC Berkeley: CREST and BitBlaze UIUC: Cute, jCute . . . Industry: NASA: Symbolic PathFinder Microsoft: Pex, Sage, Yogi IBM: Apollo . . . 5 / 25
  • 6. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Satis
  • 7. ability Modulo Theories Decision problem for logical formulas over one or more
  • 8. rst-order theories ' (:(x0 5) _ T1) ^ ((x0 5) _ T2) ^ (:(x0 5) _ (x1 = x0 + 1)) ^ (:(x1 3) _ T3) ^ (:(x1 3) _ (x2 = x1 1)) ^ ((x1 3) _ T4) ^ ((x1 3) _ (y1 = x1 + 1)) 6 / 25
  • 9. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Satis
  • 10. ability Modulo Theories Decision problem for logical formulas over one or more
  • 11. rst-order theories ' (:(x0 5) _ T1) ^ ((x0 5) _ T2) ^ (:(x0 5) _ (x1 = x0 + 1)) ^ (:(x1 3) _ T3) ^ (:(x1 3) _ (x2 = x1 1)) ^ ((x1 3) _ T4) ^ ((x1 3) _ (y1 = x1 + 1)) Tools: Microsoft: Z3 NYU: CVC3 SRI: Yices . . . SMT competition: http://www.smtcomp.org/ 6 / 25
  • 12. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution as an SMT solver Symbolic Execution can be viewed as an SMT solver 7 / 25
  • 13. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Outline 1 Introduction 2 Background 3 Symbolic Execution as DPLL(T ) 4 A lightweight approach for Symbolic Execution 5 Conclusion 8 / 25
  • 14. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion DPLL Modulo Theories The lazy approach for SMT SMT solver = SAT solver + T -solver SAT solver: implement DPLL algorithm T -solver: check satis
  • 15. ability of conjunctions of literals 9 / 25
  • 16. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion DPLL Modulo Theories The lazy approach for SMT SMT solver = SAT solver + T -solver SAT solver: implement DPLL algorithm T -solver: check satis
  • 17. ability of conjunctions of literals DPLL-based SAT solver: a depth-
  • 18. rst search procedure, using three main operations: decide: choose a literal l from the formula. propagate: remove all the clauses containing l , and deletes all occurrences of :l in the formula. backtrack: if encounter a con ict. 9 / 25
  • 19. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Boolean Abstraction ' (:(x0 5) _ T1) ^ ((x0 5) _ T2) ^ (:(x0 5) _ (x1 = x0 + 1)) ^ (:(x1 3) _ T3) ^ (:(x1 3) _ (x2 = x1 1)) ^ ((x1 3) _ T4) ^ ((x1 3) _ (y1 = x1 + 1)) (x0 5), (x1 = x0 + 1), . . . : T -atoms T1;T2; : : : : Boolean atoms 10 / 25
  • 20. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Boolean Abstraction ' (:(x0 5) _ T1) ^ ((x0 5) _ T2) ^ (:(x0 5) _ (x1 = x0 + 1)) ^ (:(x1 3) _ T3) ^ (:(x1 3) _ (x2 = x1 1)) ^ ((x1 3) _ T4) ^ ((x1 3) _ (y1 = x1 + 1)) (x0 5), (x1 = x0 + 1), . . . : T -atoms T1;T2; : : : : Boolean atoms Boolean abstraction of ': 'P (:G1 _ T1) ^ (G1 _ T2) ^ (:G1 _ A1) ^ (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 10 / 25
  • 21. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion DPLL-based SAT solver 'P (:G1 _ T1) ^ (G1 _ T2) ^ (:G1 _ A1) ^ (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 0. P = True 'P 1. P = G1 'P = (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 2. P = G1 ^ G2 'P = True ; T -solver() = Inconsistent 3. P = G1 'P = (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 4. P = G1 ^ :G2 'P = True ; T -solver() = Consistent 11 / 25
  • 22. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution pc ` c : execute the then path pc ` :c : execute the else path (pc 0 c) ^ (pc 0 :c): execute both paths then path: update pc1 = pc ^ c else path: update pc2 = pc ^ :c Use SMT solver to check satis
  • 23. ability of path conditions 12 / 25
  • 24. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution pc ` c : execute the then path pc ` :c : execute the else path (pc 0 c) ^ (pc 0 :c): execute both paths then path: update pc1 = pc ^ c else path: update pc2 = pc ^ :c Use SMT solver to check satis
  • 25. ability of path conditions Observation SMT solver is used to solve conjunctions of literals ) the SAT solver is not used 12 / 25
  • 26. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Implementation of Symbolic Execution Symbolic Executor = Boolean Executor + T -solver Boolean Executor: A depth-
  • 27. rst search procedure, using three main operations: decide: choose a literal from the condition. update: execute block of code on that path. backtrack: if reach the leaf of the symbolic execution tree. 13 / 25
  • 28. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Outline 1 Introduction 2 Background 3 Symbolic Execution as DPLL(T ) 4 A lightweight approach for Symbolic Execution 5 Conclusion 14 / 25
  • 29. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Transition System A bounded Static Single Assignment program: P (S; I ; G;A;T) S: the set of symbolic states I S : the set of initial symbolic states G : the set of guards A : the set of action Actions do not update computer memory: presented by Boolean atoms. Actions update computer memory: presented by T -atoms. T S G A S: the transition function 15 / 25
  • 30. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Program to formula tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij 16 / 25
  • 31. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Program to formula tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij Encode the transition into a formula: tij gij ! aij or equally tij :gij _ aij 16 / 25
  • 32. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Program to formula tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij Encode the transition into a formula: tij gij ! aij or equally tij :gij _ aij A program trace: t01 ^ t12 ^ ^ t(k1)k = (:g01 _ a01) ^ (:g12 _ a12) ^ (:g(k1)k _ a(k1)k ) 16 / 25
  • 33. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Program to formula tij = hsi ; gij ; aij ; sj i 2 T: si ! sj by action aij under guard gij Encode the transition into a formula: tij gij ! aij or equally tij :gij _ aij A program trace: t01 ^ t12 ^ ^ t(k1)k = (:g01 _ a01) ^ (:g12 _ a12) ^ (:g(k1)k _ a(k1)k ) Program semantics: all possible traces ' = ^ tij2T tij = ^ tij2T (:gij _ aij ) 16 / 25
  • 34. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Transition System: Example void test ( int x, int y){ if(x 5){ x ++; if (x 3) x --; else y = x + 1; } } s0 x0 5 T1 s1 s2 s3 s4 s5 s6 s7 ¬(x0 5) T2 x0 5 x1 = x0 + 1 x1 3 T3 ¬(x1 3) T4 x1 3 ¬(x1 3) x2 = x1 − 1 y1 = x1 + 1 17 / 25
  • 35. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Transition System: Example void test ( int x, int y){ if(x 5){ x ++; if (x 3) x --; else y = x + 1; } } s0 x0 5 T1 s1 s2 s3 s4 s5 s6 s7 ¬(x0 5) T2 x0 5 x1 = x0 + 1 x1 3 T3 ¬(x1 3) T4 x1 3 ¬(x1 3) x2 = x1 − 1 y1 = x1 + 1 ' (:(x0 5) _ T1) ^ ((x0 5) _ T2) ^ (:(x0 5) _ (x1 = x0 + 1)) ^ (:(x1 3) _ T3) ^ (:(x1 3) _ (x2 = x1 1)) ^ ((x1 3) _ T4) ^ ((x1 3) _ (y1 = x1 + 1)) 17 / 25
  • 36. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution vs SMT solver Symbolic Execution Symbolic Executor = Boolean Executor + T -solver Boolean Executor: a depth-
  • 37. rst search procedure, using three main operations: decide, update, backtrack SMT solver SMT solver = SAT solver + T -solver DPLL-based SAT solver: a depth-
  • 38. rst search procedure, using three main operations: decide, propagate, backtrack 18 / 25
  • 39. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Outline 1 Introduction 2 Background 3 Symbolic Execution as DPLL(T ) 4 A lightweight approach for Symbolic Execution 5 Conclusion 19 / 25
  • 40. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution vs SMT solver Symbolic Execution returns all symbolic path. SMT solvers return only one model. ! Use an SMT solver that can return all models for Symbolic Execution ! The only SMT solver known to generate all models: MathSAT 20 / 25
  • 41. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution via All-SMT 'P := (:G1 _ T1) ^ (G1 _ T2) ^ (:G1 _ A1) ^ (:G2 _ T3) ^ (:G2 _ A2) ^ (G2 _ T4) ^ (G2 _ A3) 1 (assert (= ( x0 5) G1)) 8 (assert (or (not G1) A1)) 2 (assert (= ( x1 3) G2)) 9 (assert (or (not G2) T3)) 3 (assert (= (= x1 (+ x0 1)) A1)) 10 (assert (or (not G2) A2)) 4 (assert (= (= x2 ( x1 1)) A2)) 11 (assert (or G2 T4)) 5 (assert (= (= y1 (+ x1 1)) A2)) 12 (assert (or G2 A3)) 6 (assert (or (not G1) T1)) 13 (check-allsat (G1 G2)) 7 (assert (or G1 T2)) 21 / 25
  • 42. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Symbolic Execution via All-SMT (G1 G2): (True,False), (False,True) and (False,False) s0 x0 5 T1 s1 s2 s3 s4 s5 s6 s7 ¬(x0 5) T2 x0 5 x1 = x0 + 1 x1 3 T3 ¬(x1 3) T4 x1 3 ¬(x1 3) x2 = x1 − 1 y1 = x1 + 1 22 / 25
  • 43. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Outline 1 Introduction 2 Background 3 Symbolic Execution as DPLL(T ) 4 A lightweight approach for Symbolic Execution 5 Conclusion 23 / 25
  • 44. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion Conclusion Symbolic Execution can be viewed as an SMT solver Exploit techniques developed for Symbolic Execution to SMT. Exploit techniques developed for SMT for Symbolic Execution. A lightweight approach for Symbolic Execution based on All-SMT solver 24 / 25
  • 45. Introduction Background Symbolic Execution as DPLL(T ) A lightweight approach for Symbolic Execution Conclusion THANK YOU FOR YOUR ATTENTION! 25 / 25