package goblint
Install
dune-project
Dependency
Authors
Maintainers
Sources
sha256=99b78e6def71534d195eef9084baa26d8334b36084e120aa6afb300c9bf8afa6
sha512=f3162bd95a03c00358a2991f6152fc6169205bfb4c55e2c483e98cc3935673df9656d025b6f1ea0fa5f1bd0aee037d4f483966b0d2907e3fa9bf11a93a3392af
doc/goblint.lib/Goblint_lib/index.html
Module Goblint_libSource
Main library.
Framework
Main external executable functionality: command-line, front-end and analysis execution.
module Control : sig ... endMain internal functionality: analysis of the program by abstract interpretation via constraint solving.
module Server : sig ... endInteractive server mode using JSON-RPC.
CFG
Control-flow graphs (CFGs) are used to represent each function.
module Node = Nodemodule Edge = Edgemodule MyCFG = MyCFGmodule CfgTools = CfgToolsSpecification
Analyses are specified by domains and transfer functions. A dynamic composition of analyses is combined with CFGs to produce a constraint system.
module Analyses : sig ... endAnalysis specification and constraint system signatures.
module Constraints : sig ... endConstruction of a constraint system from an analysis specification and CFGs. Transformatons of analysis specifications as functors.
module AnalysisState = AnalysisStatemodule AnalysisStateUtil = AnalysisStateUtilmodule ControlSpecC = ControlSpecCMaster control program (MCP) is the analysis specification for the dynamic product of activated analyses.
module MCP : sig ... endMCP analysis specification.
module MCPRegistry : sig ... endRegistry of dynamically activatable analyses. Analysis specification modules for the dynamic product.
module MCPAccess : sig ... endMemory access metadata module for MCP.
MCP allows activated analyses to query each other during the analysis. Query results from different analyses for the same query are met for precision.
module Queries : sig ... endQueries and their result lattices.
MCP allows activated analyses to emit events to each other during the analysis.
module Events : sig ... endEvents.
Results
The following modules help query the constraint system solution using semantic information.
module AnalysisResult : sig ... endAnalysis result output.
module ResultQuery : sig ... endPerform queries on the constraint system solution.
Configuration
Runtime configuration is represented as JSON. Options are specified and documented by the JSON schema src/config/options.schema.json.
module AutoSoundConfig : sig ... endAutomatically turning on analyses required to ensure soundness based on a given specification (e.g., SV-COMP specification) or programming idioms (e.g., longjmp) in the analyzed code, but only when it is possible to do so automatically. This does not fully exempt from the need for manual configuration.
Analyses
Analyses activatable under MCP.
Value
Analyses related to values of program variables.
module Base : sig ... endNon-relational value analysis aka base analysis (base).
module VarEq : sig ... endSymbolic expression equalities analysis (var_eq).
module CondVars : sig ... endSymbolic variable - logical expression equalities analysis (condvars).
module TmpSpecial : sig ... endAnalysis that tracks which variables hold the results of calls to math library functions (tmpSpecial).
Heap
Analyses related to the heap.
module Region : sig ... endAnalysis of disjoint heap regions for dynamically allocated memory (region).
module MallocFresh : sig ... endAnalysis of unescaped (i.e. thread-local) heap locations (mallocFresh).
module Malloc_null : sig ... endPath-sensitive analysis of failed dynamic memory allocations (malloc_null).
module MemLeak : sig ... endAn analysis for the detection of memory leaks (memLeak).
module UseAfterFree : sig ... endAn analysis for the detection of use-after-free vulnerabilities (useAfterFree).
module MemOutOfBounds : sig ... endAn analysis for the detection of out-of-bounds memory accesses (memOutOfBounds).
Concurrency
Analyses related to concurrency.
Locks
Analyses related to locking.
module MutexEventsAnalysis : sig ... endMutex locking and unlocking analysis (mutexEvents).
module LocksetAnalysis : sig ... endBasic lockset analyses.
module MutexTypeAnalysis : sig ... endAn analysis tracking the type of a mutex (pthreadMutexType).
module MutexAnalysis : sig ... endMust lockset and protecting lockset analysis (mutex).
module MayLocks : sig ... endMay lockset analysis and analysis of double locking (maylocks).
module SymbLocks : sig ... endSymbolic lockset analysis for per-element (field or index) locking patterns (symb_locks).
module Deadlock : sig ... endDeadlock analysis (deadlock).
Threads
Analyses related to threads.
module ThreadFlag : sig ... endMulti-threadedness analysis (threadflag).
module ThreadId : sig ... endCurrent thread ID analysis (threadid).
module ThreadAnalysis : sig ... endCreated threads and their uniqueness analysis (thread).
module ThreadJoins : sig ... endJoined threads analysis (threadJoins).
module MHPAnalysis : sig ... endMay-happen-in-parallel (MHP) analysis for memory accesses (mhp).
module ThreadReturn : sig ... endThread returning analysis which abstracts a thread's call stack by a boolean, indicating whether it is at the topmost call stack frame or not (threadreturn).
Other
module RaceAnalysis : sig ... endData race analysis (race).
module ThreadEscape : sig ... endEscape analysis for thread-local variables (escape).
module PthreadSignals : sig ... endMust received signals analysis for Pthread condition variables (pthreadSignals).
module ExtractPthread : sig ... endPromela extraction analysis for Pthread programs (extract-pthread).
Longjmp
Analyses related to longjmp and setjmp.
module ActiveSetjmp : sig ... endAnalysis of active setjmp buffers (activeSetjmp).
module ModifiedSinceSetjmp : sig ... endAnalysis of variables modified since setjmp (modifiedSinceSetjmp).
module ActiveLongjmp : sig ... endAnalysis of active longjmp targets (activeLongjmp).
module PoisonVariables : sig ... endTaint analysis of variables that were modified between setjmp and longjmp and not yet overwritten. (poisonVariables).
module Vla : sig ... endAnalysis of variable-length arrays (VLAs) in scope (vla).
Tutorial
Analyses for didactic purposes.
module Constants : sig ... endSimple intraprocedural integer constants analysis example (constants).
module Signs : sig ... endSimple intraprocedural integer signs analysis template (signs).
module Taint : sig ... endSimple interprocedural taint analysis template (taint).
module UnitAnalysis : sig ... endSimplest possible analysis with unit domain (unit).
Other
module Assert : sig ... endAnalysis of assert results (assert).
module LoopTermination : sig ... endTermination analysis for loops and goto statements (termination).
module Callstring : sig ... endCall String analysis call_string and/or Call Site analysis call_site. The call string limitation for both approaches can be adjusted with the "callString_length" option. By adding new implementations of the CallstringType, additional analyses can be added.
module LoopfreeCallstring : sig ... endmodule Uninit : sig ... endAnalysis of initialized local variables (uninit).
module Expsplit : sig ... endPath-sensitive analysis according to values of arbitrary given expressions (expsplit).
module StackTrace : sig ... endCall stack analyses (stack_trace, stack_trace_set, stack_loc).
Helper
Analyses which only support other analyses.
module AccessAnalysis : sig ... endAnalysis of memory accesses (access).
module WrapperFunctionAnalysis : sig ... endFamily of analyses which provide symbolic locations for special library functions. Provides symbolic heap locations for dynamic memory allocations and symbolic thread identifiers for thread creation (mallocWrapper, threadCreateWrapper).
module TaintPartialContexts : sig ... endTaint analysis of variables modified in a function (taintPartialContexts).
module UnassumeAnalysis : sig ... endUnassume analysis (unassume).
module ExpRelation : sig ... endStateless symbolic comparison expression analysis (expRelation).
module AbortUnless : sig ... endAnalysis of assume_abort_if_not-style functions (abortUnless).
module PtranalAnalysis : sig ... endCIL's GoblintCil.Ptranal for function pointer evaluation (ptranal).
Domains
Domains used by analysis specifications and constraint systems are lattices.
Besides lattice operations, their elements can also be compared and output (in various formats). Those operations are specified by Printable.S.
module Printable = PrintableGeneral
Standard general-purpose domains and domain functors.
Analysis-specific
Domains for specific analyses.
Value
Non-relational
Domains for Base analysis.
Numeric
module IntDomain = IntDomainmodule FloatDomain = FloatDomainAddresses
Memory locations are identified by mvalues, which consist of a variable and an offset. Mvalues are used throughout Goblint, not just the Base analysis.
Addresses extend mvalues with NULL, unknown pointers and string literals.
module Mval = Mvalmodule Offset = Offsetmodule StringDomain = StringDomainmodule AddressDomain = AddressDomainComplex
module StructDomain = StructDomainmodule UnionDomain = UnionDomainmodule ArrayDomain = ArrayDomainmodule NullByteSet = NullByteSetmodule JmpBufDomain = JmpBufDomainCombined
These combine the above domains together for Base analysis.
module BaseDomain : sig ... endFull domain of Base analysis.
module ValueDomain = ValueDomainmodule ValueDomainQueries = ValueDomainQueriesRelational
Domains for RelationAnalysis.
Concurrency
module MutexAttrDomain = MutexAttrDomainmodule LockDomain : sig ... endLockset domains.
module SymbLocksDomain : sig ... endSymbolic lockset domain.
module DeadlockDomain : sig ... endDeadlock domain.
module ThreadFlagDomain : sig ... endMulti-threadedness flag domains.
module ThreadIdDomain = ThreadIdDomainmodule ConcDomain = ConcDomainmodule MHP : sig ... endMay-happen-in-parallel (MHP) domain.
module EscapeDomain : sig ... endDomain for escaped thread-local variables.
module PthreadDomain : sig ... endDomains for extraction of Pthread programs.
Other
module Basetype = Basetypemodule Lval = Lvalmodule Access : sig ... endMemory accesses and their manipulation.
module AccessDomain : sig ... endDomain for memory accesses.
module MusteqDomain : sig ... endSymbolic lvalue equalities domain.
module RegionDomain : sig ... endDomains for disjoint heap regions.
module StackDomain : sig ... endCall stack domains.
Testing
Modules related to (property-based) testing of domains.
module DomainProperties : sig ... endQCheck properties for lattice properties.
module AbstractionDomainProperties : sig ... endQCheck properties for abstract operations.
module IntDomainProperties : sig ... endQCheck properties for IntDomain.
Incremental
Incremental analysis is for analyzing multiple versions of the same program and reusing as many results as possible.
I/O
Various input/output interfaces and formats.
module Messages = MessagesFront-end
The following modules handle program input.
module Preprocessor : sig ... endDetection of suitable C preprocessor.
module CompilationDatabase : sig ... endInput program from a real-world project using a compilation database.
module TerminationPreprocessing : sig ... endWitnesses
Witnesses are an exchangeable format for analysis results.
module Svcomp : sig ... endSV-COMP tasks and results.
module SvcompSpec : sig ... endSV-COMP specification strings and files.
module Invariant = Invariantmodule InvariantCil = InvariantCilmodule WitnessUtil : sig ... endUtilities for witness generation and witness invariants.
GraphML
Automaton-based GraphML witnesses used in SV-COMP.
module MyARG : sig ... endAbstract reachability graph.
module WitnessConstraints : sig ... endAnalysis specification transformation for ARG construction.
module Witness : sig ... endOutput of ARG as GraphML.
module Graphml : sig ... endStreaming GraphML output.
YAML
Entry-based YAML witnesses to be used in SV-COMP.
module YamlWitness : sig ... endYAML witness generation and validation.
module YamlWitnessType : sig ... endYAML witness format types.
module WideningTokens : sig ... endWidening tokens are a generic and dynamic mechanism for delaying widening.
Violation
Experimental generation of violation witness automata or refinement with observer automata.
module Violation : sig ... endViolation checking in an ARG.
ARG path feasibility checking using weakest precondition and Z3 (not installed!).
module ObserverAutomaton : sig ... endFinite automaton for matching an infeasible ARG path.
module ObserverAnalysis : sig ... endPath-sensitive analysis using an ObserverAutomaton.
module Refinement : sig ... endExperimental analysis refinement.
SARIF
module SarifType : sig ... endSARIF format types.
module SarifRules : sig ... endSARIF rule definitions for Goblint.
Transformations
Transformations can be activated to transform the program using analysis results.
module Transform : sig ... endSignatures and registry for transformations.
module DeadCode : sig ... endDead code elimination transformation (remove_dead_code).
module EvalAssert : sig ... endTransformation for instrumenting the program with computed invariants as assertions (assert).
module ExpressionEvaluation : sig ... endTransformation for evaluating expressions on the analysis results (expeval). Hack for Gobview.
Utilities
module Timing = Timingmodule GoblintDir : sig ... endIntermediate data directory.
General
module IntOps = IntOpsmodule FloatOps = FloatOpsmodule LazyEval = LazyEvalmodule ResettableLazy = ResettableLazymodule ProcessPool : sig ... endProcess pool for running processes in parallel.
module Timeout : sig ... endTimeout utilities.
module TimeUtil : sig ... endDate and time utilities.
module MessageUtil = MessageUtilmodule XmlUtil = XmlUtilmodule GobExn : sig ... endException utilities.
CIL
module CilType = CilTypemodule Cilfacade = Cilfacademodule CilLocation = CilLocationmodule RichVarinfo = RichVarinfomodule CilCfg : sig ... endCreation of CIL CFGs.
module LoopUnrolling : sig ... endSyntactic loop unrolling.
Library specification
For more precise analysis of C standard library, etc functions, whose definitions are not available, custom specifications can be added.
Analysis-specific
module BaseUtil : sig ... endBasic analysis utilities.
module PrecisionUtil = PrecisionUtilmodule ContextUtil = ContextUtilmodule ReturnUtil : sig ... endSpecial variable for return value.
module BaseInvariant : sig ... endAnalyses.Spec.branch refinement for Base analysis.
module CommonPriv : sig ... endThread-modular value analysis utilities for BasePriv and RelationPriv.
module WideningThresholds = WideningThresholdsmodule VectorMatrix : sig ... endOCaml implementations of vectors and matrices.
Precision comparison
module PrecCompare : sig ... endPrecision comparison.
module PrecCompareUtil : sig ... endSignatures for precision comparison.
module PrivPrecCompareUtil : sig ... endBasePriv precision comparison.
Library extensions
OCaml library extensions which are completely independent of Goblint.
See Goblint_std.
Standard library
OCaml standard library extensions which are not provided by Batteries.
module GobFormat = GobFormat