aboutsummaryrefslogtreecommitdiffhomepage
path: root/kernel/cClosure.ml
Commit message (Collapse)AuthorAge
* Swapping Context and Constr: defining declarations on constr in Constr.Gravatar Hugo Herbelin2018-06-27
| | | | | | | | | This shall eventually allow to use contexts of declarations in the definition of the "Case" constructor. Basically, this means that Constr now includes Context and that the "t" types of Context which were specialized on constr are not defined in Constr (unfortunately using a heavy boilerplate).
* Using more general information for primitive records.Gravatar Pierre-Marie Pédrot2018-06-23
| | | | | This brings more compatibility with handling of mutual primitive records in the kernel.
* Faster and cleaner fconstr-to-constr conversion function.Gravatar Pierre-Marie Pédrot2018-06-17
| | | | | | | | We untangle the implementation in several ways. - No higher-order self argument function as there is only one caller. - Compute composition of lifts + substitution on terms using a dedicated function instead of mk_clos followed by to_constr. - Take more advantage of identity substitutions.
* Merge PR #7418: Actually take advantage of the normalization status of ↵Gravatar Maxime Dénès2018-06-04
|\ | | | | | | kernel closures.
* | Unify pre_env and envGravatar Maxime Dénès2018-05-28
| | | | | | | | | | We now have only two notions of environments in the kernel: env and safe_env.
* | Exporting Fun1 within Array so that Array.Fun1 and not only CArray.Fun1 works.Gravatar Hugo Herbelin2018-05-23
| |
| * Actually take advantage of the normalization status of kernel closures.Gravatar Pierre-Marie Pédrot2018-05-01
|/ | | | | | | | | | | | We know that when a fterm is marked as Whnf or Norm, the only thing that can happen in the reduction machine is administrative reduction pushing the destructured term on the stack. Thus there is no need to perform any actual performative reduction. Furthermore, every head subterm of those terms are recursively Whnf or Norm, which implies that no update mark is pushed on the stack during the destructuration. So there is no need to unzip the stack to unset FLOCKED nodes as well.
* [api] Deprecate a couple of aliases that we missed.Gravatar Emilio Jesus Gallego Arias2018-03-28
|
* Merge PR #6769: Split closure cache and remove whd_bothGravatar Maxime Dénès2018-03-09
|\
* | Replace invalid tag @raises in ocamldoc comments with @raiseGravatar mrmr19932018-03-05
| |
| * Pass the constant cache as a separate argument in kernel reduction.Gravatar Pierre-Marie Pédrot2018-03-04
| |
* | Update headers following #6543.Gravatar Théo Zimmermann2018-02-27
|/
* Merge PR #6685: Use whd-all on rigid-flex conversion.Gravatar Maxime Dénès2018-02-07
|\
| * Respect the transparent state of the current conversion on strong weak-head.Gravatar Pierre-Marie Pédrot2018-02-05
| | | | | | | | | | This fixes the previous patch in rare corner-cases where unification code was relying on both kernel conversion and specific transparent state.
* | CClosure.unfold_projection: don't catch Not_found, assume env is okGravatar Gaëtan Gilbert2018-02-02
| | | | | | | | | | We can do this after the parent commit (Reductionops.nf_* don't use empty env)
* | kernel: cleanup projection unfoldingGravatar Gaëtan Gilbert2018-02-02
|/ | | | | - use Redflags.red_projection - share unfold_projection between CClosure and Reduction
* Share the rel environment between Environ.env and reduction cache.Gravatar Pierre-Marie Pédrot2017-12-29
|
* [api] Also deprecate constructors of Decl_kinds.Gravatar Emilio Jesus Gallego Arias2017-12-23
| | | | | | | | Unfortunately OCaml doesn't deprecate the constructors of a type when the type alias is deprecated. In this case it means that we don't get rid of the kernel dependency unless we deprecate the constructors too.
* [api] Remove aliases of `Evar.t`Gravatar Emilio Jesus Gallego Arias2017-11-26
| | | | | There don't really bring anything, we also correct some minor nits with the printing function.
* Make some functions on terms more robust w.r.t new term constructs.Gravatar Maxime Dénès2017-11-23
| | | | | | Extending terms is notoriously difficult. We try to get more help from the compiler by making sure such an extension will trigger non exhaustive pattern matching warnings.
* [api] Move structures deprecated in the API to the core.Gravatar Emilio Jesus Gallego Arias2017-11-06
| | | | We do up to `Term` which is the main bulk of the changes.
* [api] Deprecate all legacy uses of Names in core.Gravatar Emilio Jesus Gallego Arias2017-11-06
| | | | This will allow to merge back `Names` with `API.Names`
* Bump year in headers.Gravatar Pierre-Marie Pédrot2017-07-04
|
* Drop '.' from CErrors.anomaly, insert it in argsGravatar Jason Gross2017-06-02
| | | | | | | | | | | | | | | | | As per https://github.com/coq/coq/pull/716#issuecomment-305140839 Partially using ```bash git grep --name-only 'anomaly\s*\(~label:"[^"]*"\s*\)\?\(Pp.\)\?(\(\(Pp.\)\?str\)\?\s*".*[^\.!]")' | xargs sed s'/\(anomaly\s*\(~label:"[^"]*"\s*\)\?\(Pp.\)\?(\(\(Pp.\)\?str\)\?\s*".*\s*[^\.! ]\)\s*")/\1.")/g' -i ``` and ```bash git grep --name-only ' !"' | xargs sed s'/ !"/!"/g' -i ``` The rest were manually edited by looking at the results of ```bash git grep anomaly | grep '\.ml' | grep -v 'anomaly\s*\(~label:"[^"]*"\s*\)\?\(Pp\.\)\?(\(\(Pp.\)\?str\)\?\s*".*\(\.\|!\)")' | grep 'anomaly\($\|[^_]\)' | less ```
* Missing optimization when Kernel Term Sharing is disabled.Gravatar Pierre-Marie Pédrot2017-04-12
| | | | | We don't have to perfom in-place updates because we actually know that there is none on the stack. This should speed up UniMath.
* Optimizing array mapping in the kernel.Gravatar Pierre-Marie Pédrot2017-02-19
| | | | | | | | | | | | | | | | | We unroll the map operation by hand in two performance-critical cases so as not to call the generic array allocation function in OCaml, and allocate directly on the minor heap instead. The generic array function is slow because it needs to discriminate between float and non-float arrays. The unrolling replaces this by a simple increment to the minor heap pointer and moves from the stack. The quantity of unrolling was determined by experimental measures on various Coq developments. It looks like most of the maps are for small arrays of size lesser or equal to 4, so this is what is implemented here. We could probably extend it to an even bigger number, but that would result in ugly code. From what I've seen, virtually all maps are of size less than 16, so that we could probably be almost optimal by going up to 16 unrollings, but the code tradeoffs are not obvious. Maybe when we have PPX?
* Fast access environment in CClosure.Gravatar Pierre-Marie Pédrot2016-09-09
|
* closure.ml renamed into cClosure.ml (avoid clash with a compiler-libs module)Gravatar Pierre Letouzey2016-07-03
For the moment, there is a Closure module in compiler-libs/ocamloptcomp.cm(x)a