CBMC vs OpenJML
CBMC
diffblue.github.ioOpenJML
openjml.orgSide by side
| Figure | CBMC | OpenJML |
|---|---|---|
| Price from | Free | Free |
| Free plan | Yes | Yes |
| Free trial | — | — |
| Open source | — | — |
| Windows | Yes | Yes |
| macOS | Yes | Yes |
| Linux | Yes | Yes |
| API | — | Yes |
| Self-hosted | Yes | — |
| Plans published | 1 | 1 |
| Spec score · Formal Verification Tools | 8.1 (#8) | 7.9 (#14) |
| Language support | The repository states support for C89, C99, most of C11, C17, C23, many GCC and Visual Studio extensions, and SystemC using Scoot. | The feature status page says Java language elements through Java 7 are generally parsed, typechecked, and compiled in runtime assertion checking, with exceptions and partial support documented. |
| License | The repository identifies CBMC as licensed under the 4-clause BSD license. | The OpenJML User Guide states that the command-line tool is licensed under GPL version 2. |
| Purpose | CBMC is a bounded model checker for C and C++ programs that explores possible execution paths and checks assertions. | OpenJML checks whether Java programs annotated with Java Modeling Language specifications satisfy those specifications. |
Plans
In their own words
CBMC
CBMC is a bounded model checker for C and C++ programs. It explores execution paths to check assertions, including array bounds, pointer safety, exceptions, and some undefined behavior such as signed integer overflow. Its analysis unwinds loops before sending the resulting equation to a decision procedure, and inputs may need a bounded size. The repository lists C89, C99, most of C11, C17, C23, GCC and Visual Studio extensions, and SystemC through Scoot; the listed input languages also include Java bytecode. CBMC supports contracts and can produce counterexamples. Its incremental SMT2 backend works with SMT-LIB 2.6-compliant solvers, with Z3 and CVC5 as examples. Distribution options include Homebrew instructions for macOS, Ubuntu DEB packages, Windows MSI installers, and Docker images. goto-cc can replace gcc or cl.exe in Makefiles to collect project models. The guide discusses routine development and continuous integration use. CBMC is free under the 4-clause BSD license.