Skip to content

Releases: microsoft/snmalloc

0.6.2

28 Jun 10:44
dc12688
Compare
Choose a tag to compare

Minor release primarily improving support on CHERI and Open Enclave

Thanks to @devnexen, @saaramar, @brvtalcake, @jumaffre and @EAirPeter for your contributions to this release.

0.6.1

02 Sep 16:10
88a2740
Compare
Choose a tag to compare

Minor release. Largest change is bringing online Morello CHERI support.

Thanks to the external contributors @panekj, @devnexen and @mfelsche.

0.6.0

09 May 12:40
d5c732f
Compare
Choose a tag to compare

This is a major revision of the snmalloc design. The redesign has been primarily focused on adding new security features. The redesign affects all aspects of snmalloc. A more comprehensive explanation of the new features can be found in the docs

  • Uses Buddy Allocators for large allocations: In 0.5.3, we never reconsolidate large allocations, so if you ask for several 1MiB allocations, return them, and then ask for several 2MiB allocations it won't be able to use the space from the 1MiB allocations.  This is not a problem in 0.6 as we have a proper buddy allocator at that level so we recombine the big bits of memory properly
  • Variable sized slabs and out of band meta-data - Previously, snmalloc used fixed sized super slabs with metadata at the head. By using variable sized slabs and out of band meta-data, the slabs don't have to be grouped into superslabs which reduces the minimum memory requirement. (https://github.com/microsoft/snmalloc/blob/main/docs/security/VariableSizedChunks.md)
  • Improved per thread caching - #511 - This enables very small per thread usage initially that can grow to the level required. This means that low foot print scenarios on OpenEnclave can be supported with exactly the same code paths as high footprint scenarios. This brings the per thread costs down to approximately 16k per thread of metadata + 16k per thread per sizeclass used. This will grow in powers of 2 (upto 2MiB) to cover the required amount.

0.5.3

29 Jan 15:16
a3660c4
Compare
Choose a tag to compare

All minor changes

  • Fix performance regression for Debug builds (#274)
  • Refactoring towards sandbox support (#221, #268, #269)
  • Refactoring towards CHERI support (#266)
  • Bug fixes for Power (#265), SPARC (#264), ARM 32bit (#263) Solaris (#262),

0.5.2

10 Nov 10:24
Compare
Choose a tag to compare

Bug fixes

  • Fixes issue where unused memory is zeroed by the OS, then superslab data can become corrupt. Only affected the 16MiB chunk size configuration. The bug did not affect the Linux implementation. #259
  • Typo that meant 16MiB configuration was ignored in some cases. #254

Platform Support

  • Improve Haiku support #255
  • Added DragonFly BSD support #252

Thanks especially to @devnexen for finding and fixing many issues in this release, and for the contributions to many previous releases in expanding snmallocs platform support.

0.5.1

22 Sep 13:38
Compare
Choose a tag to compare

The main change in this release is a new mechanism for tracking very coarse-grained memory usage statistics (#241). The interface is only exposed in malloc-extensions.h. We recommend static linking this API, as we may refine this in future releases.

Other changes:

  • PALs now fully static (#245)

Bug fixes:

  • Haiku Debug build fixed (#247)
  • Windows Clang CTZ was not defined on correct size for size_t (#242)
  • Fix to unit tests (#239)
  • FlatPageMap calculated too large size if payload was not a byte size (#236)

0.5.0

09 Jul 12:25
4e1f582
Compare
Choose a tag to compare

This version significantly improves the peak working set on Windows, and has a lower RSS on Linux systems using transparent huge pages.

Detailed changes:

  • Change default chunksize to 1MiB, and add explicit -16mib tagged version of libraries (#229).
  • Adds new AddressSpaceManager that improves performance with transparent huge pages (#214, #227) also improves support for open enclave (#212)
  • Improve Open Enclave support with new smaller chunk size of 256KiB (#212), and add versions of libraries and tests using this chunksize with the tag -oe.
  • Preliminary support for Haiku (#218) and Solaris (#226)

0.4.2

11 Jun 10:55
Compare
Choose a tag to compare

Changes

  • Preliminary Android support (#171)
  • Fixes to 32bit compile for Linux (#173)
  • Preparatory work for CHERI support (#188, #191, #193, #202)
  • Performance of alloc_size (#196)
  • Minor changes to build defaults (#177, #182, #187, #189, #194, #197, #206)
  • Improve Open Enclave support (#205, #201, #195)
  • Expose cfree (#179)
  • Allow different OS_PAGE_SIZES (#185)
  • Improve support for VS2019 (#207)
  • Add error message for failed init (#190)

Bug fixes

  • realloc of large allocation may calculate incorrectly return original allocation (#178, #209)
  • Fixed sized delete of nullptr (#181)
  • Fixed memory ordering in unit test (#184)

0.4.1

15 Apr 08:25
2b92574
Compare
Choose a tag to compare

Small fixes to 0.4

  • Build fixes for GCC9 and GCC 10 (#172)
  • Bug fix - if first call of a thread is a calloc, then it might not be zeroed. (#172)

0.4

10 Apr 14:23
cf9c2eb
Compare
Choose a tag to compare

The following are the main changes since the previous version:

  • Improved Decommit on Windows
    • Removed redundant system calls #120
    • Implement lazy decommit strategy to take OS call back, so an application not performing allocation can release memory to the OS #128
    • Bug Fix: Remove infinite loop on low-memory notification #123
  • Improved performance of multiple fast and slow paths
    • Improved sized deallocation code paths #115
    • Remote deallocation code path separated into fast and slow path (increased perf considerable for producer/consumer workloads) #138
    • Improve allocation slow path and change to thread local bump allocator #143
  • Improved alignment code
    • Support alignment of large allocations #124
    • Efficient calculation of alignment requests (just two additional integer instructions on fast path) #113
  • Support more platforms and tool chains
  • Bug fixes based on mimalloc-bench
    • Fixed poor performance in the message queue handling due to small batch size (#158 )
    • Fixed leak of allocators during TLS teardown (#161)
    • Fixed high page fault count from using MADV_DONTNEED for zeroing (#159)