alexcrichton opened PR #2877 from less-tls
to main
:
This commit removes a TLS lookup of the store information whenever a
trap is created. This was previously done to lookup information in the
module registry, but nowadays there's a global registry which has all
the equivalent information as well. This commit moves around some code
in the module registry and then uses this global map when creating
traps.This is not motivated by performance, and likely regresses performance
slightly since it involves taking a global lock now. That being said the
perf of creating aTrap
is generally not super consequential, so this
is seen as ok.The goal of this commit is to lessen Wasmtime's reliance on TLS for
store-based information. I'm hoping to lessen this even more with the
changes for bytecodealliance/rfcs#11, where acquiring a store via TLS is
going to be much more difficult if not possible any more.<!--
Please ensure that the following steps are all taken care of before submitting
the PR.
[ ] This has been discussed in issue #..., or if not, please tell us why
here.[ ] A short description of what this does, why it is needed; if the
description becomes long, the matter should probably be discussed in an issue
first.[ ] This PR contains test cases, if meaningful.
- [ ] A reviewer from the core maintainer team has been assigned for this PR.
If you don't know who could review this, please indicate so. The list of
suggested reviewers on the right can help you.Please ensure all communication adheres to the code of conduct.
-->
alexcrichton updated PR #2877 from less-tls
to main
.
alexcrichton updated PR #2877 from less-tls
to main
.
alexcrichton closed without merge PR #2877.
Last updated: Dec 23 2024 at 12:05 UTC