package lustre-v6

  1. Overview
  2. Docs
The Lustre V6 Verimag compiler

Install

Dune Dependency

Authors

Maintainers

Sources

lustre-v6.v6.107.1.tgz
md5=4b642b106a76e19de3751afb53ccdcf4
sha512=ec6d35f0f4da219490cad7969d86e9128b7c3f03baa507f662b038b1915383581eda697ddb0e734a1a5311ef6b0908b1d0cf375a0be5dbb1aa7e9e79848037cc

doc/lustre-v6/AstCore/index.html

Module AstCoreSource

(Raw) Abstract syntax tree of source Lustre Core programs.

Sourcetype clock_exp =
  1. | Base
  2. | NamedClock of Lv6Id.clk Lxm.srcflagged

type_exp is used to type flow, parameters, constants.

Sourceand type_exp_core =
  1. | Bool_type_exp
  2. | Int_type_exp
  3. | Real_type_exp
  4. | Named_type_exp of Lv6Id.idref
  5. | Array_type_exp of type_exp * val_exp
Sourceand node_info = {
  1. name : Lv6Id.t;
  2. static_params : static_param Lxm.srcflagged list;
  3. vars : node_vars option;
  4. loc_consts : (Lxm.t * const_info) list;
  5. def : node_def;
  6. has_mem : bool;
  7. is_safe : bool;
}
Sourceand static_param =
  1. | StaticParamType of Lv6Id.t
  2. | StaticParamConst of Lv6Id.t * type_exp
  3. | StaticParamNode of Lv6Id.t * var_info Lxm.srcflagged list * var_info Lxm.srcflagged list * has_mem_flag * is_safe_flag
Sourceand node_vars = {
  1. inlist : Lv6Id.t list;
  2. outlist : Lv6Id.t list;
  3. loclist : Lv6Id.t list option;
  4. vartable : var_info_table;
}
Sourceand var_info = {
  1. var_nature : var_nature;
  2. var_name : Lv6Id.t;
  3. var_number : int;
  4. var_type : type_exp;
  5. var_clock : clock_exp;
}
Sourceand var_nature =
  1. | VarInput
  2. | VarOutput
  3. | VarLocal
Sourceand node_def =
  1. | Extern
  2. | Abstract
  3. | Body of node_body
  4. | Alias of by_pos_op Lxm.srcflagged
Sourceand node_body = {
  1. asserts : val_exp Lxm.srcflagged list;
  2. eqs : eq_info Lxm.srcflagged list;
}
Sourceand has_mem_flag = bool
Sourceand is_safe_flag = bool
Sourceand eq_info = left_part list * val_exp
Sourceand left_part =
  1. | LeftVar of Lv6Id.t Lxm.srcflagged
  2. | LeftField of left_part * Lv6Id.t Lxm.srcflagged
  3. | LeftArray of left_part * val_exp Lxm.srcflagged
  4. | LeftSlice of left_part * slice_info Lxm.srcflagged
Sourceand slice_info = {
  1. si_first : val_exp;
  2. si_last : val_exp;
  3. si_step : val_exp option;
}
Sourceand by_pos_op =
  1. | Predef_n of AstPredef.op Lxm.srcflagged
  2. | CALL_n of node_exp Lxm.srcflagged
  3. | IDENT_n of Lv6Id.idref
  4. | PRE_n
  5. | ARROW_n
  6. | FBY_n
  7. | CURRENT_n
  8. | WHEN_n of clock_exp
  9. | TUPLE_n
  10. | WITH_n of val_exp * val_exp * val_exp
  11. | CONCAT_n
  12. | HAT_n
  13. | ARRAY_n
  14. | STRUCT_ACCESS_n of Lv6Id.t
  15. | ARRAY_ACCES_n of val_exp
  16. | ARRAY_SLICE_n of slice_info
Sourceand operands =
  1. | Oper of val_exp list
Sourceand by_name_op =
  1. | STRUCT_n of Lv6Id.idref
  2. | STRUCT_WITH_n of Lv6Id.idref * Lv6Id.idref
  3. | STRUCT_anonymous_n
Sourceand static_arg =
  1. | StaticArgLv6Id of Lv6Id.idref
  2. | StaticArgConst of val_exp
  3. | StaticArgType of type_exp
  4. | StaticArgNode of by_pos_op

Params statiques effectifs :

  • val_exp (pour les constantes)
  • type_exp (pour les types)
  • node_exp (pour les node)
  • ident : a résoudre, peut etre const, type ou node

constant

Sourceand const_info =
  1. | ExternalConst of Lv6Id.t * type_exp * val_exp option
  2. | EnumConst of Lv6Id.t * type_exp
  3. | DefinedConst of Lv6Id.t * type_exp option * val_exp

Type

Sourcetype field_info = {
  1. fd_name : Lv6Id.t;
  2. fd_type : type_exp;
  3. fd_value : val_exp option;
}
Sourcetype struct_type_info = {
  1. st_name : Lv6Id.t;
  2. st_flist : Lv6Id.t list;
  3. st_ftable : (Lv6Id.t, field_info Lxm.srcflagged) Hashtbl.t;
}
Sourcetype type_info =
  1. | ExternalType of Lv6Id.t
  2. | AliasedType of Lv6Id.t * type_exp
  3. | EnumType of Lv6Id.t * Lv6Id.t Lxm.srcflagged list
  4. | StructType of struct_type_info
  5. | ArrayType of Lv6Id.t * type_exp * val_exp

Operator

Sourcetype item_ident =
  1. | ConstItem of Lv6Id.t
  2. | TypeItem of Lv6Id.t
  3. | NodeItem of Lv6Id.t * static_param Lxm.srcflagged list
Sourcetype item_info =
  1. | ConstInfo of const_info
  2. | TypeInfo of type_info
  3. | NodeInfo of node_info
Sourceval string_of_type_exp : type_exp -> string
Sourceval string_of_var_nature : var_nature -> string
Sourceval lxm_of_val_exp : val_exp -> Lxm.t
OCaml

Innovation. Community. Security.