| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Print concise summaries instead of full commands for some of the most verbose
commands. For example, print
```
OCAMLC lambda/switch.cmo
```
instead of
```
./boot/ocamlrun ./boot/ocamlc -nostdlib -I ./boot -use-prims runtime/primitives -g -strict-sequence -principal -absname -w +a-4-9-40-41-42-44-45-48 -warn-error +a -bin-annot -strict-formats -I lambda -I utils -I parsing -I typing -I bytecomp -I file_formats -I lambda -I middle_end -I middle_end/closure -I middle_end/flambda -I middle_end/flambda/base_types -I asmcomp -I driver -I toplevel -I tools -c lambda/switch.ml
```
and
```
CC runtime/addrmap.b.o
```
instead of
```
gcc -c -O2 -fno-strict-aliasing -fwrapv -pthread -g -Wall -Werror -fno-common -fexcess-precision=standard -fno-tree-vrp -ffunction-sections -I./runtime -D_FILE_OFFSET_BITS=64 -DCAMLDLLIMPORT= -DIN_CAML_RUNTIME -o runtime/addrmap.b.o runtime/addrmap.c
```
The output is generated with the Make function `$(info ...)` to avoid shelling
out to `echo` each time, which can be expensive under Cygwin.
A variable `V` controls whether to use the new style. When `V=0` (the default),
it is used. If `V=1`, then the usual full output is used instead.
Co-authored-by: Nicolás Ojeda Bär <n.oje.bar@gmail.com>
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The debugger and toplevels let users install printers for their data types.
To make sure the provided printers have the right type, both the debugger and
the toplevel need to know the internal OCaml representation of
the expected types.
So far, both the debugger and the toplevels used to extract the expected
representatioons from topdirs.cmi which they were reading at runtime.
This creates problems (e.g. when the compiler has not yet been installed)
and yields not so easy to read code.
In this commit, the type of the printers are defined in strings as they
would be written in OCaml in topdirs.ml. These strings are parsed
at runtime and the corresponding typing declarations are added to the
environment.
|
| | |
|
| |
|
|
|
|
| |
Load_path.find{,_uncap} now invoke a hook before raising Not_found,
which provides a mechanism for automatically adding directories to the
Load_path if required.
|
| |
|
|
|
|
| |
Use the same configuration for boot/ocamlc regardless of the machine on
which the bootstrap is performed. Now set Config.in_boot_compiler to
true for boot/ocamlc.
|
| |
|
|
|
|
|
|
| |
/!\ Need bootstrap
+ Move Uid and Sig_component_kind to Shape
Co-authored-by: Thomas Refis <thomas.refis@gmail.com>
|
| | |
|
| |
|
|
|
|
| |
This commit simply moves code from Topeval (whose interface is shared
with the bytecode interpreter) to a new module Tophooks which is
specific to the native toplevel.
|
| |
|
|
|
|
|
| |
This PR introduces polling instructions (Ipoll Mach instructions) to guarantee that the mutator can always be interrupted (by signals or other asynchronous actions) in a finite amount of time.
Co-authored-by: Damien Doligez <damien.doligez@gmail.com>
Co-authored-by: Xavier Leroy <xavierleroy@users.noreply.github.com>
Co-authored-by: Mark Shinwell <mshinwell@gmail.com>
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#10404)
The analyzer is parameterized by an abstract domain and a transfer function.
For recursive handlers, it remembers the latest inferred abstract state
and uses it to start the next fixpoint iteration. This avoids behaviors
exponential in the nesting of recursive handlers, like we would have
if we started every iteration with bottom.
This exponential behavior was present in the old implementation of liveness
analysis. It is gone in the new implementation that just calls into
the generic analyzer.
|
| |\
| |
| | |
#6654, #9974: make include and with constraints aware of ghost components
|
| | |
| |
| |
| |
| |
| | |
Signatures contain ghost type items that depends on a core syntactic
item, the module "Signature_group" provides iterators that are aware
of this difference between syntactic and ghost items.
|
| |/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit refactors the types that make up type-checking errors to
maintain more structural information. Most significantly, we split
out the errors we get from unification, moregen, and type equality in
`Ctype` into three distinct exceptions, and retain the sorts of
information we keep during unification in the other two cases as well
(no more `Unify []`). We also maintain more information in
`Includecore` about mismatches of primitives, manifests, and private
objects and variants
This commit doesn't make a lot of changes to the user-visible error
messages yet, only what's necessary to support the type changes, but
it enables a forthcoming patch where we use this improvement to
produce more informative error messages.
This commit includes existing work by Mekhrubon Tuarev, who did all
the early development. I (Antal Spector-Zabusky) came and built the
layer of types on top.
|
| | |
|
| | |
|
| |\
| |
| | |
Cmm invariants
|
| | | |
|
| |/
|
|
|
|
|
|
|
|
| |
The availability analysis was introduced in 2017 as part of GPR #856,
as a first step towards generating DWARF debugging information.
This project (generating DWARF debug info) was stopped, but the analysis
is still here, even though its results are not used and it is not normally run
(except when the experimental -drunavail flag is given).
This is essentially dead code. This PR removes it.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit improves the error messages for ill-typed functor applications and inclusion between functor types. It does so by computing a diff between the expected and the provided types, and find an application that minimizes the error. The set of changes also paves the way for better diff for inclusion checks between signatures.
* Implement a generic and variadic Wagner–Fischer algorithm for computing locally optimal
paths.
* Compute a full error tree for module type inclusion and equality errors
* Improve the error message for module type equality
* Expand the error message at the module level by using a diffing algorithm to
analyze erroneous functor multi-applications or inclusions using Levenshtein distance.
Co-authored-by: Florian Angeletti <florian.angeletti@inria.fr>
Co-authored-by: octachron <octa@polychoron.fr>
|
| |
|
|
| |
This reverts commit 48d3301cbeb8c79c57c86b442e14f03322ab8f4e.
|
| |\
| |
| | |
Fix CI
|
| | | |
|
| |/ |
|
| |
|
|
| |
Introduce modules Topeval and Topcommon to share common code between the bytecode and native toplevel.
|
| | |
|
| |
|
|
|
|
| |
This follows from #10061 by renaming the library to further unify the two
toplevels.
Some remaining references to `Opttop*` have also been cleaned up.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This unifies both implementations of the toplevel under a common interface.
Similar Makefile hacks to those in place for dynlink are used: byte
and native implementations are in separate directories, while the
shared interface are in the parent and copied as needed by the build
rules.
This is a preliminary step to remove duplication as much as possible
in the two implementations, but should already be pretty useful for
libraries that use the `Toploop` interface.
|
| |
|
|
| |
import Local_store from merlin, with a simplified API following review comments
|
| |\
| |
| | |
The Spacetime memory profiler is not going to be supported in Multicore OCaml, and is already broken by some of the related changes in OCaml 4.12. The core development team decided to remove Spacetime support from OCaml 4.12.
|
| | | |
|
| |/
|
|
|
|
|
|
|
|
|
| |
* Save IR before emit
* Update .depend for linear_format
* Test for -save-ir-after command-line option
* Address review comments
* Add Changes entry
|
| |
|
|
|
| |
Depending on ocamlopt meant they were always rebuilt on Windows/Cygwin
builds.
|
| |\
| |
| | |
Implement (in utils/binutils.ml) a simple parser for ELF, Mach-O and PE shared object files. Use it to get rid of libbfd in ocamlobjinfo and to improve the checking of external primitives during linking in ocamlc.
|
| | | |
|
| |/ |
|
| |
|
|
|
|
|
|
| |
The aim is to also move the Simple/Half_simple/General stuff from
matching, but we need to split in those modules the part that are
purely structural (they go in Patterns) and the parts that are
actually compilation logic (Half_simple.of_clause), those stay in
Matching.
|
| |
|
|
|
|
|
|
|
| |
(This is a small, independent readability fix.)
ARCH_SPECIFIC was moved into Makefile.compilerlibs by mistake; it is
not used in Makefile.compilerlibs (in particular the
ARCH_SPECIFIC_ASMCOMP_* variables do not depend on it), and it is used
in the main Makefile.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Move driver code from Cmt2annot to Read_cmt
* Move cmt2annot.ml into typing/
* make depend
* Use standard error handling
* Move specific logic to read_cmt
* Do not pass full cmt record as argument
* Better locations
* Emit .annot files produced from cmt data
* Remove direct calls to Stypes
* Deprecate -annot
* Changes
* make depend
* Adapt doc
* make -C tools depend
|
| | |
|
| |
|
|
| |
(The typo was caught by make's undefined-variables warning on the INRIA CI)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before this commit, the Makefile for compilerlibs archives only tracks
their dependencies on implementation object files (.cmo,
.cmx). .mli-only files in those directories result in a .cmi without
a .cmo.
The main makefile uses dependencies on compilerlibs archives as
a proxy for all dependencies on the corresponding compiler
modules. This assumption was broken by .mli-only modules not being
dependencies on the archives.
For example, rebuilding compilerlibs archives would not refresh
file_format/cmxs_format.cmi. The following steps would lead to a build
failure:
make core
make ocamltools
<add a new blank line at the beginning of utils/misc.mli>
make ocamltools
File "/home/gasche/Prog/ocaml/github-trunk/tools/objinfo.ml", line 1:
Error: The files /home/gasche/Prog/ocaml/github-trunk/utils/misc.cmi
and /home/gasche/Prog/ocaml/github-trunk/file_formats/cmxs_format.cmi
make inconsistent assumptions over interface Misc
|
| |
|