daan
9a33f23b5f
fix MI_SHOW_ERRORS on msvc
2020-04-28 11:11:23 -07:00
Daan
07e80aebb7
Merge branch 'dev' into xmalloc
2020-04-28 10:53:34 -07:00
Daan
9ba16f2df9
Merge pull request #232 from asl/cmake-err-warn-default
...
Add cmake option to specify whether warnings / errors are enabled by default
2020-04-28 10:51:30 -07:00
Anton Korobeynikov
079b886feb
Add cmake option to specify whether warnings / errors are enabled by default.
...
Currently warnings / errors are enabled by default in debug build.
Otherwise they could be enabled only via environmental variable or
API option call. Add possibility to specify the default during the
build time. This simplifies e.g. integration of the library into
bigger projects as no source changes would be required.
2020-04-28 16:44:44 +03:00
Anton Korobeynikov
2f1fc1df5c
Add xmalloc()-like functionality.
...
xmalloc is a non-standard extension forcing malloc() to
abort should the memory allocation failed instead of returning a
null pointer. Such functionality is quite useful as it provides one
single point of error handling if the caller of malloc() does not
check the result (as it often does!) and segfault is ocurring somewhere
else. If more fine-grained control is necessary one could register a custom
error handler, however, this might not be an option while interposing.
2020-04-28 16:38:47 +03:00
Daan Leijen
798cd6647d
use line-buffered output for statistics (issue #235
2020-04-24 07:43:21 -07:00
daan
1f396e64a0
merge from dev
2020-03-16 16:41:21 -07:00
daan
07fbe4f80f
fixes for dragonfly
2020-02-02 14:31:28 -08:00
daan
bb64634e4e
Merge branch 'dev-exp' into dev-exp-tls
2020-02-01 17:48:57 -08:00
daan
3f17ac287c
add 'nodiscard' attribute to mimalloc interface
2020-02-01 17:29:30 -08:00
daan
a169cf0e3f
merge dev-exp; add pthread TLS support for macOSX
2020-02-01 14:10:10 -08:00
daan
724602b78b
enable page-reset by default
2020-01-31 17:27:45 -08:00
daan
4531367de2
fix padding check for aligned allocation; improve perf for small aligned allocations
2020-01-31 13:20:02 -08:00
daan
03b363a1c2
first working tls on macOS using interpose; still slow
2020-01-29 22:46:44 -08:00
daan
7ff3ec2bf7
use EFAULT for buffer overflow and call abort in debug mode (as well as secure mode)
2020-01-29 17:25:40 -08:00
daan
b50bec463d
merge from dev-exp; better abandoned reclamation
2020-01-27 22:12:23 -08:00
daan
e070eba112
fix tagged null encoding, search segment cache before reclaim
2020-01-24 16:31:18 -08:00
daan
58fdcbb0cd
fix bug in collect where has_page was not set on free pages
2020-01-23 21:37:14 -08:00
daan
e226ebcc97
Merge branch 'dev' into dev-arena
2020-01-22 20:39:33 -08:00
daan
e3b16fe4ef
reduce type casts in atomic operations
2020-01-22 19:44:54 -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
dc58388968
Add ability to register custom error function called on various error conditions; including ENOMEM
2020-01-17 19:59:55 -08:00
daan
8d8f355ed0
add option to reset eagerly when a segment is abandoned
2020-01-16 11:25:02 -08:00
daan
9629d73188
fix options
2020-01-15 18:07:29 -08:00
daan
7a1e86fc20
merge from dev
2020-01-15 18:03:37 -08:00
daan
c9b5ac80b3
update page reset queue to just do delayed page resets
2020-01-15 12:00:44 -08:00
daan
783e3377f7
add output argument to stat printing
2020-01-15 10:53:54 -08:00
daan
f92a2a7264
add argument pointer to the register output routine
2020-01-15 10:18:32 -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
2808c9f4c8
default to non-eager commit
2020-01-13 18:01:52 -08:00
daan
4a27ea1643
merge from dev
2020-01-13 18:01:34 -08:00
daan
36d168a2d9
add preload check to options initialization
2019-12-01 00:03:35 -08:00
daan
b5fbdb7180
merge from dev
2019-11-25 11:16:39 -08:00
daan
1d998af854
clean up options; make secure work with eager_page_commit
2019-11-25 10:47:17 -08:00
daan
c6df7a199c
experimental eager page commit option
2019-11-24 22:02:40 -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
128cdd1dfb
merge from dev
2019-11-24 18:51:09 -08:00
daan
4a0d35afd0
improve secure guard page allocation to work with non-eager commit
2019-11-23 11:59:19 -08:00
daan
7da00c1220
wip: full decommit delay, for arena cache as well
2019-11-21 20:57:32 -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 Leijen
211f1aa519
remove reset delay slots; add reset tracking per page and segment
2019-11-20 14:55:12 -08:00
Daan Leijen
30e2c54adb
remove delayed reset option (for now)
2019-11-20 14:13:02 -08:00
Daan Leijen
d01ed42bcb
replace max_numa_nodes by use_numa_nodes (to help with wrong detection of numa nodes on WSL for example)
2019-11-13 13:35:50 -08:00
Daan Leijen
bdb8274819
change max_numa_node to max_numa_nodes option
2019-11-12 12:04:43 -08:00
daan
165ee45845
initialize delay slots for the main thread
2019-11-11 17:31:48 -08:00
daan
a0958b2da6
enable more reset delay slots
2019-11-11 17:06:16 -08:00
daan
741a80256d
merge from dev-exp
2019-11-11 14:51:16 -08:00