daan
a46d20a681
merge with new atomic macros
2020-01-22 20:53:44 -08:00
Daan Leijen
caa5e51a67
align size of page_t, increase slices per segment
2020-01-22 11:29:32 -08:00
daan
0028272cf4
small fixes, reduced segment size, fix merge conflicts
2020-01-20 22:33:29 -08:00
daan
394a7a92ab
merge from dev
2020-01-20 19:06:08 -08:00
daan
7a1e86fc20
merge from dev
2020-01-15 18:03:37 -08:00
daan
0099707af9
use delayed free for all pages; reduce size of the page structure for improved address calculation
2020-01-15 17:19:01 -08:00
daan
c9b5ac80b3
update page reset queue to just do delayed page resets
2020-01-15 12:00:44 -08:00
daan
941c55ee42
wip: first implementation of page free list on segments for effecient delayed page reset
2020-01-14 21:47:18 -08:00
daan
88b141cf1f
ensure proper padding for the page structure
2020-01-13 20:48:37 -08:00
daan
4a27ea1643
merge from dev
2020-01-13 18:01:34 -08:00
daan
683d8998d4
fix potential A-B-A problem with segment abandonment; noticed by Manual Poeter and Sam Gross
2020-01-08 17:45:38 -08:00
daan
eeb623e6af
increase retire limit, collect retired pages
2020-01-03 17:06:41 -08:00
daan
f9ca88f71c
set secure default to 0 again
2020-01-02 17:57:41 -08:00
daan
fc3e537bd4
improve double free detection with faster same page check
2019-12-28 15:28:13 -08:00
daan
e3391d9a53
stronger encoding of free lists using two keys per page
2019-12-28 00:57:42 -08:00
daan
ba87a39d9f
updated random cookie generation using OS primitives and chacha20
2019-12-22 19:37:49 -08:00
daan
41af533a34
define commit unit in terms of segment size
2019-11-24 19:17:56 -08:00
daan
ec0005b919
more fine grained commit tracking per MiB
2019-11-24 19:09:15 -08:00
daan
321e18777e
wip: delayed decommit on segments
2019-11-21 19:53:43 -08:00
daan
1066be1594
merge from dev-exp
2019-11-21 17:03:30 -08:00
daan
50575b12c0
Merge branch 'dev' into dev-exp
2019-11-21 16:29:59 -08:00
daan
41caf6d0f8
set secure default to 0
2019-11-21 16:29:46 -08:00
daan
6568059cc6
merge from dev
2019-11-21 16:28:28 -08:00
daan
74dbfc30be
improved security by encoding NULL values; double free mitigation on by default; more precise free list corruption detection
2019-11-21 15:21:23 -08:00
Daan Leijen
211f1aa519
remove reset delay slots; add reset tracking per page and segment
2019-11-20 14:55:12 -08:00
daan
a0958b2da6
enable more reset delay slots
2019-11-11 17:06:16 -08:00
daan
181bef382c
merge dev-exp
2019-11-10 11:39:53 -08:00
Daan Leijen
b04206a9d3
add os cache to arena
2019-11-10 10:10:10 -08:00
Daan Leijen
fed0068dac
merge from dev-exp; bitmap based arena
2019-11-10 07:56:40 -08:00
daan
27f1a8b3d2
fix avg display; set secure default to 0`
2019-11-07 10:35:30 -08:00
daan
36090dee5c
Merge branch 'dev' into dev-exp
2019-11-07 10:34:06 -08:00
daan
31d11f64d5
fix secure free list extension where a non-empty initial free list was discarded
2019-11-07 10:33:45 -08:00
daan
378716c467
refactor and improve atomic bitmap usage
2019-11-07 10:26:52 -08:00
daan
829fd872f4
initial delay slots
2019-11-04 11:48:41 -08:00
daan
e0b8ec7f54
merge with dev-exp
2019-11-02 11:56:19 -07:00
daan
fd9d8c85ae
change numa support on linux to use getcpu
2019-11-02 11:55:03 -07:00
daan
08c4726043
merge from dev-exp
2019-11-01 22:04:20 -07:00
daan
2c12d7f223
optimized numa calls; better Linux support
2019-11-01 22:01:52 -07:00
daan
f7d2c45af3
initial experiment with fixed memory arena and sliced segments
2019-10-31 00:40:41 -07:00
daan
c7ec30ae25
fix secure mode
2019-10-30 15:36:13 -07:00
daan
b73beede34
merge from dev
2019-10-30 15:19:34 -07:00
daan
b052d3b731
enable double free and heap corruption detection in debug mode
2019-10-28 15:54:33 -07:00
daan
081e2d1eb6
fix statistics display
2019-10-28 13:43:42 -07:00
daan
9d4f57abf3
merge from dev-win
2019-10-28 12:33:01 -07:00
daan
2affdbbd2e
stronger secure mode when defining MI_SECURE=4: checks for double free, corrupted free list, and invalid pointer frees. Performance is impacted but not too much -- more perf testing is needed
2019-10-18 18:11:04 -07:00
daan
4b15e2ed97
merge from dev
2019-10-17 18:24:35 -07:00
daan
5de851a84d
update page_flags to have more portable definition
2019-10-17 16:48:16 -07:00
daan
26c27fbf58
use uint8_t bit fields, and improve portability of page_flags type
2019-10-17 12:07:26 -07:00
Johannes Schindelin
559688ec64
Suppress warning about unnamed struct
...
This prevents MSVC complaining with
warning C4201: nonstandard extension used: nameless struct/union
The struct might seem unnecessary to the occasional reader (it did seem
so to this commit's author), but it is not! It is required to align the
fields to a boundary, which is verified by the test suite. Removing that
"unnecessary" `struct` results in this failure:
1: Test command: mimalloc-test-api
[...]
1: test: malloc-zero... mimalloc: assertion failed: at src/page.c:591, mi_page_init
1: assertion: "!mi_page_has_aligned(page)"
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2019-10-17 20:43:18 +02:00
Johannes Schindelin
e747a6f3a6
Use unsigned
for bit-field variables
...
It is actually non-standard to use `bool` with a bit-field quantifier,
and VS 2019 complains about this.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
2019-10-17 20:43:18 +02:00