285: add many emscripten functions for PHP r=MarkMcCaskey a=MarkMcCaskey
Co-authored-by: Mark McCaskey <mark@wasmer.io>
Co-authored-by: Mark McCaskey <markmccaskey@users.noreply.github.com>
286: Add extend to imports r=MarkMcCaskey a=MarkMcCaskey
a rewrite of #283 with a focus on simplicity
resolves#258
Co-authored-by: Mark McCaskey <mark@wasmer.io>
284: fix make debug-release r=MarkMcCaskey a=MarkMcCaskey
My guess without looking in to the history is that:
- the unsafe block was around the `debug!` call
- when debug was off, it was giving a warning because the unsafe block was empty
- the unsafe was removed to stop the warning
- it wasn't tested with the debug flag
This PR also
- cleans up the Makefile
- adds debug-release to CI
Co-authored-by: Mark McCaskey <mark@wasmer.io>
271: feat: Implement `wasmer_module_serialize` and `wasmer_module_deserialize` functions in `runtime-c-api` r=Hywan a=Hywan
This PR implements 5 new functions in the `runtime-c-api` crate:
1. `wasmer_module_serialize` to serialize a module into a `wasmer_serialized_module_t` type,
2. `wasmer_module_deserialize` to deserialize a serialized module,
3. `wasmer_serialized_module_bytes` to read the bytes in the `wasmer_serialized_module_t` type into a `wasmer_byte_array`,
4. `wasmer_serialized_module_from_bytes` to transform a `wasmer_byte_array` into a `wasmer_serialized_module_t`,
4. `wasmer_serialized_module_destroy` to destroy a `wasmer_serialized_module_t`.
Documentation and a test suite have been added.
We need to change the visibility of the `wasmer_runtime::default_compiler` function to public, since it is used in `runtime-c-api`.
The new test suite `test-module-serialize` does a full roundtrip: A module is compiled, then serialized, then deserialized, to finally be instantiated and a function is called on it.
Thoughts?
Co-authored-by: Ivan Enderlin <ivan.enderlin@hoa-project.net>
280: feat(runtime-c-api) Mirrors the `debug` and `llvm` features r=Hywan a=Hywan
`wasmer-runtime` has a `debug` and a `llvm` feature. Let's mirror
them in `wasmer-runtime-c-api` so that the user can, for instance,
compile with the LLVM backend.
Co-authored-by: Ivan Enderlin <ivan.enderlin@hoa-project.net>