Sebastian Ullrich
f0347ee719
chore: lean --stats gives number of imported bytes ( #8725 )
...
Thanks to `mmap`, startup time is not necessarily related to this
figure, but it can be used as a rough measure for that and how much data
the module depends on, i.e. the rebuild chance.
Also adds new cumulative benchmarks for this metric as well as the
number of imported constants and env ext entries.
2025-06-12 08:29:42 +00:00
Sebastian Ullrich
7feb583b9e
feat: enable experimental module system in Init ( #8047 )
2025-04-23 17:21:33 +00:00
Henrik Böving
ac738a8e81
perf: use mimalloc in compactor hashmaps ( #7929 )
...
This PR changes the compactor hashmap to use mimalloc which speeds up
olean serialization.
2025-04-14 09:11:34 +00:00
Sebastian Ullrich
69536808ca
feat: read/writeModuleDataParts API for serialization with cross-file sharing ( #7854 )
...
This PR introduces fundamental API to distribute module data across
multiple files in preparation for the module system.
2025-04-10 13:32:24 +00:00
Sebastian Ullrich
7c79f05cd4
feat: API to avoid deadlocks from dropped promises ( #6958 )
...
This PR improves the `Promise` API by considering how dropped promises
can lead to never-finished tasks.
2025-02-07 15:33:10 +00:00
Patrick Massot
ccac989dda
doc: expand an error message about compacting closures ( #3627 )
...
Provide a hint of where the error message may come from.
2024-03-07 20:02:23 +00:00
Mario Carneiro
bb8cc08de8
chore: compact objects in post-order
2023-06-26 08:35:19 -07:00
Leonardo de Moura
5e9ebf044a
fix: insert_mpz
2021-12-01 13:47:05 -08:00
Leonardo de Moura
92a5f8f18e
fix: insert_mpz
2021-12-01 13:38:20 -08:00
Leonardo de Moura
375de32bfb
fix: fix_mpz
2021-12-01 13:38:19 -08:00
Leonardo de Moura
9a81ae556a
feat: add support for USE_GMP=OFF at compact.cpp
2021-11-30 16:46:53 -08:00
Leonardo de Moura
0002d8bd04
chore: missing #ifdef LEAN_USE_GMP
2021-11-29 11:35:13 -08:00
Sebastian Ullrich
3a7fa704c3
refactor: avoid non-compiler headers in lean.h
2021-11-18 09:42:35 +01:00
Gabriel Ebner
ee2804d278
fix: use unsigned char in hash_str
...
char has different signedness on various architectures (signed on amd64,
unsigned on aarch64). oleans are then not architecture-independent
since they contain hashes (e.g. in mkStr).
2021-10-21 22:08:49 +02:00
Sebastian Ullrich
b13d3e6ca5
fix: dllexport functions not already annotated in header
2021-09-20 18:41:46 +02:00
Leonardo de Moura
c8406a301d
chore: reduce src/include/lean
2021-09-07 08:24:54 -07:00
Sebastian Ullrich
3c91c9e874
feat: try memory-mapping .olean files on Windows
2021-08-04 16:40:57 +02:00
Sebastian Ullrich
fbdcaab009
feat: show number of mmap-ed modules in --stats
2021-08-04 16:40:57 +02:00
Sebastian Ullrich
05abdf7848
perf: move root address of compacted region to the front
...
for true zero-cost loading
2021-08-04 16:40:57 +02:00
Sebastian Ullrich
4766ee0b5e
feat: try to mmap() .olean files on Linux & macOS
2021-08-04 16:40:57 +02:00
Sebastian Ullrich
4d8da44f50
feat: allow specifying virtual base address for compacted region
2021-08-04 16:40:57 +02:00
Sebastian Ullrich
e25edf893c
fix: mark MPZ objects in compacted regions as persistent
2021-07-27 16:35:42 +02:00
Sebastian Ullrich
450293e64a
feat: zero-copy GMP deserialization
2021-07-26 07:11:05 -07:00
Leonardo de Moura
51200c916e
chore: make explicit user and internal panics
2021-03-04 07:37:33 -08:00
Sebastian Ullrich
77cbaa752c
fix: Task: make reference and -j0 semantics eager, simplify
2020-09-14 17:57:33 +02:00
Sebastian Ullrich
c88784ef9d
refactor: consistent io_result_mk* naming
...
/cc @leodemoura
2020-08-31 11:08:57 +02:00
Leonardo de Moura
e3b1ae514b
fix: nontermination
...
This issue was reported by Simon Winwood at Zulip.
Here is the message
The following code doesn't terminate (in a reasonable amount of time)
```
def large_nat : Nat := (9223372036854775807 : Nat)
```
$ time lean --o=large-nat.olean large-nat.lean
2020-08-18 18:45:28 -07:00
Sebastian Ullrich
c38f4fe837
feat: unsafe functions for freeing compacted regions
2020-07-10 07:42:26 -07:00
Leonardo de Moura
2f1ec93289
chore: move runtime implementation to src/runtime
2020-05-22 14:35:16 -07:00
Leonardo de Moura
1a77ee4f89
chore: delete old runtime directory
2020-05-18 11:33:18 -07:00
Leonardo de Moura
8bdca35282
chore: use #include <lean/runtime/...> for runtime .h files
2020-05-18 11:30:07 -07:00
Leonardo de Moura
a897f7e7f3
chore: style nonsense
2020-02-06 17:06:36 -08:00
Leonardo de Moura
224fe05d51
feat: reset memory
2020-02-06 16:56:25 -08:00
Leonardo de Moura
469562d524
feat: maximize sharing at compact
2020-02-06 16:39:20 -08:00
Leonardo de Moura
9eef6851be
chore: track number of objects
2020-02-06 14:58:20 -08:00
Leonardo de Moura
a944d158a3
feat(CMakeLists.txt): add SMALL_RC cmake option
...
When used with `COMPRESSED_OBJECT_HEADER`, Lean uses a compressed
object header where only 32-bits are reserved for the RC.
The motivation is performance, in our experiments, it is faster to
access a 32-bit counter than a 45-bit one.
With a smaller RC, we can use 8-bits for the memory kind information,
and speedup its access.
2019-08-28 14:54:08 -03:00
Leonardo de Moura
88e44d9fdd
fix(runtime/compact): memory leak
2019-08-24 11:21:19 -07:00
Leonardo de Moura
140708fe8d
chore(runtime): style
2019-08-24 07:40:56 -07:00
Leonardo de Moura
70f3537a29
feat(runtime): add lean_panic and variants
2019-08-24 07:40:39 -07:00
Leonardo de Moura
6553c5531c
fix(runtime): bugs at compact.cpp and object size calculation
2019-08-24 07:40:38 -07:00
Leonardo de Moura
1ba481fad5
chore(runtime/compact): minor
2019-08-24 07:40:38 -07:00
Leonardo de Moura
79f4eeea62
fix(runtime/lean): incorrect assertion
2019-08-24 07:40:38 -07:00
Leonardo de Moura
dcd15f3424
refactor(runtime): C backend
2019-08-24 07:40:38 -07:00
Leonardo de Moura
b0c84874ba
chore(runtime/compact): add additional comments
2019-07-30 17:58:15 -07:00
Sebastian Ullrich
20b6502aaf
fix(runtime/compact): badly aligned "field" in terminator
2019-07-30 17:52:43 -07:00
Leonardo de Moura
30a6a2ade8
feat(library/init/data, runtime): remove parray support from runtime, and implement them in Lean using Scala/Clojure Radix trees
...
The Scala/Clojure approach for persistent arrays works great with our
`reset/reuse`. We seem to be much more efficient than their
implementations because of `reset/reuse`. The new approach also seems
better than the old one implemented in the runtime, and has a few
advantages:
1- The reroot procedure used in the old approach required
synchronization for multi-threaded code, or we would need to perform
deep copies when sending `parray` objects between threads.
2- We don't need any runtime extension for the new approach.
3- The old approach used "trail lists" for undoing array updates.
This works well for bactracking search use cases, but it is bad
in use cases where we are simultaneously updating the persistent
arrays that have shared nodes.
2019-06-02 09:18:19 -07:00
Leonardo de Moura
1da4782483
feat(runtime, library/init/io): add io.ref
2019-03-16 22:16:28 -07:00
Leonardo de Moura
4863ca071a
chore(runtime): make sure we use the same naming convention for getters and setters
2018-09-09 10:07:00 -07:00
Leonardo de Moura
8f195515a6
feat(runtime): add persistent arrays to runtime
2018-09-09 09:44:38 -07:00
Leonardo de Moura
4d6da3dd69
fix(runtime/compact): bug at read
2018-08-28 10:30:51 -07:00