jbmc - Bounded model checking for Java bytecode
- jbmc [-?] [-h]
[--help]
- show help
- jbmc
method-name
- Use the fully qualified name of a method as entry point, e.g.,
'mypackage.Myclass.foo:(I)Z'
- jbmc
class-name
- The entry point is the method specified by --function, or
otherwise, the public static void main(String[]) method of the
given class class-name.
- jbmc -jar
jarfile
- JAR file to be checked. The entry point is the method specified by
--function or otherwise, the public static void
main(String[]) method of the class specified by --main-class or
the main class specified in the JAR manifest (checked in this order).
- jbmc --gb
goto-binary
- GOTO binary file to be checked. The entry point is the method specified by
--function, or otherwise, the public static void
main(String[]) of the class specified by --main-class (checked
in this order).
- -classpath
dirs/jars, -cp dirs/jars, --classpath dirs/jars
- Set class search path of directories and jar files using a colon-separated
list of directories and JAR archives to search for class files.
- --main-class
class-name
- Set the name of the main class.
- --function
name
- Set entry point function name.
- --arch
arch
- Set analysis architecture, which defaults to the host architecture. Use
one of: alpha, arm, arm64, armel,
armhf, hppa, i386, ia64, mips,
mips64, mips64el, mipsel, mipsn32,
mipsn32el, powerpc, ppc64, ppc64le,
riscv64, s390, s390x, sh4, sparc,
sparc64, v850, x32, x86_64, or
none.
- --os os
- Set analysis operating system, which defaults to the host operating
system. Use one of: freebsd, linux, macos,
netbsd, openbsd, solaris, hurd, or
windows.
- --i386-linux,
--i386-win32, --i386-macos, --ppc-macos,
--win32, --winx64
- Set analysis architecture and operating system.
- --LP64, --ILP64,
--LLP64, --ILP32, --LP32
- Set width of int, long and pointers, but don't override default
architecture and operating system.
- --16, --32, --64
- Equivalent to --LP32, --ILP32, --LP64 (on Windows:
--LLP64).
- --little-endian
- allow little-endian word-byte conversions
- --big-endian
- allow big-endian word-byte conversions
- --gcc
- use GCC as preprocessor
- --disable-uncaught-exception-check
- ignore uncaught exceptions and errors
- --throw-assertion-error
- Throw java.lang.AssertionError on violated assert statements
instead of failing at the location of the assert statement.
- --throw-runtime-exceptions
- Make implicit runtime exceptions explicit.
- --assert-no-exceptions-thrown
- Transform throw instructions into assert FALSE followed by
assume FALSE.
- --max-nondet-array-length
N
- Limit nondet (e.g. input) array size to at most N.
- --max-nondet-tree-depth
N
- Limit size of nondet (e.g. input) object tree; at level N
references are set to null.
- --java-assume-inputs-non-null
- Never initialize reference-typed parameter to the entry point with
null.
- --java-assume-inputs-interval
[L:U] or [L:] or [:U]
- Force numerical primitive-typed inputs (byte, short,
int, long, float, double) to be initialized
within the given range; lower bound L and upper bound U must
be integers; does not work for arrays.
- --java-assume-inputs-integral
- Force float and double inputs to have integer values; does not work for
arrays;
- --java-max-vla-length
N
- Limit the length of user-code-created arrays to N.
- --java-cp-include-files
r
- Regular expression or JSON list of files to load (with '@' prefix).
- --java-load-class
CLASS
- Also load code from class CLASS.
- --java-no-load-class
CLASS
- Never load code from class CLASS.
- --ignore-manifest-main-class
- Ignore Main-Class entries in JAR manifest files. If this option is
specified and the options --function and --main-class are
not, we can be certain that all classes in the JAR file are loaded.
- --context-include
i, --context-exclude e
- Only analyze code matching specification i that does not match
specification e, if --context-exclude e is also used.
All other methods are excluded, i.e., we load their signatures and
meta-information, but not their bodies. A specification is any prefix of a
package, class or method name, e.g. "org.cprover." or
"org.cprover.MyClass." or
"org.cprover.MyClass.methodToStub:(I)Z". These options can be
given multiple times. The default for context-include is 'all included';
default for context-exclude is 'nothing excluded'.
- --no-lazy-methods
- Load and translate all methods given on the command line and in
--classpath Default is to load methods that appear to be reachable
from the --function entry point or main class. Note that
--show-symbol-table, --show-goto-functions and
--show-properties output are restricted to loaded methods by
default.
- --lazy-methods-extra-entry-point
METHODNAME
- Treat METHODNAME as a possible program entry point for the purpose
of lazy method loading. METHODNAME can be a regular expression that
will be matched against all symbols. If missing, a java:: prefix
will be added. If no descriptor is found, all overloads of a method will
also be added.
- --static-values
f
- Load initial values of static fields from the given JSON file. We assign
static fields to these values instead of calling the normal static
initializer (clinit) method. The argument can be a relative or absolute
path to the file.
- --java-lift-clinit-calls
- Lifts clinit calls in function bodies to the top of the function. This may
reduce the overall cost of static initialisation, but may be unsound if
there are cyclic dependencies between static initializers due to
potentially changing their order of execution, or if static initializers
have side-effects such as updating another class' static field.
- --java-threading
- enable java multi-threading support (experimental)
- --java-unwind-enum-static
- unwind loops in static initialization of enums
- --symex-driven-lazy-loading
- only load functions when first entered by symbolic execution. Note that
--show-symbol-table, --show-goto-functions/properties output
will be restricted to loaded methods in this case, and only output after
the symex phase.
- --nondet-static
- add nondeterministic initialization of variables with static lifetime
All tools honor the TMPDIR environment variable when generating
temporary files and directories.
If you encounter a problem please create an issue at
https://github.com/diffblue/cbmc/issues
cbmc(1), janalyzer(1), jdiff(1)
2001-2018, Daniel Kroening, Edmund Clarke