package jasmin

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

Module Jasmin.SyntaxSource

Sourcemodule L = Location
Sourceexception ParseError of Location.t * string option
Sourceval parse_error : ?msg:string -> Location.t -> 'a
Sourcetype arr_access = Warray_.arr_access
Sourcetype sign = [
  1. | `Unsigned
  2. | `Signed
]
Sourcetype vesize = [
  1. | `W1
  2. | `W2
  3. | `W4
  4. | `W8
  5. | `W16
  6. | `W32
  7. | `W64
  8. | `W128
]
Sourcetype vsize = [
  1. | `V2
  2. | `V4
  3. | `V8
  4. | `V16
  5. | `V32
]
Sourcetype wsign = [
  1. | `Word of sign option
  2. | `WInt of sign
]
Sourcetype svsize = vsize * sign * vesize
Sourcetype castop1 =
  1. | CSS of swsize
  2. | CVS of svsize
Sourcetype castop = castop1 L.located option
Sourcetype int_representation = string
Sourceval parse_int : int_representation -> Z.t
Sourceval bits_of_wsize : Annotations.wsize -> int
Sourceval string_of_sign : sign -> string
Sourceval suffix_of_wsign : [< `WInt of sign | `Word of sign option ] -> string
Sourceval string_of_swsize_op : (Annotations.wsize * [< `WInt of sign | `Word of sign option ]) -> string
Sourceval string_of_swsize_ty : (Annotations.wsize * [< `WInt of sign | `Word of sign option ]) -> string
Sourceval int_of_vsize : vsize -> int
Sourceval bits_of_vesize : vesize -> int
Sourceval string_of_svsize : (vsize * sign * vesize) -> string
Sourceval string_of_osign : sign option -> string
Sourcetype cast = [
  1. | `ToWord of swsize
  2. | `ToInt of sign option
]
Sourcetype peop1 = [
  1. | `Cast of cast
  2. | `Not of castop
  3. | `Neg of castop
]
Sourcetype peop2 = [
  1. | `And
  2. | `Or
  3. | `Add of castop
  4. | `Sub of castop
  5. | `Mul of castop
  6. | `Div of sign option * castop
  7. | `Mod of sign option * castop
  8. | `BAnd of castop
  9. | `BOr of castop
  10. | `BXOr of castop
  11. | `ShR of sign option * castop
  12. | `ROR of castop
  13. | `ROL of castop
  14. | `ShL of castop
  15. | `Eq of castop
  16. | `Neq of castop
  17. | `Lt of sign option * castop
  18. | `Le of sign option * castop
  19. | `Gt of sign option * castop
  20. | `Ge of sign option * castop
]
Sourceval string_of_castop1 : castop1 -> string
Sourceval string_of_castop : castop -> string
Sourceval string_of_cast : [< `ToInt of sign option | `ToWord of Annotations.wsize * [< `WInt of sign | `Word of sign option ] ] -> string
Sourceval string_of_peop1 : peop1 -> string
Sourceval string_of_signcastop : (sign option * castop) -> string
Sourceval string_of_peop2 : peop2 -> string
module W = Wsize
Sourcetype pexpr_r =
  1. | PEParens of pexpr
  2. | PEVar of Annotations.pident
  3. | PEGet of [ `Aligned | `Unaligned ] option * arr_access * swsize L.located option * Annotations.pident * pexpr * pexpr option
  4. | PEFetch of mem_access
  5. | PEpack of svsize * pexpr list
  6. | PEBool of bool
  7. | PEInt of int_representation
  8. | PECall of Annotations.pident * pexpr list
  9. | PECombF of Annotations.pident * pexpr list
  10. | PEPrim of Annotations.pident * pexpr list
  11. | PEOp1 of peop1 * pexpr
  12. | PEOp2 of peop2 * pexpr * pexpr
  13. | PEIf of pexpr * pexpr * pexpr
Sourceand mem_access = [ `Aligned | `Unaligned ] option * swsize L.located option * pexpr
Sourceand psizetype =
  1. | TypeWsize of swsize
  2. | TypeSizeAlias of Annotations.pident
Sourceand ptype_r =
  1. | TBool
  2. | TInt
  3. | TWord of swsize
  4. | TArray of psizetype * pexpr
  5. | TAlias of Annotations.pident
