Verified Software Toolchain (Verifiable C)
Also known as VST, Verifiable C, VST-Floyd
Prove in the Rocq proof assistant that a C program meets its specification; compiled with CompCert, the proof carries down to the assembly code.
Use it if
- You need the strongest guarantee available for a C program, carried down to assembly by CompCert, and can invest in interactive proofs in Rocq.
- Your code is self-contained C such as a cryptographic primitive or a data-structure library, written in (or easy to adapt to) the subset VST supports.
Look elsewhere if
- Your code casts between pointers and integers, uses bit-fields, goto, struct assignment, or defines variadic functions; VST rejects these.
- You want push-button checking; every function needs a hand-written proof in Rocq.
- You use it commercially and cannot get a CompCert license: the clightgen tool that turns C into Rocq is not open source.
How it works
From your code to an accepted proof. Each step either has to be trusted or is checked by something else.
- Input C code
- Front end CompCert clightgen Trusted Translates a .c file into a Rocq file holding its Clight syntax tree. It is CompCert's own front end: the parser is verified, but preprocessing (an external C preprocessor) and elaboration are not (CompCert manual, section 1.3).
- Semantics CompCert Clight semantics Verified VST's program logic is proved sound against this semantics, and CompCert is proved correct against the same semantics, so when you compile with CompCert it is an internal interface rather than an assumption.
- Translation Verifiable C program logic and Floyd proof automation Verified A higher-order separation logic for Clight, proved sound in Rocq. Floyd is the set of Rocq tactics that users run to build proofs.
- Checker Rocq kernel Trusted
- Compiler CompCert (or GCC / Clang) Verified CompCert's correctness proof covers compilation to assembly; the assembler and linker are outside it. Compiling with GCC or Clang is possible, but then the compiler must be trusted.
Verified or checked: outside the trusted base Validated per run or by tests Trusted without proof
- C: Programs in the Verifiable C subset of CompCert Clight; clightgen -normalize first moves side effects and memory loads out of expressions.
Trust
What a proof from this toolchain relies on: the trusted computing baseTrusted computing base (TCB). Everything that must be correct for a proof to mean what it says., one part at a time. How these are rated.
- Checker What has the final word on a proof?Strong
Every proof is checked by the Rocq kernel.
- Semantics Is the tool's model of the language the real language?Strong
CompCert's C semantics; with CompCert it is a proved interface, not an assumption.
The VST and CompCert proofs meet at the same Clight semantics, so a program compiled with CompCert does not depend on that semantics matching ISO C. With GCC or Clang, the semantics becomes an assumption about what those compilers do.
- Frontend How does your source get into the model?Strong
CompCert's own front end; its parser is verified, its elaboration is not.
clightgen uses the same front end as the CompCert compiler. Preprocessing is done by an external tool and elaboration to CompCert C is not verified (CompCert manual, section 1.3). If you compile with GCC or Clang instead, treat this axis as amber.
- Binary gap Does the proof cover what actually runs?Strong
With CompCert the proof carries down to assembly; assembler and linker not covered.
Published VST proofs compose with CompCert's correctness theorem in Rocq. The CompCert manual says assembling and linking are not verified. Compiling with GCC or Clang instead puts the compiler back in the trusted base.
- Escape hatches Can a proof silently rest on unchecked assumptions?Partial
Rocq Admitted and Axiom exist; Print Assumptions lists them.
Library specifications imported from floyd.library (malloc, free, exit and others) are assumed. The manual says so and suggests not importing them if you do not trust them.
What it can prove
Kinds of guarantees, not how easy they are to get.
| Feature | Support | Notes |
|---|---|---|
| No undefined behavior Memory safety and absence of runtime errors: no out-of-bounds access, use-after-free, overflow traps, panics or undefined behavior on any input allowed by the precondition. | SupportedSupported.A proved function never crashes or hits undefined behavior in CompCert C, given its precondition. Signed integer overflow must be proved absent. Source | A proved function never crashes or hits undefined behavior in CompCert C, given its precondition. Signed integer overflow must be proved absent. source |
| Functional correctness The code meets a written specification of its results, for example “returns the sorted list” or “implements this RFC”. | SupportedSupported.The main use: functions are proved against specifications written in Rocq. Source | The main use: functions are proved against specifications written in Rocq. source |
| Equivalence Two programs (an optimized and a reference version, or code before and after a change) are proved to behave the same, or one refines the other. | Not supportedNot supported.No built-in way to compare two programs. You can prove that both meet the same specification. | No built-in way to compare two programs. You can prove that both meet the same specification. |
| Information flow Secrets do not influence public outputs, timing or memory access patterns (constant-time code, non-interference). | Not supportedNot supported.The program logic has no rules for secrecy or timing. Published VST work proves cryptographic security by composing functional correctness with separate Rocq proofs, not information-flow properties of the C code. Source | The program logic has no rules for secrecy or timing. Published VST work proves cryptographic security by composing functional correctness with separate Rocq proofs, not information-flow properties of the C code. source |
| Concurrency Correctness of code with threads or shared memory: absence of data races, deadlock freedom, linearizability of concurrent data structures. | PartialPartial.Supports threads synchronized with locks and with sequentially consistent atomics, using Iris-style reasoning. Weaker (relaxed) atomics are not supported. CompCert's proof is for sequential code; extending it to concurrent programs is a separate research result. Source | Supports threads synchronized with locks and with sequentially consistent atomics, using Iris-style reasoning. Weaker (relaxed) atomics are not supported. CompCert's proof is for sequential code; extending it to concurrent programs is a separate research result. source |
| Termination and liveness Every run finishes, or the system keeps making progress (liveness). | Not supportedNot supported.Partial correctness only: a proof says the code does not crash and, if it terminates, ends in a state satisfying the postcondition. Source | Partial correctness only: a proof says the code does not crash and, if it terminates, ends in a state satisfying the postcondition. source |
Language coverage
Which parts of C it handles. Hover or focus a mark for details.
Common features
| Feature | Support | Notes |
|---|---|---|
| Machine integers Fixed-width integer arithmetic, overflow and bit operations. | SupportedSupported.Signed and unsigned machine integers; signed overflow must be proved absent. Source | Signed and unsigned machine integers; signed overflow must be proved absent. source |
| Floating point IEEE 754 floating-point arithmetic, including rounding and NaNs. | SupportedSupported.Uses CompCert's IEEE 754 model. The LAProof work verified a floating-point sparse matrix-vector multiply in C with VST, including accuracy bounds. Source | Uses CompCert's IEEE 754 model. The LAProof work verified a floating-point sparse matrix-vector multiply in C with VST, including accuracy bounds. source |
| Heap and pointers Dynamically allocated memory, pointers or references, and aliasing. | SupportedSupported.Separation logic for pointer data structures; malloc and free have (assumed) specifications. Source | Separation logic for pointer data structures; malloc and free have (assumed) specifications. source |
| Arrays and buffers Indexed memory such as arrays, slices, vectors and byte buffers. | SupportedSupported. Source | source |
| Loops Unbounded loops, which need invariants or bounds to verify. | SupportedSupported.Loops are verified with user-written loop invariants. Source | Loops are verified with user-written loop invariants. source |
| Recursion Functions that call themselves, directly or through others. | SupportedSupported. Source | source |
| Higher-order code Function pointers, closures and callbacks. | SupportedSupported.Function pointers are supported; the manual shows object-oriented C with function pointers (progs/verif_object.v, progs/verif_message.v). Source | Function pointers are supported; the manual shows object-oriented C with function pointers (progs/verif_object.v, progs/verif_message.v). source |
| Threads and shared memory Concurrent threads with locks, atomics or message passing. | PartialPartial.Locks and sequentially consistent atomics only; no relaxed atomics. Source | Locks and sequentially consistent atomics only; no relaxed atomics. source |
| I/O and system calls Files, network, system calls and foreign-function calls. | PartialPartial.Calls to external functions (system calls, I/O) are given specifications that are assumed, not proved. Source | Calls to external functions (system calls, I/O) are given specifications that are assumed, not proved. source |
| Standard library Specifications or models for the language's standard library. | PartialPartial.Ships assumed specifications for malloc, free, exit and a few others; the manual says their implementations are not proved against them. Other library functions need your own specifications. Source | Ships assumed specifications for malloc, free, exit and a few others; the manual says their implementations are not proved against them. Other library functions need your own specifications. source |
C-specific features
| Feature | Support | Notes |
|---|---|---|
| Pointer casts and provenance Casting between pointers and integers, pointer arithmetic across objects. | Not supportedNot supported.The manual lists "no casting between integers and pointers" as a restriction of Verifiable C. Source | The manual lists "no casting between integers and pointers" as a restriction of Verifiable C. source |
| Unions and type punning Reading a value through a different type than it was written with. | PartialPartial.Unions are supported. Reading a different member than the one written works only in special cases: same representation, or numeric members of the same size (manual chapter on union casting). Source | Unions are supported. Reading a different member than the one written works only in special cases: same representation, or numeric members of the same size (manual chapter on union casting). source |
| Bit-fields Struct members narrower than a byte. | Not supportedNot supported.The manual lists "no bitfields in structs" as a restriction, even though CompCert itself supports them. Source | The manual lists "no bitfields in structs" as a restriction, even though CompCert itself supports them. source |
| Variadic functions Functions such as printf that take a variable number of arguments. | PartialPartial.Variadic functions cannot be verified. There is limited, undocumented support for calling printf and fprintf. Source | Variadic functions cannot be verified. There is limited, undocumented support for calling printf and fprintf. source |
| setjmp / longjmp Non-local jumps out of nested calls. | Not supportedNot supported.CompCert, whose semantics VST uses, treats setjmp and longjmp as ordinary functions and advises against using them. Source | CompCert, whose semantics VST uses, treats setjmp and longjmp as ordinary functions and advises against using them. source |
| volatile and MMIO Memory-mapped device registers and volatile accesses. | UnknownUnknown.The manual does not describe how volatile accesses are verified. | The manual does not describe how volatile accesses are verified. |
| Inline assembly Assembly code embedded in C functions. | Not supportedNot supported.No documented support in VST. CompCert turns asm statements off by default and warns that they can break its guarantees. Source | No documented support in VST. CompCert turns asm statements off by default and warns that they can break its guarantees. source |
Stage
Computed from the evidence below; see the criteria. 1criterion is missing for Stage 2.
- Met: Released or updated in the last 12 months Latest release: 2.17, 2026-09-22. evidence
- Met: Installs and runs on current platforms Release 2.17 (2026-09) works with Rocq 9.1 to 9.3 and CompCert 3.18. evidence
- Met: User documentation or tutorial Reference manual plus Software Foundations Volume 5 (Verifiable C) as a tutorial. evidence
- Met: Used by a group other than its authors Radboud University used VST to prove X25519 in TweetNaCl correct (CSF 2021). evidence
- Not met: Verified code in production at two or more independent organizations None recorded.
- Met: Checker axis is not red
- Met: Semantics axis is not red
- Met: Public channel for soundness bugs Public GitHub issue tracker. evidence
In use
Verified code in production, and notable verification projects.
Facts and sources
- Effort
- Interactive: You write proofs step by step in a proof assistant.
- Licence
- Open source, BSD-2-Clause (VST itself; the CompCert clightgen front end it needs is under the INRIA non-commercial license)
- Maintained by
- Princeton University
- Latest release
- 2.17 (22 Sep 2026) source
- Last checked
- 26 Nov 2026
Further sources
- VST repository and README · accessed 26 Nov 2026
- Verifiable C reference manual · accessed 26 Nov 2026
- Verifying Concurrent Programs with VST (Mansky) · accessed 26 Nov 2026
- VST 2.17 release notes · accessed 26 Nov 2026
- VST license · accessed 26 Nov 2026
- Note on the clightgen license · accessed 26 Nov 2026
- VST home page · accessed 26 Nov 2026
- Verified Correctness and Security of mbedTLS HMAC-DRBG (CCS 2017), trusted base discussion · accessed 26 Nov 2026
- Compiler Correctness for Concurrency (Princeton TR-014-19, 2020) · accessed 26 Nov 2026
- CompCert manual, structure and verified parts · accessed 26 Nov 2026