Stream: git-wasmtime

Topic: wasmtime / PR #3760 Make memfd image creation lazy (on fi...


view this post on Zulip Wasmtime GitHub notifications bot (Feb 02 2022 at 23:59):

cfallin opened PR #3760 from memfd-lazy-create to main:

As a followup to the recent memfd allocator work, this PR makes the
memfd image creation occur on the first instantiation, rather than
immediately when the Module is loaded.

This shaves off a potentially surprising cost spike that would have
otherwise occurred: prior to the memfd work, no allocator eagerly read
the module's initial heap state into RAM. The behavior should now more
closely resemble what happened before (and the improvements in overall
instantiation time and performance, as compared to either eager init
with pure-mmap memory or user-mode pagefault handling with uffd,
remain).

<!--

Please ensure that the following steps are all taken care of before submitting
the PR.

Please ensure all communication adheres to the code of conduct.
-->

view this post on Zulip Wasmtime GitHub notifications bot (Feb 02 2022 at 23:59):

cfallin requested alexcrichton for a review on PR #3760.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 15:21):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 15:21):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 15:21):

alexcrichton created PR review comment:

Given the relative cost of locking a mutex I think it'd be better to use a OnceCell for this which also removes the need for cloning and a custom enum here.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 20:40):

cfallin updated PR #3760 from memfd-lazy-create to main.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 20:47):

cfallin updated PR #3760 from memfd-lazy-create to main.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 20:47):

cfallin submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 20:47):

cfallin created PR review comment:

Done!

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 21:09):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 03 2022 at 21:20):

cfallin merged PR #3760.


Last updated: Dec 23 2024 at 13:07 UTC