Sourcetype writable = [
  1. | `Constant
  2. | `Writable
]
Sourcetype ptr = [
  1. | `Pointer of writable option
  2. | `Direct
]
Sourcetype pstorage = [
  1. | `Reg of ptr
  2. | `Stack of ptr
  3. | `Inline
  4. | `Global
]
Sourcetype pstotype = pstorage * ptype
Sourcetype annot_pstotype = Annotations.annotations * pstotype
Sourcetype plvalue_r =
  1. | PLIgnore
  2. | PLVar of Annotations.pident
  3. | PLArray of [ `Aligned | `Unaligned ] option * arr_access * swsize L.located option * Annotations.pident * pexpr * pexpr option
  4. | PLMem of mem_access
Sourcetype plvalue = plvalue_r L.located
Sourcetype peqop = [
  1. | `Raw
  2. | `Add of castop
  3. | `Sub of castop
  4. | `Mul of castop
  5. | `Div of sign option * castop
  6. | `Mod of sign option * castop
  7. | `ShR of sign option * castop
  8. | `ROR of castop
  9. | `ROL of castop
  10. | `ShL of castop
  11. | `BAnd of castop
  12. | `BXOr of castop
  13. | `BOr of castop
]
Sourcetype align = [
  1. | `Align
  2. | `NoAlign
]
Sourcetype plvals = Annotations.annotations L.located option * plvalue list
Sourcetype vardecl = Annotations.pident * pexpr option
Sourcetype vardecls = pstotype * vardecl L.located list
Sourceval var_decl_id : vardecl -> Annotations.pident
Sourcetype pinstr_r =
  1. | PIArrayInit of Annotations.pident
    (*

    ArrayInit(x);

    *)
  2. | PIAssign of plvals * peqop * pexpr * pexpr option
    (*

    x, y += z >> 4 if c;

    *)
  3. | PIIf of pexpr * pblock * pblock option
    (*

    if e else

    *)
  4. | PIFor of Annotations.pident * fordir * pexpr * pexpr * pblock
    (*

    for i = 0 to N

    *)
  5. | PIWhile of pblock option * pexpr * pblock option
    (*

    while (x > 0)

    *)
  6. | PIdecl of vardecls
    (*

    reg u32 x y z;

    *)
Sourceand pblock_r = pinstr list
Sourceand fordir = [
  1. | `Down
  2. | `Up
]
Sourceval string_of_sizetype : psizetype -> Annotations.symbol
Sourceval pp_writable : [< `Constant | `Writable ] option -> string
Sourceval pp_pointer : [< `Direct | `Pointer of [< `Constant | `Writable ] option ] -> string
Sourceval pp_storage : [< `Global | `Inline | `Reg of [< `Direct | `Pointer of [< `Constant | `Writable ] option ] | `Stack of [< `Direct | `Pointer of [< `Constant | `Writable ] option ] ] -> string
Sourcetype pparam = {
  1. ppa_ty : ptype;
  2. ppa_name : Annotations.pident;
  3. ppa_init : pexpr;
}
Sourcetype pfunbody = {
  1. pdb_instr : pinstr list;
  2. pdb_ret : Annotations.pident list option L.located;
}
Sourcetype pcall_conv = [
  1. | `Export
  2. | `Inline
]
Sourcetype paramdecls = pstotype * Annotations.pident list
Sourcetype pfundef = {
  1. pdf_annot : Annotations.annotations;
  2. pdf_cc : pcall_conv option;
  3. pdf_name : Annotations.pident;
  4. pdf_args : (Annotations.annotations * paramdecls) list;
  5. pdf_rty : (Annotations.annotations * pstotype) list option;
  6. pdf_body : pfunbody;
}
Sourcetype gpexpr =
  1. | GEword of pexpr
  2. | GEarray of pexpr list
  3. | GEstring of string L.located
Sourcetype pglobal = {
  1. pgd_type : ptype;
  2. pgd_name : Annotations.pident;
  3. pgd_val : gpexpr;
}
Sourcetype pexec = {
  1. pex_name : Annotations.pident;
  2. pex_mem : (int_representation * int_representation) list;
}
Sourcetype prequire = string L.located
Sourcetype pitem =
  1. | PFundef of pfundef
  2. | PParam of pparam
  3. | PGlobal of pglobal
  4. | Pexec of pexec
  5. | Prequire of Annotations.pident option * prequire list
  6. | PNamespace of Annotations.pident * pitem L.located list
  7. | PTypeAlias of Annotations.pident * ptype
Sourcetype pprogram = pitem L.located list