Debian Codegraph @

kernel/nativecode.mli

raw symbols SCIP
1 (************************************************************************)
2 (* * The Rocq Prover / The Rocq Development Team *)
3 (* v * Copyright INRIA, CNRS and contributors *)
4 (* <O___,, * (see version control and CREDITS file for authors & dates) *)
5 (* \VV/ **************************************************************)
6 (* // * This file is distributed under the terms of the *)
7 (* * GNU Lesser General Public License Version 2.1 *)
8 (* * (see LICENSE file for the text of the license) *)
9 (************************************************************************)
10 open Names
11 open Constr
12 open Declarations
13 open Environ
14 open Nativevalues
15
16 (** This file defines the mllambda code generation phase of the native
17 compiler. mllambda represents a fragment of ML, and can easily be printed
18 to OCaml code. *)
19
20 type cenv
21
22 val make_cenv : unit -> cenv
23 val get_cenv_symbols : cenv -> symbols
24
25 type global
26
27 val debug_native_compiler : CDebug.t
28
29 val keep_debug_files : unit -> bool
30
31 val pp_global : Format.formatter -> global -> unit
32
33 val mk_open : string -> global
34
35 val get_value : symbols -> int -> Nativevalues.t
36
37 val get_sort : symbols -> int -> Sorts.t
38
39 val get_name : symbols -> int -> Name.t
40
41 val get_const : symbols -> int -> Constant.t
42
43 val get_match : symbols -> int -> Nativevalues.annot_sw
44
45 val get_ind : symbols -> int -> inductive
46
47 val get_evar : symbols -> int -> Evar.t
48
49 val get_instance : symbols -> int -> UVars.Instance.t
50
51 val get_proj : symbols -> int -> inductive * int
52
53 type code_location_updates
54 type linkable_code = global list * symbols * code_location_updates
55
56 val empty_updates : code_location_updates
57
58 val register_native_file : string -> unit
59
60 val is_loaded_native_file : string -> bool
61
62 val compile_constant_field : cenv -> env -> Constant.t ->
63 global list -> constant_body -> global list
64
65 val compile_mind_field : cenv -> ModPath.t -> Id.t ->
66 global list -> mutual_inductive_body -> global list
67
68 val compile_rewrite_rules : env -> Id.t ->
69 global list -> rewrite_rules_body -> global list
70
71 val mk_conv_code : env -> Genlambda.evars -> string -> constr -> constr -> linkable_code
72 val mk_norm_code : env -> Genlambda.evars -> string -> constr -> linkable_code
73
74 val mk_library_header : Nativevalues.symbols -> global list
75
76 val mod_uid_of_dirpath : DirPath.t -> string
77
78 val link_info_of_dirpath : DirPath.t -> link_info
79
80 val update_locations : code_location_updates -> unit
81
82 val add_header_comment : global list -> string -> global list