From 040c878c6ea06eef6f939e73c93911ccb3e4c9bf Mon Sep 17 00:00:00 2001 From: Matthew Parkinson Date: Fri, 28 Feb 2020 09:03:41 +0000 Subject: [PATCH] Update documentation The readme was considerably out of date, with the introduction being over a year old. This commit reflects the developments and improvements in stabiity of snmalloc. --- README.md | 28 ++++++++++++++++++++++++---- security.md | 37 +++++++++++++++++++++++++++++++++++++ 2 files changed, 61 insertions(+), 4 deletions(-) create mode 100644 security.md diff --git a/README.md b/README.md index 8b39dc9e..163c2cec 100644 --- a/README.md +++ b/README.md @@ -1,18 +1,38 @@ # snmalloc -snmalloc is a research allocator. Its key design features are: +snmalloc is a high-performance allocator. +snmalloc can be used directly in a project as a header-only C++ library, +it can be `LD_PRELOAD`ed on Elf platforms (e.g. Linux, BSD), +and there is a [crate](https://crates.io/crates/snmalloc-rs) to use it from Rust. + +Its key design features are: * Memory that is freed by the same thread that allocated it does not require any synchronising operations. * Freeing memory in a different thread to initially allocated it, does not take any locks and instead uses a novel message passing scheme to return the - memory to the original allocator, where it is recycled. + memory to the original allocator, where it is recycled. This enables 1000s of remote + deallocations to be performed with only a single atomic operation enabling great + scaling with core count. * The allocator uses large ranges of pages to reduce the amount of meta-data required. +* The fast paths are highly optimised with just two branches on the fast path + for malloc (On Linux compiled with Clang). +* The platform dependencies are abstracted away to enable porting to other platforms. -Details about snmalloc's design can be found in the -[accompanying paper](snmalloc.pdf). Differences between the paper and the +snmalloc's design is particular well suited to the following two difficult +scenarios that can be problematic for other allocators: + + * Allocations on one thread are freed by a different thread + * Deallocations occur in large batches + +Both of these can cause massive reductions in performance of other allocators, but +do not for snmalloc. + +Comprehensive details about snmalloc's design can be found in the +[accompanying paper](snmalloc.pdf), and differences between the paper and the current implementation are [described here](difference.md). +Since writing the paper, the performance of snmalloc has improved considerably. [![Build Status](https://dev.azure.com/snmalloc/snmalloc/_apis/build/status/Microsoft.snmalloc?branchName=master)](https://dev.azure.com/snmalloc/snmalloc/_build/latest?definitionId=1?branchName=master) diff --git a/security.md b/security.md new file mode 100644 index 00000000..15d4fd46 --- /dev/null +++ b/security.md @@ -0,0 +1,37 @@ +## Security + +Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/). + +If you believe you have found a security vulnerability in any Microsoft-owned repository that meets Microsoft's [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below. + +## Reporting Security Issues + +**Please do not report security vulnerabilities through public GitHub issues.** + +Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report). + +If you prefer to submit without logging in, send email to [secure@microsoft.com](mailto:secure@microsoft.com). If possible, encrypt your message with our PGP key; please download it from the the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc). + +You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc). + +Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue: + + * Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.) + * Full paths of source file(s) related to the manifestation of the issue + * The location of the affected source code (tag/branch/commit or direct URL) + * Any special configuration required to reproduce the issue + * Step-by-step instructions to reproduce the issue + * Proof-of-concept or exploit code (if possible) + * Impact of the issue, including how an attacker might exploit the issue + +This information will help us triage your report more quickly. + +If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs. + +## Preferred Languages + +We prefer all communications to be in English. + +## Policy + +Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).