An overview of Coq Xinyu Feng USTC.

Slides:



Advertisements
Similar presentations
A Translation from Typed Assembly Language to Certified Assembly Programming Zhong Shao Yale University Joint work with Zhaozhong Ni Paper URL:
Advertisements

Static and User-Extensible Proof Checking Antonis StampoulisZhong Shao Yale University POPL 2012.
Translation-Based Compositional Reasoning for Software Systems Fei Xie and James C. Browne Robert P. Kurshan Cadence Design Systems.
Comparing Semantic and Syntactic Methods in Mechanized Proof Frameworks C.J. Bell, Robert Dockins, Aquinas Hobor, Andrew W. Appel, David Walker 1.
Certified Typechecking in Foundational Certified Code Systems Susmit Sarkar Carnegie Mellon University.
Proofs and Programs Wei Hu 11/01/2007. Outline  Motivation  Theory  Lambda calculus  Curry-Howard Isomorphism  Dependent types  Practice  Coq Wei.
Introducing Formal Methods, Module 1, Version 1.1, Oct., Formal Specification and Analytical Verification L 5.
Foundational Certified Code in a Metalogical Framework Karl Crary and Susmit Sarkar Carnegie Mellon University.
LIFE CYCLE MODELS FORMAL TRANSFORMATION
VIDE als voortzetting van Cocktail SET Seminar 11 september 2008 Dr. ir. Michael Franssen.
ISBN Chapter 3 Describing Syntax and Semantics.
Software Reliability CIS 640 Adapted from the lecture notes by Doron Pelel (
Proof Planning in Logical Frameworks Carsten Schürmann Yale University September 2002.
VeriML: Revisiting the Foundations of Proof Assistants Zhong Shao Yale University MacQueen Fest May 13, 2012 (Joint work with Antonis Stampoulis)
The Design and Implementation of a Certifying Compiler [Necula, Lee] A Certifying Compiler for Java [Necula, Lee et al] David W. Hill CSCI
Code-Carrying Proofs Aytekin Vargun Rensselaer Polytechnic Institute.
An Integration of Program Analysis and Automated Theorem Proving Bill J. Ellis & Andrew Ireland School of Mathematical & Computer Sciences Heriot-Watt.
Formal Methods in Software Engineering Credit Hours: 3+0 By: Qaisar Javaid Assistant Professor Formal Methods in Software Engineering1.
Advanced Formal Methods Mads Dam KTH/CSC Course 2D1453,
Building Reliable Software Requirements and Methods.
Programmability with Proof-Carrying Code George C. Necula University of California Berkeley Peter Lee Carnegie Mellon University.
On the Correctness of Model Transformations Gabor Karsai ISIS/Vanderbilt University.
Describing Syntax and Semantics
Extensible Untrusted Code Verification Robert Schneck with George Necula and Bor-Yuh Evan Chang May 14, 2003 OSQ Retreat.
Foundations of Programming Languages – Course Overview Xinyu Feng Acknowledgments: some slides taken or adapted from lecture notes of Stanford CS242
Python Mini-Course University of Oklahoma Department of Psychology Day 1 – Lesson 2 Fundamentals of Programming Languages 4/5/09 Python Mini-Course: Day.
Have Your Verified Compiler And Extend It Too Zachary Tatlock Sorin Lerner UC San Diego.
VeriML DARPA CRASH Project Progress Report Antonis Stampoulis October 5 th, 2012 A language-based, dependently-typed, user-extensible approach to proof.
Introduction to Our Research on Certifying Compiler Zhaopeng Li (In Chinese: 李兆鹏 ) Certifying Compiler Group USTC-Yale Joint.
Proof Carrying Code Zhiwei Lin. Outline Proof-Carrying Code The Design and Implementation of a Certifying Compiler A Proof – Carrying Code Architecture.
Overview of Formal Methods. Topics Introduction and terminology FM and Software Engineering Applications of FM Propositional and Predicate Logic Program.
WSMX Execution Semantics Executable Software Specification Eyal Oren DERI
ISBN Chapter 3 Describing Semantics -Attribute Grammars -Dynamic Semantics.
Checking Reachability using Matching Logic Grigore Rosu and Andrei Stefanescu University of Illinois, USA.
An overview of Coq Xinyu Feng USTC Erasmus Mundus NordSecMob Scholar at DTU.
Towards Automatic Verification of Safety Architectures Carsten Schürmann Carnegie Mellon University April 2000.
© Andrew IrelandDependable Systems Group On the Scalability of Proof Carrying Code for Software Certification Andrew Ireland School of Mathematical & Computer.
Advanced Development of Certified OS Kernels DARPA CRASH Site Visit PIs: Zhong Shao & Bryan Ford (Yale University) October 5th, Friday, 2012, Room 307.
Logic in Computer Science - Overview Sep 1, 2009 박성우.
3.2 Semantics. 2 Semantics Attribute Grammars The Meanings of Programs: Semantics Sebesta Chapter 3.
Chapter 3 Part II Describing Syntax and Semantics.
Tool Support for proof Engineering Anne Mulhern Computer Sciences Department University of Wisconsin-Madison Madison, WI USA
All-Path Reachability Logic Andrei Stefanescu 1, Stefan Ciobaca 2, Radu Mereuta 1,2, Brandon Moore 1, Traian Serbanuta 3, Grigore Rosu 1 1 University of.
SAFE KERNEL EXTENSIONS WITHOUT RUN-TIME CHECKING George C. Necula Peter Lee Carnegie Mellon U.
Static Techniques for V&V. Hierarchy of V&V techniques Static Analysis V&V Dynamic Techniques Model Checking Simulation Symbolic Execution Testing Informal.
URL: by Wishnu Prasetya Course on Program Verification 2015/2016.
CENG 424-Logic for CS Introduction Based on the Lecture Notes of Konstantin Korovin, Valentin Goranko, Russel and Norvig, and Michael Genesereth.
Sub-fields of computer science. Sub-fields of computer science.
Instructor: Sorin Lerner
Types for Programs and Proofs
Sparkle a functional theorem prover
(One-Path) Reachability Logic
State your reasons or how to keep proofs while optimizing code
Advanced Compilation and Automatic Programming
Program Verification Using
Foundations of Programming Languages – Course Overview
Lecture 5 Floyd-Hoare Style Verification
Benjamin Goldberg Compiler Verification and Optimization
Foundations of Programming Languages – Course Overview
IS 2935: Developing Secure Systems
Engineering Aspects of Formal Metatheory
Formal Semantics of Prog. Lang. – Introduction
Formal Methods in software development
The Design & Implementation of Hyperupcalls
Logic: tool-based modeling and reasoning
Motivation for Language Specification
When, What, Why create system and software models
Follow-up of MoU objectives
Rich Model Toolkit – An Infrastructure for Reliable Computer Systems
An overview of Coq.
Presentation transcript:

An overview of Coq Xinyu Feng USTC

What is Coq? A proof assistant developed by INRIA https://coq.inria.fr/ Coq is a formal proof management system. It provides a formal language to write mathematical definitions, executable algorithms and theorems together with an environment for semi-interactive development of machine-checked proofs …

What is Coq? A functional programming language with rich type sys. Define inductive data types and write algorithms manipulating them. All programs must terminate. A higher-order logic with interactive theorem prover Allows you to reason about mathematical structures and your programs Generates machine-checkable proofs A meta-language/logic Allows you to encode another language/logic and prove the properties of that language/logic

Why Coq? To have more rigorous formal reasoning For mathematics and program verification Tools like Coq boost program verification

Program verification under attack [CACM 1979] Mathematical proofs can often be wrong! Program verification would never work … Mathematics is trustworthy because of the social process to check/validate proofs. But nobody would care or check proofs for programs: “The verification of even a puny program can run into dozens of pages, and there's not alight moment or a spark of wit on any of those pages. Nobody is going to run into a friend's office with a program verification … Nobody is ever going to read it.”

Problem addressed by tools like Coq Proofs are mechanized and machine-checkable through Curry-Howard isomorphism [first published paper in 1980] Proof checking is as simple as type checking Fully automatic Very simple algorithm No longer need to trust the proofs Check them! Only need to trust the proof checker Simple, can be reviewed by human experts …

A framework for certified software Proof Checker Yes CPU Specifications Proof Machine code No certified code (code + proof) specifications: lang. semantics + program safety/security/correctness … automated proof checker need not trust the correctness of proofs

Applications of Coq Formal proofs of mathematical theorems Formal proof of 4-color theorem By Georges Gonthier and Benjamin Werner, 2004 Other: Feit–Thompson theorem proved in Coq in 2012 Formal verification OS kernels and hypervisors CertiKOS project at Yale seL4 in Isabelle at NICTA Compilers CompCert at INRIA and following projects LLVM verification and Upenn Others Web servers (bedrock projects @ MIT) Certified software tool chains (e.g., analysis algorithms) @ Princeton Teaching: logic, programming languages, …

Gains lots of popularity Other recipients of the award: Unix、TCP/IP、World-Wide Web、Java、Make、VMWare、Eclipse、LLVM …

Demo: Small examples Imp in Coq (syntax and operational semantics)