Commit Graph

686 Commits

Author SHA1 Message Date
daan
ec2a8f387b strengthen alignment check to be void* aligned 2019-06-27 13:27:53 -07:00
daan
b3ce61c408 fix atomic statistics counter increase 2019-06-25 20:05:43 -07:00
daan
654bcd7049 Merge branch 'master' into dev 2019-06-25 19:57:45 -07:00
Daan
1713c37f9d
Merge pull request #28 from jserv/gcc-visibility
Avoid unnecessary symbol exposure with ELF-based systems
2019-06-25 19:54:28 -07:00
daan
cae02b4676 Merge branch 'master' into dev 2019-06-25 19:45:59 -07:00
Jim Huang
47e822c70f Correct the use of MI_DEBUG by conditional build
MI_DEBUG is a macro rather than a variable.
2019-06-25 21:59:20 +08:00
Frank Denis
59a714725b Read-only strings should be const char * 2019-06-25 12:19:36 +02:00
Frank Denis
236cd2e65c fn() is not a valid C prototype 2019-06-25 12:16:36 +02:00
Jim Huang
256eb97849 Avoid unnecessary symbol exposure with ELF-based systems
GCC's default visibility is "public" but can be changed to
"hidden" with the argument "-fvisibility=hidden".

Tested with x86_64 / Ubuntu Linux 18.04 LTS:

[before]
$ nm -g -C libmimalloc.so | grep "T " | wc -l
142

[after]
$ nm -g -C libmimalloc.so | grep "T " | wc -l
93

This patch does not change the build on macOS.
2019-06-25 10:00:22 +08:00
daan
c1226611c6 Merge branch 'master' into dev 2019-06-24 18:13:04 -07:00
Daan
8bb8852d4f
Merge pull request #17 from jserv/macos-rebranding
Apple rebrands "OS X" as "macOS"
2019-06-24 18:12:06 -07:00
Daan
e86935e108
Merge pull request #18 from jserv/fix-typo
Fix typo
2019-06-24 18:09:26 -07:00
daan
cc951affac fix compilation on older mac systems without CLOCK_MONOTONIC 2019-06-24 18:06:46 -07:00
daan
f36149a9ac fix format specifiers 2019-06-24 12:20:32 -07:00
Jim Huang
855e2f0d89 Use clock_gettime() instead of timespec_get()
clock_gettime(CLOCK_REALTIME, &ts) is equivalent to timespec_get(&ts,
TIME_UTC) in C11.

It has the advantage that avoids the following building error when building
with macOS:

  warning: 'timespec_get' is only available on macOS 10.15 or newer
   [-Wunguarded-availability-new]
2019-06-24 23:56:19 +08:00
daan
cbbd57322a Merge branch 'master' into dev 2019-06-24 08:12:25 -07:00
daan
91222691cb fix more warnings on mingw build 2019-06-24 00:42:45 -07:00
daan
c1c848516c fix warnings on mingw build 2019-06-24 00:37:15 -07:00
daan
faadceadf5 Merge branch 'master' into dev 2019-06-24 00:21:07 -07:00
daan
443fa0fbb5 fix assertions for the new huge page cache 2019-06-24 00:06:22 -07:00
daan
f0731862d6 fix compilation on mingw, issue #25 2019-06-23 23:17:44 -07:00
daan
cd7aa0ce83 improve handling of huge pages in the cache 2019-06-23 23:15:42 -07:00
daan
43568fa422 ensure huge pages are part of the segment cache to avoid mmap calls 2019-06-23 21:37:43 -07:00
daan
e5e2b789ba fix pool commit for windows 2019-06-23 20:41:34 -07:00
Jim Huang
a667971cbf Apple rebrands "OS X" as "macOS"
In 2012, with the release of OS X 10.8 Mountain Lion, the name of the
system was shortened from Mac OS X to OS X. In 2016, with the release
of macOS 10.12 Sierra, the name was changed from OS X to macOS to
streamline it with the branding of Apple's other primary operating
systems: iOS, watchOS, and tvOS.

Reference: https://en.wikipedia.org/wiki/MacOS
2019-06-24 10:15:50 +08:00
Jim Huang
243636b6a1 Fix typo in comment 2019-06-24 10:13:43 +08:00
daan
3526b09903 fix gcc warning 2019-06-23 18:37:54 -07:00
Daan Leijen
ef02104fd3 fix posix_memalign according to issue #27 2019-06-23 10:59:47 -07:00
Daan
fab7329c7a
Merge pull request #24 from jserv/clarify-license
Clarify top-level license file
2019-06-23 10:47:38 -07:00
Jim Huang
78c7a1f349 Fix typo in comments 2019-06-24 01:40:28 +08:00
Jim Huang
b1d299b35b Clarify top-level license file
To be consistent with other Microsoft open source projects, each source
file points to the file "LICENSE" in top-level directory.
2019-06-23 19:53:34 +08:00
Daan
06f8da4218
Merge pull request #15 from krytarowski/netbsd-1
Fix build on NetBSD
2019-06-22 21:04:15 -07:00
Kamil Rytarowski
b0b1b43dba Fix build on NetBSD
Add missing argument in mi_mmap()
2019-06-23 00:06:41 +02:00
Frank Denis
4d67e58e0f Fix mi_process_info placeholder prototype 2019-06-22 22:43:14 +02:00
Sungmann Cho
def97b0fd1 Fix spelling errors
aligment -> alignment
purgable -> purgeable
thead -> thread
2019-06-23 00:09:11 +09:00
daan
26a874eb3f initial checkin 2019-06-19 16:26:12 -07:00