using and building an automatic program verifier

10
Using and Building an Automatic Program Verifier K. Rustan M. Leino Research in Software Engineering (RiSE) Microsoft Research, Redmond Lecture 2 Marktoberdorf Summer School 2011 Bayrischzell, BY, Germany 6 August 2011

Upload: kellie-cotton

Post on 02-Jan-2016

16 views

Category:

Documents


0 download

DESCRIPTION

Using and Building an Automatic Program Verifier. K. Rustan M. Leino Research in Software Engineering ( RiSE ) Microsoft Research, Redmond. Lecture 2 Marktoberdorf Summer School 2011 Bayrischzell , BY, Germany 6 August 2011. Isar and Dafny. lemma name: P proof - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: Using and Building an Automatic Program Verifier

Using and Building an Automatic Program Verifier

K. Rustan M. LeinoResearch in Software Engineering (RiSE)Microsoft Research, Redmond

Lecture 2Marktoberdorf Summer School 2011Bayrischzell, BY, Germany6 August 2011

Page 2: Using and Building an Automatic Program Verifier

Isar and Dafny

lemma name: Pproof

hence Q by sledgehammerhence R by simpthus S by grind

end

Page 3: Using and Building an Automatic Program Verifier

Isar and Dafny

lemma name: Pproof

assert Q by sledgehammerassert R by simpassert S by grind

end

Page 4: Using and Building an Automatic Program Verifier

Isar and Dafny

ghost method name()ensures P

{assert Q by sledgehammerassert R by simpassert S by grind

}

Page 5: Using and Building an Automatic Program Verifier

Isar and Dafny

ghost method name()ensures P

{assert Q by dafnyassert R by dafnyassert S by dafny

}

Page 6: Using and Building an Automatic Program Verifier

Isar and Dafny

ghost method name()ensures P;

{assert Q;assert R;assert S;

}

Page 7: Using and Building an Automatic Program Verifier

Ghost variables, ghost code

FindZero continued

demo

Page 8: Using and Building an Automatic Program Verifier

Object structures

List

demo

Page 9: Using and Building an Automatic Program Verifier

Exercises

Listhttp://rise4fun.com/Dafny/MbH

RockBandhttp://rise4fun.com/Dafny/wjD

Page 10: Using and Building an Automatic Program Verifier

Links

Dafnyresearch.microsoft.com/dafny

rise4funrise4fun.com

Verification Cornerresearch.microsoft.com/verificationcorner