Module Flambda2_terms.Static_const
Language terms that represent statically-allocated values, bound to symbols.
type t = private | Set_of_closures of Flambda2_terms.Set_of_closures.t| Block of Flambda2_kinds.Tag.Scannable.t * Flambda2_terms.Mutability.t * Flambda2_kinds.Flambda_kind.Scannable_block_shape.t * Flambda2_term_basics.Simple.With_debuginfo.t list| Boxed_float32 of Flambda2_numbers.Numeric_types.Float32_by_bit_pattern.t Flambda2_term_basics.Or_variable.t| Boxed_float of Flambda2_numbers.Numeric_types.Float_by_bit_pattern.t Flambda2_term_basics.Or_variable.t| Boxed_int32 of Stdlib.Int32.t Flambda2_term_basics.Or_variable.t| Boxed_int64 of Stdlib.Int64.t Flambda2_term_basics.Or_variable.t| Boxed_nativeint of Flambda2_numbers.Targetint_32_64.t Flambda2_term_basics.Or_variable.t| Boxed_vec128 of Flambda2_numbers.Vector_types.Vec128.Bit_pattern.t Flambda2_term_basics.Or_variable.t| Boxed_vec256 of Flambda2_numbers.Vector_types.Vec256.Bit_pattern.t Flambda2_term_basics.Or_variable.t| Boxed_vec512 of Flambda2_numbers.Vector_types.Vec512.Bit_pattern.t Flambda2_term_basics.Or_variable.t| Immutable_float_block of Flambda2_numbers.Numeric_types.Float_by_bit_pattern.t Flambda2_term_basics.Or_variable.t list| Immutable_float_array of Flambda2_numbers.Numeric_types.Float_by_bit_pattern.t Flambda2_term_basics.Or_variable.t list| Immutable_float32_array of Flambda2_numbers.Numeric_types.Float32_by_bit_pattern.t Flambda2_term_basics.Or_variable.t list| Immutable_int_array of Flambda2_numbers.Target_ocaml_int.t Flambda2_term_basics.Or_variable.t list| Immutable_int8_array of Flambda2_numbers.Numeric_types.Int8.t Flambda2_term_basics.Or_variable.t list| Immutable_int16_array of Flambda2_numbers.Numeric_types.Int16.t Flambda2_term_basics.Or_variable.t list| Immutable_int32_array of Stdlib.Int32.t Flambda2_term_basics.Or_variable.t list| Immutable_int64_array of Stdlib.Int64.t Flambda2_term_basics.Or_variable.t list| Immutable_nativeint_array of Flambda2_numbers.Targetint_32_64.t Flambda2_term_basics.Or_variable.t list| Immutable_vec128_array of Flambda2_numbers.Vector_types.Vec128.Bit_pattern.t Flambda2_term_basics.Or_variable.t list| Immutable_vec256_array of Flambda2_numbers.Vector_types.Vec256.Bit_pattern.t Flambda2_term_basics.Or_variable.t list| Immutable_vec512_array of Flambda2_numbers.Vector_types.Vec512.Bit_pattern.t Flambda2_term_basics.Or_variable.t list| Immutable_value_array of Flambda2_term_basics.Simple.With_debuginfo.t list(*
*)Immutable_*_arrayconstructors always have at least one field. For empty arrays,Empty_arraymust be used.| Empty_array of Flambda2_term_basics.Empty_array_kind.t(*
*)Empty_arraymust specify the kind of the empty array. Arrays of unboxed numbers such as int32 and int64 have a slightly different representation (currently using custom blocks) from regular arrays of values. This affects all operations, most importantly the computation of the length of the array.| Mutable_string of {}| Immutable_string of string
The static structure of a symbol, possibly with holes, ready to be filled with values computed at runtime.
include Flambda2_algorithms.Container_types.S
with type t := Flambda2_terms.Static_const.t
module T :
Flambda2_algorithms.Container_types_intf.Thing
with type t = Flambda2_terms.Static_const.tinclude Flambda2_algorithms.Container_types_intf.Thing
with type t := Flambda2_terms.Static_const.T.t
include Stdlib.Hashtbl.HashedType
with type t := Flambda2_terms.Static_const.T.t
val equal :
Flambda2_terms.Static_const.T.t ->
Flambda2_terms.Static_const.T.t ->
boolThe equality predicate used to compare keys.
val hash : Flambda2_terms.Static_const.T.t -> intA hashing function on keys. It must be such that if two keys are equal according to equal, then they have identical hash values as computed by hash. Examples: suitable (equal, hash) pairs for arbitrary key types include
- (
(=),hash) for comparing objects by structure (provided objects do not contain floats) - (
(fun x y -> compare x y = 0),hash) for comparing objects by structure and handlingStdlib.nancorrectly - (
(==),hash) for comparing objects by physical equality (e.g. for mutable or cyclic objects).
include Stdlib.Map.OrderedType with type t := Flambda2_terms.Static_const.T.t
val compare :
Flambda2_terms.Static_const.T.t ->
Flambda2_terms.Static_const.T.t ->
intA total ordering function over the keys. This is a two-argument function f such that f e1 e2 is zero if the keys e1 and e2 are equal, f e1 e2 is strictly negative if e1 is smaller than e2, and f e1 e2 is strictly positive if e1 is greater than e2. Example: a suitable ordering function is the generic structural comparison function Stdlib.compare.
val print : Stdlib.Format.formatter -> Flambda2_terms.Static_const.T.t -> unitmodule Set :
Flambda2_algorithms.Container_types_intf.Set
with type elt = Flambda2_terms.Static_const.tmodule Map :
Flambda2_algorithms.Container_types_intf.Map
with type key = Flambda2_terms.Static_const.t
and module Set = Flambda2_terms.Static_const.Setinclude Flambda2_nominal.Contains_names.S
with type t := Flambda2_terms.Static_const.t
val free_names :
Flambda2_terms.Static_const.t ->
Flambda2_nominal.Name_occurrences.tCompute the free names of a term. Such computation covers all kinds of bindable names (variables, continuations, ...)
val apply_renaming :
Flambda2_terms.Static_const.t ->
Flambda2_nominal.Renaming.t ->
Flambda2_terms.Static_const.tApply a renaming throughout a term.
include Flambda2_nominal.Contains_ids.S
with type t := Flambda2_terms.Static_const.t
val ids_for_export :
Flambda2_terms.Static_const.t ->
Flambda2_nominal.Ids_for_export.tGather all table identifiers to export them.
val set_of_closures :
Flambda2_terms.Set_of_closures.t ->
Flambda2_terms.Static_const.tval boxed_int32 :
Stdlib.Int32.t Flambda2_term_basics.Or_variable.t ->
Flambda2_terms.Static_const.tval boxed_int64 :
Stdlib.Int64.t Flambda2_term_basics.Or_variable.t ->
Flambda2_terms.Static_const.tval boxed_nativeint :
Flambda2_numbers.Targetint_32_64.t Flambda2_term_basics.Or_variable.t ->
Flambda2_terms.Static_const.tval immutable_float_block :
Flambda2_numbers.Numeric_types.Float_by_bit_pattern.t
Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tval immutable_float_array :
Flambda2_numbers.Numeric_types.Float_by_bit_pattern.t
Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_float32_array :
Flambda2_numbers.Numeric_types.Float32_by_bit_pattern.t
Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_int_array :
Flambda2_numbers.Target_ocaml_int.t Flambda2_term_basics.Or_variable.t list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_int8_array :
Flambda2_numbers.Numeric_types.Int8.t Flambda2_term_basics.Or_variable.t list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_int16_array :
Flambda2_numbers.Numeric_types.Int16.t Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_int32_array :
Stdlib.Int32.t Flambda2_term_basics.Or_variable.t list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_int64_array :
Stdlib.Int64.t Flambda2_term_basics.Or_variable.t list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_nativeint_array :
Flambda2_numbers.Targetint_32_64.t Flambda2_term_basics.Or_variable.t list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_vec128_array :
Flambda2_numbers.Vector_types.Vec128.Bit_pattern.t
Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_vec256_array :
Flambda2_numbers.Vector_types.Vec256.Bit_pattern.t
Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_vec512_array :
Flambda2_numbers.Vector_types.Vec512.Bit_pattern.t
Flambda2_term_basics.Or_variable.t
list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val immutable_value_array :
Flambda2_term_basics.Simple.With_debuginfo.t list ->
Flambda2_terms.Static_const.tThis function can accept empty lists of fields; Empty_array will be produced.
val empty_array :
Flambda2_term_basics.Empty_array_kind.t ->
Flambda2_terms.Static_const.tval mutable_string : initial_value:string -> Flambda2_terms.Static_const.tval immutable_string : string -> Flambda2_terms.Static_const.tval is_block : Flambda2_terms.Static_const.t -> boolval is_set_of_closures : Flambda2_terms.Static_const.t -> boolval is_fully_static : Flambda2_terms.Static_const.t -> boolval must_be_set_of_closures :
Flambda2_terms.Static_const.t ->
Flambda2_terms.Set_of_closures.tval match_against_bound_static_pattern :
Flambda2_terms.Static_const.t ->
Flambda2_bound_identifiers.Bound_static.Pattern.t ->
set_of_closures:
(closure_symbols:
Flambda2_identifiers.Symbol.t Flambda2_identifiers.Function_slot.Lmap.t ->
Flambda2_terms.Set_of_closures.t ->
'a) ->
block_like:
(Flambda2_identifiers.Symbol.t -> Flambda2_terms.Static_const.t -> 'a) ->
'a