Commit Graph

621 Commits (705054b3461a085981d746844dcd1c26efcdb154)

Author SHA1 Message Date
Mark Shinwell 7cb0da58f1
Don't generate Clambda constants during Cmmgen, etc. (#2280) 2019-03-05 17:09:40 +00:00
David Allsopp 8831395f32 Move FLEXDLL_DIR definition to utils/Makefile (#2259)
Missed in d68e0e207. Fixes second part of MPR#7923.
2019-02-28 11:21:52 +01:00
Mark Shinwell 3133699187
Add bytecomp/opcodes.mli (#2265) 2019-02-26 16:17:38 +00:00
Gabriel Scherer 93f0ce31bb env refactoring: separate the cmi/crc handling into a persistent_env module
Persistent_env is a new module that handles the relation between the
type-checking state and the "persistent" typing information laying in
.cmi files on the filesystem. In particular, it handles the collection
and production of CRC information for the .cmi files being read and
written to the filesystem; the using modules (in our case, only Env)
are in charge of turning the cmi files into higher-level information
(components and signatures).

Persistent_env exposes a type `'a t` of a persistent environment,
which acts as a mutable store of `'a` values. There is no global state
in the module itself: while Env (and thus the OCaml type-checker) uses
a single global persistent environment, it should be possible to
create several independent environments to represent, for example,
several independent type-checking sessions.
2019-02-18 17:02:47 +01:00
Pierre Chambart 45b28a90b2 Move Semantics_of_primitives into asmcomp 2019-02-11 17:16:44 +01:00
Pierre Chambart 6dfd40f72f Push clambda_primitives to flambda 2019-02-11 17:16:44 +01:00
Pierre Chambart db80c8e15f Define and use Clambda_primitives
The primites for Clambda are now different from lambda ones. This will
now allow to clean those that don't make any sense in the backend.
2019-02-11 17:16:43 +01:00
Vlad Frolov 925c7dcf20
[Makefile] Fixed a bug in partialclean target 2019-02-04 00:06:42 +02:00
Jeremie Dimino 7e0862a212 Refactor load path management and initial environment
- Add a Load_path module which caches files lookup

- Instead of falling back to the external environment, allow to
  declare in the environment that a module comes from the external
  world. This allows persistent structures to shadows non-persistent
  ones
2019-01-30 16:36:38 +00:00
Nicolás Ojeda Bär 9eda39597a Remove explicit dependencies 2019-01-12 20:50:36 +01:00
Nicolás Ojeda Bär 0998b3ac4e Remove unnecessary compilation rules 2019-01-12 08:59:34 +01:00
Nicolás Ojeda Bär fe617f638f Remove unnecessary ocamldep call 2019-01-12 08:57:12 +01:00
Nicolás Ojeda Bär 8cc9013688 Do not call ocamldep on non-existing files 2019-01-12 08:57:12 +01:00
Gabriel Scherer 46ef054330 Makefiles: restructure CAMLDEP usage to easily add flags
This change should be a refactoring no-op.

Before, a DEPFLAGS variable existed in some makefiles to contain
include directories to be passed to ocamldep invocations, but no
support for easily adding command-line flags to ocamldep was available
(invocations would systematically use -slash, which was duplicated
across callsites).

With this PR, a new DEPINCLUDES variable contains the include
directories, and DEPFLAGS is repurposed to contain other command-line
flags for the tool -- currently "slash".
2018-12-12 09:30:55 +01:00
David Allsopp a875e64571 Missing clean items from GPR#1063 2018-12-06 18:14:38 +00:00
Thomas Refis af328e176b
remove typedtreeMap (#2173) 2018-11-29 15:51:45 +01:00
Rodolphe Lepigre ca227428f4 Typedecl: split immediacy to a separate unit Typedecl_variance
get_unboxed_type_representation is used in several other modules, and
split into its own Typedecl_unboxed unit.

(pair-programming with Gabriel Scherer)
2018-11-23 12:05:33 +01:00
Gabriel Scherer 24ea989c02 Typedecl: split variance to a separate unit Typedecl_variance
(pair-programming with Rodolphe Lepigre)
2018-11-23 12:05:33 +01:00
Gabriel Scherer 0e0b10fd75 Typedecl: split abstract properties to a separate unit Typedecl_properties
(pair-programming with Rodolphe Lepigre)
2018-11-23 12:03:11 +01:00
Gabriel Scherer f6837be875
Merge pull request #2151 from fpottier/improvements
Parser improvements, with a possible bug fix along the way.
2018-11-22 08:23:58 +01:00
Thomas Refis 5daea80728 fix partialclean for compdynlink_common (review and approved by mshinwell) 2018-11-20 15:46:48 +00:00
Thomas Refis aa77d3b93d
fix dune build following natdynlink modifications (#2154)
- silence some principality warning in otherlibs/dynlink
- shared some script between the makefile and the dune files
2018-11-20 15:06:47 +01:00
François Pottier de8df5dbb0 Exclude `boot/menhir/parser.{ml,mli}` from the list of source files
used by `make build-all-asts` and related commands.

Indeed, the idea is to check that the ASTs do not change when the parser is
modified -- the parser's source itself, if included, would always produce a
false positive.
2018-11-20 11:52:47 +01:00
Mark Shinwell 690116890e Various Makefile / dependency fixes 2018-11-15 10:42:49 +00:00
Mark Shinwell 960cef2e7d Fix makefile problems 2018-11-14 16:20:06 +00:00
Mark Shinwell a4c88eab27 Fixing dynlink makefiles 2018-11-14 13:10:08 +00:00
Mark Shinwell 6526a0c3d9 Make (nat)dynlink sound 2018-11-12 17:44:26 +00:00
Gabriel Scherer d4959ae5ff Makefile: reuse new rules of otherlibs/Makefile 2018-11-12 16:28:01 +01:00
Gabriel Scherer cbefaee438 minor typo fix 2018-11-09 20:37:03 +01:00
Alain Frisch 7baf33d6ad
Fix PR6638: add dedicated wrning for "unused open!" (#1110) 2018-11-09 13:41:34 +01:00
alainfrisch 0d968e357b Move variable printer to Pprintast
- The code responsible for printing Syntaxerr errors is moved to the
  Parse module (so that it can depend on the variable printer in
  Pprintast).

- Pprintast becomes a dependency for a few tools that link some
  compiler modules in an ad hoc way (they would better be implemented
  in terms of compiler-libs).
2018-11-06 13:12:54 +01:00
Thomas Refis e292cb97c5 correctly register dependencies 2018-10-11 17:13:22 +01:00
Thomas Refis d68e0e2077
Provide a way to build the bytecode compiler using Dune (#2093) 2018-10-10 16:16:00 +01:00
Mark Shinwell 2b5f13c913 GPR#2056 (Backend_var) 2018-09-28 17:59:01 +02:00
Sébastien Hinderer 132b3a151d
Get rid of the standard_runtime configuration variable (#2066)
This configuration variable was formerly used by the -make_runtime and
-use_runtime option but this is no longer the case.
2018-09-25 15:29:18 +02:00
Sébastien Hinderer ba6362a07d Move config/Makefile to Makefile.config
In order to prepare the transition to autoconf, this commit moves the
configuration Makefile out of the config directory which will disappear
and gives it the name it will have once intstalled, namely Makefile.config.
2018-09-17 14:23:35 +02:00
David Allsopp 6fab940f38 Export SUPPORTS_SHARED_LIBRARIES in ocamlc -config 2018-09-13 13:40:17 +01:00
Gabriel Scherer ef00dc7317 remove experimental/
This subdirectory was used to store experimental patches on some older
version-control system where branching (or discussing branches?) was
inconvenient. It doesn't make much sense anymore now, and getting rid
of it simplifies a couple places that had to grow around it.

Suggested-by: Nicolás Ojeda Bär

(no change entry needed)
2018-09-08 16:53:08 +02:00
Gabriel Scherer e024eeecd8 Makefile rules to test parser changes by comparing -dparsetree output 2018-09-08 12:24:29 +02:00
David Allsopp b069f692b4 Remove space from end of FLEXLINK_ENV 2018-09-07 08:34:53 +02:00
David Allsopp ad07b6d9b5 Use $(addprefix ...) and spacing adjustments 2018-09-07 08:34:53 +02:00
David Allsopp 4756a576f0 Move FLEXLINK_ENV definition to Makefile.common 2018-09-07 08:34:53 +02:00
David Allsopp 171a97407d Harden flexlink.opt target
If an error occurs while making flexlink.opt, the bytecode image was not
restored. It's now restored even if an error occurs while building the
native code image.
2018-09-07 08:34:53 +02:00
David Allsopp c13c200f87 Standardise setting and use of OCAML_FLEXLINK
Some Makefiles were using export to set OCAML_FLEXLINK "globally" while
others set a variable FLEXLINK_ENV and set the environment explicitly.

All Makefiles now use FLEXLINK_ENV and also only invoke it on linking
commands (rather than, for example, all invocations of ocamlopt).
2018-09-07 08:34:53 +02:00
Gabriel Scherer 9e84a038cb Makefile: make the parser.mly timestamp heuristic more robust
Reviewed by Sébastien Hinderer.

(no change entry needed)
2018-09-06 12:17:17 +02:00
Gabriel Scherer 51912516fa [minor] documentation improvements for Makefile.menhir 2018-09-06 11:10:48 +02:00
octachron 075bf9bed6 doc: remove unprefix trick 2018-09-03 13:59:32 +01:00
Gabriel Scherer a0d2aeb7e1 Menhir update test: use POSIX (find .. -prune -newer) instead of bash's -nt 2018-09-02 12:04:05 +02:00
Gabriel Scherer cbb92d2817 remove unused ocamlyacc dependencies, never put it in boot/ 2018-09-01 23:17:06 +02:00
Gabriel Scherer ac265e9ea3 (minor) remove unused CAMLYACC variables 2018-09-01 23:17:06 +02:00