Convert compilation artifacts to just bytes (#3239)

* Convert compilation artifacts to just bytes

This commit strips the `CompilationArtifacts` type down to simply a list
of bytes. This moves all extra metadata elsewhere to live within the
list of bytes itself as `bincode`-encoded information.

Small affordance is made to avoid an in-process
serialize-then-deserialize round-trip for use cases like `Module::new`,
but otherwise this is mostly just moving some data around.

* Rename data section to `.rodata.wasm`
This commit is contained in:
Alex Crichton
2021-08-26 21:17:02 -05:00
committed by GitHub
parent a2a6be72c4
commit d12f1d77e6
7 changed files with 168 additions and 73 deletions

View File

@@ -28,6 +28,7 @@ addr2line = { version = "0.16.0", default-features = false }
libc = { version = "0.2.60", default-features = false, optional = true }
scroll = { version = "0.10.1", features = ["derive"], optional = true }
ittapi-rs = { version = "0.1.5", optional = true }
bincode = "1.2.1"
[target.'cfg(target_os = "windows")'.dependencies]
winapi = { version = "0.3.8", features = ["winnt", "impl-default"] }