Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change default chunksize to 1MiB #229

Merged
merged 5 commits into from
Jul 9, 2020
Merged

Change default chunksize to 1MiB #229

merged 5 commits into from
Jul 9, 2020

Conversation

mjp41
Copy link
Member

@mjp41 mjp41 commented Jul 8, 2020

This change makes the original 16MiB option not the common option.

It also changes the names of the defines to
SNMALLOC_USE_LARGE_CHUNKS
SNMALLOC_USE_SMALL_CHUNKS

The second should be set for Open Enclave configuration, and results in
256KiB chunk sizes. The first being set builds the original 16MiB chunk
sizes. If neither is set, then we default to 1MiB chunk sizes.

This change makes the original 16MiB option not the common option.

It also changes the names of the defines to
  SNMALLOC_USE_LARGE_CHUNKS
  SNMALLOC_USE_SMALL_CHUNKS

The second should be set for Open Enclave configuration, and results in
256KiB chunk sizes.  The first being set builds the original 16MiB chunk
sizes.  If neither is set, then we default to 1MiB chunk sizes.
@mjp41
Copy link
Member Author

mjp41 commented Jul 8, 2020

@SchrodingerZhu this is going to need changes downstream in snmalloc-rs

@mjp41
Copy link
Member Author

mjp41 commented Jul 8, 2020

Once, I land this changes and a few other PRs I plan to release, 0.5.

@mjp41
Copy link
Member Author

mjp41 commented Jul 8, 2020

@achamayou @anakrish this change will change the defines needed in allocator.cpp, but makes things a bit clearer.

https://github.com/openenclave/openenclave/blob/469f75adffa8aa302315db469af7e233f2efd41e/3rdparty/snmalloc/allocator.cpp#L24-L25

will become

#define SNMALLOC_USE_SMALL_CHUNKS

@achamayou
Copy link
Member

@mjp41 thank you for the heads up, I'll PR the update on the OE side once 0.5 is out.

@SchrodingerZhu
Copy link
Collaborator

this is going to need changes downstream in snmalloc-rs

will make it happen when this is merged.

@mjp41 mjp41 merged commit 4e1f582 into microsoft:master Jul 9, 2020
@mjp41 mjp41 deleted the chunksize branch July 9, 2020 12:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants