package bap-std

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Brancher is responsible for resolving destinations of branch instructions.

type t = brancher
type dest = addr option * edge

destination target (if known) and edge classification (see edge)

val sexp_of_dest : dest -> Ppx_sexp_conv_lib.Sexp.t
val dest_of_sexp : Ppx_sexp_conv_lib.Sexp.t -> dest
type dests = dest list
val sexp_of_dests : dests -> Ppx_sexp_conv_lib.Sexp.t
val dests_of_sexp : Ppx_sexp_conv_lib.Sexp.t -> dests
val create : (mem -> Disasm_expert.Basic.full_insn -> dests) -> t

create resolve creates a brancher from resolve function, that accepts a memory region, occupied by an instruction, the instruction itself and returns a list of destination.

val set_path : t -> string -> t

set_path s limits the symbolizer applicability only to addresses that belong to a file/compilation unit with the specified path.

  • since 2.2.0
val path : t -> string option

path s is the path to the file that this symbolizer serves.

  • since 2.2.0
val of_bil : arch -> t

of_bil arch creates a brancher that will use a BIL code to statically deduce the instruction destinations.

val resolve : t -> mem -> Disasm_expert.Basic.full_insn -> dests

resolve brancher mem insn returns a list of destinations of the instruction insn, that occupies memory region mem.

val provide : t -> unit

provide brancher provides the brancher information to the knowledge base.

val providing : t -> (unit -> 'a Bap_knowledge.knowledge) -> 'a Bap_knowledge.knowledge

providing t scope provides the information in the specified scope,

After the scope function is evaluated the information source is retracted from the knowledge base.

See Bap_knowledge.Knowledge.promising{promising

}

.

  • since 2.2.0
module Factory : Source.Factory.S with type t = t
OCaml

Innovation. Community. Security.