Allows to trigger atomics related operations on a memory that supports
interacting with the atomics layer.
It adds a shared_handle() method to `Memory`.
Right now only final operations are exposed that wake up all atomic
waiters, and that allow disabling atomics.
This is required for forceful shutdown of instances that keep
hot-looping on atomics, and will be used from WASIX.
This reverts a breaking API change by providing stub implementations for
two new methods on LinearMemory (grow_at_least, reset).
The implementations return a new MemoryError::UnsupportedOperation.
Note: Since MemoryError is non-exhaustive, adding a new variant is
allowed.
We can make these methods required in a future major release if desired.
Closes#4392
* Make sure vmoffset are aligned to pointer size (for #4059)
* Fix linter
* Be more conservative on alignment
* Bumped MAGIC Header version as vmoffset changed
* Update linux wasmu files for CI deserialize test
* Updated windows wasmu files for deserialize CI test
Rework the deserialize/deserialize_checked methods for module
deserialization.
* Make deserialize() methods use artifact validation
* Make checked methods unsafe again, because loading executable memory
is inherently unsafe
* Rename methods that skip artifact validation to deserialize_unchecked
Closes#3727
* Change the try_clone and try_copy methods to return a Result<_, MemoryError>
This is a more informative return type than the previous Option<>,
and allows handling failure cases better
* Remove deprecated duplicate_in_store() method
Closes#3810
Enable rkyv validation of serialized module artifacts.
Required additions:
* derive the required CheckBytes trait for all types
* Add `_checked` variants of all the deserialization functions
Also enables the `strict` feature of rkyv by default.
This will ensure consistent archive binary layout across architectures
and Rust compiler versions.