Commit Graph

20944 Commits (547f9b8126fbb558de184a3424b0fc22a3d57f27)

Author SHA1 Message Date
Jacques-Henri Jourdan 18c0f95560 Memprof : Refactor [run_callback_exn] so that it also stores the value returned by the callback. 2020-10-19 17:00:04 +02:00
Jacques-Henri Jourdan ea52bec84b Memprof: thread-local context is now stored as a pointer in systhread's data structures.
Reasons:
- Better abstraction in memprof.h
- Simpler Saving/restore functions
- We introduce a current's thread context, so that we don't need to do a spacial case for the current thread
2020-10-19 17:00:04 +02:00
Jacques-Henri Jourdan 13a874cf3f Memprof : get rid of the tracking_state struct, and create an entry_array struct, which only contains information specific to the array. 2020-10-19 16:41:13 +02:00
Jacques-Henri Jourdan 11411635bc Memprof: refactor realloc_trackst. 2020-10-19 16:41:13 +02:00
Jacques-Henri Jourdan d1800821df Gc.Memprof.stop does no longer try to run pending callbacks.
This is only effetive in native mode, since function calls in bytecode
mode will trigger polling and hence run pending callbacks.
2020-10-19 16:41:13 +02:00
Jacques-Henri Jourdan b371c21396 Memprof: fix rounding error. 2020-10-19 16:41:13 +02:00
Jacques-Henri Jourdan cad494b399 Whitespace, typos. 2020-10-19 16:36:23 +02:00
Florian Angeletti af2096729b release info update 2020-10-19 16:20:18 +02:00
Florian Angeletti 21c33a53cd first commit after branching 4.12 2020-10-19 16:19:49 +02:00
Florian Angeletti 24dbb0976a last commit before branching 4.12 2020-10-19 16:08:29 +02:00
Florian Angeletti 55973d1203 Bump magic numbers for 4.12 (and trunk) 2020-10-19 15:33:26 +02:00
Florian Angeletti 7acf73f2b0
Merge pull request #9980 from xavierleroy/ocamlopt-doc
Ocamlopt documentation updates
2020-10-19 14:38:20 +02:00
Xavier Leroy be02a26305 Revise explanation of -nodynlink 2020-10-19 12:00:01 +02:00
Stephen Dolan 9b3931a156
Ensure Mtype.nondep_sig checks use the correct environment (#9946) 2020-10-19 10:40:25 +01:00
jacobly0 8a46d76bf9
Fix mergeable section flags and use .rodata.cst16 where appropriate (#9981)
On x86-64 ELF, the `.rodata.cst8` section was incorrectly used.
2020-10-18 13:57:53 +02:00
David Allsopp 64f6f83f44
Update HACKING.adoc (#9966)
Clarify why basing topic branches on release tags is bad.
Documented the configure options implied by dev-mode.
2020-10-18 07:59:56 +01:00
David Allsopp 36faf1a2a6
Merge pull request #9967 from dra27/configurable-opt
Add (developer) ability to disable the use of the .opt compilers in the build
2020-10-18 07:57:23 +01:00
Xavier Leroy a9f1f9ee1b
Update manual/manual/cmds/native.etex
Co-authored-by: Vincent Laviron <vincent.laviron@gmail.com>
2020-10-16 10:28:32 +02:00
Xavier Leroy e7d2c394c0 Modernize the description of target-specific ocamlopt aspects
No more "Intel Pentium" and "AMD Athlon".
2020-10-16 10:12:30 +02:00
Xavier Leroy 0fac4b030b Explain -nodynlink better
Including interactions with PIE.

Closes: #8867
2020-10-16 09:55:22 +02:00
Xavier Leroy 8b7ff3532c
Move the examples of labeled functions to StdLabels (#9976)
In the old days, the interfaces of the labeled modules
(ArrayLabels, BytesLabels, ListLabels, StringLabels)
started with short examples of labelings.

Now, the interfaces of the non-labeled modules
(Array, Bytes, List, String) are automatically generated
from the interfaces of the labeled modules.  As a side effect,
the interfaces of Array, Bytes, List and String also start
with short examples of labelings, which is somewhat strange.

This commit reorganizes the documentation as follows:
- The documentation of the StdLabels module is expanded, and includes
  the examples of labeled functions previously scattered in
  ArrayLabels, BytesLabels, ListLabels, StringLabels.
- Array, Bytes, List, String and their labeled counterparts
  briefly mention the labeled modules and point to StdLabels,
  but no longer contain examples.
2020-10-15 15:07:31 +02:00
Thomas Refis 9fdc759ac0
Centralized tracking of frontend's global state (#9963)
import Local_store from merlin, with a simplified API following review comments
2020-10-15 14:47:19 +02:00
Greta Yorsh 5410d0c5d3
Fix example of external C function in the manual (#9977) 2020-10-14 16:31:33 +02:00
Thomas Refis efac790249
Make some locations more accurate (#8987) 2020-10-14 16:03:10 +02:00
Florian Angeletti 5e15dd8eb5
Merge pull request #9861 from trefis/9858
Catch Nondep_cannot_erase
2020-10-13 16:31:34 +02:00
Greta Yorsh 855c13cd6e
ability to restart compilation from .cmir-linear IR files 2020-10-13 15:07:13 +02:00
Nicolás Ojeda Bär 246564e8db
Remove dead code (#9974) 2020-10-13 09:48:16 +02:00
Xavier Leroy 426b10c6a8
Provide semaphores in the threading library (#9930)
This commit adds a new thread-related module Semaphore, implementing
counting semaphores and binary semaphores.

The two kinds of semaphores are presented as two different
abstract types in two sub-modules, Counting and Binary.
2020-10-12 19:09:52 +02:00
Xavier Leroy f809e9dec1
Make sure the process can terminate when the last thread calls Thread.exit (#9973)
To this end, the tick thread must be stopped, otherwise it prevents
the whole process from exiting.

Fixes: #9971
2020-10-12 15:24:40 +02:00
Mehdi Bouaziz 6ab6052e15
[hashtbl] Restore ongoing traversal status after filter_map_inplace (#8746) 2020-10-12 15:12:09 +02:00
Gabriel Scherer 0cec3a353b
Merge pull request #9803 from trefis/pr9799
pat_env points to the correct environment
2020-10-12 11:00:52 +02:00
Gabriel Scherer 82b29828d2
Allow `[@tailcall true]` and `[@tailcall false]` (#9754)
* remove the unused is_native_tail_call_heuristic forward reference

This forward-reference from Lambda to Asmcomp was used to generate
machine-specific tailcall information in -annot output; this only use
was removed in 57d329e07b, so we can now
remove it to simplify the codebase.

The logic was non-trivial and might be useful again in the future.

* [minor] testsuite: convert warnings/w51.ml to an expect-test

* [minor] translattribute: refactor attribute payload deconstruction

* [@tailcall false]: warn if the call *is* a tailcall

(+ constructor renaming suggested by Nicolás during review)

* Changes

* testsuite: add an example with the 'invalid payload' exception

(suggested by Nicolás during review)
2020-10-10 13:41:39 +02:00
Xavier Leroy d910c35301 Add a test for --enable-reserved-header-bits 2020-10-09 14:51:00 +02:00
Xavier Leroy 53ed75072d configure --enable-reserved-header-bits=N: fix range of accepted N
It ranges between 0 and 31, not 0 and 21.
2020-10-09 14:50:13 +02:00
Xavier Leroy 86c8a98f3c
Merge pull request #9948 from nojb/remove_spacetime
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.
2020-10-09 14:43:23 +02:00
Damien Doligez 0069123c61
clean up and fix GC message 0x1 (#9949) 2020-10-09 12:02:00 +02:00
Nicolás Ojeda Bär 8420c3ea9f Bootstrap 2020-10-08 20:28:15 +02:00
Nicolás Ojeda Bär 7e4392a39e Changes 2020-10-08 20:28:15 +02:00
Nicolás Ojeda Bär 899a2013aa Adapt tests 2020-10-08 20:28:15 +02:00
Nicolás Ojeda Bär 43883ae4bc Remove labels after calls, checkbound, and GC points 2020-10-08 20:28:15 +02:00
Nicolás Ojeda Bär 67c9c0772e Remove Spacetime support in marshaller 2020-10-08 20:28:15 +02:00
Nicolás Ojeda Bär 3869f71e98 Remove Cblockheader 2020-10-08 20:28:15 +02:00
Nicolás Ojeda Bär 540996d21e Remove Spacetime 2020-10-08 20:28:12 +02:00
David Allsopp 0e6bc29b2b
Use CAMLprim in all manual examples (#9898) 2020-10-07 16:37:37 +02:00
Thomas Refis 66e5cd11f2 Changes 2020-10-07 15:54:23 +02:00
Thomas Refis c7f9c8e559 pat_env: I must not tell lies 2020-10-07 15:54:23 +02:00
Thomas Refis b938cb32c5 add test from PR#9799 2020-10-07 15:54:23 +02:00
Greta Yorsh 04bceec6cc
Save Linear IR before emit (#8939)
* Save IR before emit

* Update .depend for linear_format

* Test for -save-ir-after command-line option

* Address review comments

* Add Changes entry
2020-10-07 11:32:40 +01:00
Vincent Laviron eb342da8a9
Ensure all structured constants are registered (#9940)
Allocated constants from other compilation units were not registered, resulting in missed opportunities for unboxing FP and boxed-integer constants.
2020-10-06 15:19:51 +02:00
Leo White 952281944d
Merge pull request #9429 from lpw25/more-hash-operators
Add ppx-only unary operators
2020-10-06 07:46:35 +01:00