Bennet Bleßmann
6b50ec328c
move the creation of the LIBRARIES IndexMap out of the generated file
...
- only leave the filling of the map in the generated code
2024-07-25 18:53:36 +02:00
Bennet Bleßmann
1eb6a883f6
run rustfmt
2024-07-23 00:01:58 +02:00
Bennet Bleßmann
e7fd408548
use include_str! for the build in libraries
...
instead of "copy-paste-ing" the prolog source into rust string literals in the generated files
2024-07-23 00:01:29 +02:00
Mark Thom
eaa95293e4
Merge pull request #2439 from Skgland/miri
...
Some cleanup and miri fixes
2024-07-22 13:40:57 -06:00
Mark Thom
8ac663d703
Merge pull request #2442 from aarroyoc/fix-http-at-end-of-stream
...
Fix at_end_of_stream/1 for http read stream
2024-07-07 16:02:51 -06:00
Mark Thom
902712695c
Merge pull request #2440 from triska/statistics
...
ADDED: Preliminary support for statistics/2.
2024-07-07 15:59:44 -06:00
Bennet Bleßmann
5d03be4b09
fix leak of slaps with dropped payload
2024-07-07 19:22:46 +02:00
Bennet Bleßmann
689632b51c
cleanup the slab types
...
- get rid of HeaderOrIdxPtr
- add IndexPtrSlab
- add UntypedArenaSlab
- add to_untyped for converting a typed slab into an unsyped slab
- remove TypedArenaPtr::new, as they shouldn't be created outside of this module
2024-07-07 17:12:52 +02:00
Bennet Bleßmann
1b19ae81d5
wrap Payloads that are dropped eraly in ManuallyDrop
2024-07-07 15:58:31 +02:00
Bennet Bleßmann
a0d790445d
check that we don't attempt to un-drop while evacuating
2024-07-07 14:37:41 +02:00
Bennet Bleßmann
213ee5ca45
add AllocateInArena as a Pivot for arena_alloc!
...
so that the value type passed to `arena_alloc!` can differ from the `ArenaAllocated::Payload` type
2024-07-07 14:36:53 +02:00
Bennet Bleßmann
74720d4d2e
remove unsafe impl From<UntypedArenaPtr> for CodeIndex
2024-07-07 14:18:50 +02:00
Skgland
39bd520542
ignore pstr_iter_tests test in miri as it takes too long
2024-07-07 13:22:49 +02:00
Bennet Bleßmann
496e4e9f56
fix clippy again
2024-07-07 11:31:36 +02:00
Bennet Bleßmann
89c1ea4232
fix leak of ArenaAllocated IndexPtr
2024-07-07 11:30:56 +02:00
Bennet Bleßmann
a2a50586aa
replace static Once and two mut statics with one static OnceLock
2024-07-07 11:30:56 +02:00
Bennet Bleßmann
0284a2092d
reduce span of unsafe block
2024-07-07 11:30:37 +02:00
Bennet Bleßmann
c414f75329
switch macos to latest as macos-11 has been removed
...
See https://github.com/actions/runner-images/issues/9255
2024-07-06 18:47:35 +02:00
Bennet Bleßmann
943dce566b
fix clippy
2024-07-06 18:26:34 +02:00
Bennet Bleßmann
b32498b37c
adjust ignore reason
2024-07-06 18:24:38 +02:00
Bennet Bleßmann
ea041a40f9
if UB un IndexPtr ArenaAllocated impl
2024-07-06 17:43:13 +02:00
Bennet Bleßmann
1d66f91a41
replace ref_thread_local::ref_thread_local! with std::thread_local!
...
removes `ref_thread_local` which was still at 0.0.0 released October 2018 while latest 0.1.1 was released mid November 2021
fixes libraries.rs UB
2024-07-06 17:18:26 +02:00
Bennet Bleßmann
fee7ba58b0
fix stack alignement
...
- adjust align() in RawBlockTraits impl for Stack
- ensure ptr is always aligned in RawBlock::allock
2024-07-06 16:21:59 +02:00
Bennet Bleßmann
8e53d12776
make components a comma seperated string instead of a list
2024-07-06 16:01:52 +02:00
Adrián Arroyo Calle
08a9f7c068
Fix at_end_of_stream/1 for http read stream
2024-07-06 16:00:50 +02:00
Bennet Bleßmann
33793193cc
add miri to CI
2024-07-06 15:46:04 +02:00
Bennet Bleßmann
285f11ccdc
add associated Payload type to ArenaAllocated
2024-07-06 15:37:08 +02:00
Bennet Bleßmann
d87400afa0
switch Rcu to the arcu crate
...
The arcu crate is a more general implementation of the Rcu I implemented in here in scryer. It contains some bug-fixes regarding race-conditions in the Rcu update function, which could cause leaks and uses after free.
Source of the problem was the Relaxed load/strore/update of the reference count in side the Arc not being properly ordered with other load/stores.
2024-07-06 14:49:19 +02:00
Bennet Bleßmann
fcb41542c3
fix stream.rs UB
2024-07-06 14:30:03 +02:00
Bennet Bleßmann
87b4c9d736
somehow this was never marked as bad
2024-07-06 14:30:03 +02:00
Bennet Bleßmann
6386e70584
clippy: change ToString impl to Display
...
- write directly to formatter, eliminating intermediate String allocations
- take Value by reference eliminating clones
- remove trim() called on the result of QueryResolution::to_string
- we only emit "true", "false", or "[<resolutions>]"
neither of which contains trailing or leading withespace,
so the calls was effectively a noop
2024-07-06 13:32:58 +02:00
Bennet Bleßmann
722975d77e
clippy: use type associated constants
2024-07-06 13:08:59 +02:00
Bennet Bleßmann
8943962704
clippy: ptr dereference in safe function
2024-07-06 13:07:26 +02:00
Bennet Bleßmann
ed57ef3d01
clippy: identity conversion
2024-07-06 13:06:50 +02:00
Bennet Bleßmann
9e7d41025a
fix saftey comment
2024-07-06 13:06:24 +02:00
Bennet Bleßmann
d2f236d116
clippy: explicit ptr addrs comparision
...
relevant for wide pointers i.e. pointers with metadata
2024-07-06 13:06:13 +02:00
Bennet Bleßmann
1ff995fedb
clippy: allow new without default
2024-07-06 13:04:55 +02:00
Bennet Bleßmann
1b16c6c73f
clippy: use clone_from rather than clone
2024-07-06 13:03:14 +02:00
Bennet Bleßmann
ceac9c9095
clippy: ignore unused fields on PrologBenchmark struct
2024-07-06 13:01:19 +02:00
Markus Triska
0005dcaacb
ADDED: Preliminary support for statistics/2.
...
This is needed for benchmarking library(reif) and its newly provided
goal expansion (#2433 ).
It partly addresses #321 .
2024-07-06 11:33:02 +02:00
Bennet Bleßmann
467a82fe46
run rustfmt
2024-07-06 04:18:02 +02:00
Bennet Bleßmann
ce40f8f10c
update ignore reason
2024-07-06 04:15:30 +02:00
Bennet Bleßmann
d2d451b182
adjust the generation of the LIBRARIES map
...
pre-genrate constants instaed of driectly genrating the literal for the insert
2024-07-06 03:53:22 +02:00
Bennet Bleßmann
52fa51853e
don't use env::current_dir() in miri
2024-07-06 03:53:22 +02:00
Bennet Bleßmann
6575b1b573
fix some more miri errors
...
probably relevant to mthom/scryer-prolog#2438
2024-07-06 03:52:46 +02:00
Bennet Bleßmann
cba81b4dc7
some test pass miri
2024-07-06 02:43:00 +02:00
Bennet Bleßmann
91253917b4
remove rust_beta_channel feature
...
- the msrv (i.e. rust-version in Cargo.toml) is high enough that all gated code can now be used on stabe
2024-07-06 02:24:26 +02:00
Bennet Bleßmann
821358c062
unify pointer width
2024-07-06 01:49:25 +02:00
Bennet Bleßmann
3de0a4e2ad
replace transmut with pointer cast calls
2024-07-06 01:38:13 +02:00
Bennet Bleßmann
b8a3067744
resolve miri error for pstr_iter_tests in atom_table
...
relevant to mthom/scryer-prolog#2438
2024-07-06 01:21:03 +02:00