Changelog
Unreleased
-
Added
install_lucet_signal_handler()andremove_lucet_signal_handler(), along withInstance::ensure_signal_handler_installed()andInstance::ensure_sigstack_installed()options to control the automatic installation and removal of signal handlers and alternate signal stacks. The default behaviors have not changed. -
Added
Instance::run_start()to the public API, which runs the Wasm start function if it is present in that instance's Wasm module. It does nothing if there is no start function.Creating or resetting an instance no longer implicitly runs the start function. Embedders must ensure that
run_start()is called before calling any other exported functions.Instance::run()will now returnErr(Error::InstanceNeedsStart)if the start function is present but hasn't been run since the instance was created or reset. -
Encoded the Wasm start function in Lucet module metadata, rather than as a specially-named symbol in the shared object. This reduces contention from
dlsymoperations when multiple threads run Lucet instances concurrently. -
Upgraded the
libloadingdependency, allowing for more specific error messages from dynamic loading operations. -
Corrected a race condition where a
KillSwitchfired while lucet-runtime is handling a guest fault could result in a SIGALRM or panic in the Lucet embedder. -
Converted the
&mut Vmctxargument to hostcalls into&Vmctx. Additionally, allVmctxmethods now take&self, where some methods such asyieldpreviously took&mut self. These methods still require that no other outstanding borrows (such as the heap view) are held across them, but that property is checked dynamically rather than at compile time.
0.6.1 (2020-02-18)
-
Added metadata to compiled modules that record whether instruction counting instrumentation is present.
-
Made
lucetcmore flexible in its interpretation of theLDenvironment variable. It now accepts a space-separated set of tokens; the first token specifies the program to invoke, and the remaining tokens specifying arguments to be passed to that program. Thanks, @froydnj! -
Added public
LucetcOptmethods to configure thecanonicalize_nanssetting. Thanks, @roman-kashitsyn! -
Fixed
lucet-runtime's use of CPUID to not look for extended features unless required by the module being loaded, avoiding a failure on older CPUs where that CPUID leaf is not present. Thanks, @shravanrn!
0.6.0 (2020-02-05)
-
Added
free_slots(),used_slots(), andcapacity()methods to theRegiontrait. -
Added a check to ensure the
Limitssignal stack size is at leastMINSIGSTKSZ, and increased the default signal stack size on macOS debug builds to fit this constraint. -
Added an option to canonicalize NaNs to the
lucetcAPI. Thanks, @DavidM-D! -
Restored some of the verbosity of pretty-printed errors in
lucetcandlucet-validate, with more on the way. -
Fixed OS detection for LDFLAGS on macOS. Thanks, @roman-kashitsyn!
0.5.1 (2020-01-24)
- Fixed a memory corruption bug that could arise in certain runtime configurations. (PR) (RustSec advisory)
0.5.0 (2020-01-24)
-
Lucet officially became a project of the Bytecode Alliance 🎉.
-
Integrated
wasi-commonas the underlying implementation for WASI inlucet-wasi. -
Updated to Cranelift to version 0.51.0.
-
Fixed a soundness bug by changing the types of the
Vmctx::yield*()methods to require exclusive&mut selfaccess to theVmctx. This prevents resources like embedder contexts or heap views from living across yield points, which is important for safety since the host can modify the data underlying those resources while the instance is suspended. -
Added the
#[lucet_hostcall]attribute to replacelucet_hostcalls!, which is now deprecated. -
Added the ability to specify an alignment for the base of a
MmapRegion-backed instance's heap. Thanks, @shravanrn! -
Added a
--targetoption tolucetcto allow cross-compilation to other architectures than the host's. Thanks, @froydnj! -
Changed the Cargo dependencies between Lucet crates to be exact (e.g.,
"=0.5.0"rather than"0.5.0") rather than allowing semver differences. -
Fixed the
KillSwitchtype not being exported from the public API, despite being usable viaInstance::kill_switch(). -
Improved the formatting of error messages.
-
Ensured the
lucet-wasiexecutable properly links in the exported symbols fromlucet-runtime.
0.4.3 (2020-01-24)
- Backported the fix for a memory corruption bug that could arise in certain runtime configurations. (PR) (RustSec advisory)