make backtrace collection a Config field rather than a cargo feature (#4183)

* sorta working in runtime

* wasmtime-runtime: get rid of wasm-backtrace feature

* wasmtime: factor to make backtraces recording optional. not configurable yet

* get rid of wasm-backtrace features

* trap tests: now a Trap optionally contains backtrace

* eliminate wasm-backtrace feature

* code review fixes

* ci: no more wasm-backtrace feature

* c_api: backtraces always enabled

* config: unwind required by backtraces and ref types

* plumbed

* test that disabling backtraces works

* code review comments

* fuzzing generator: wasm_backtrace is a runtime config now

* doc fix
This commit is contained in:
Pat Hickey
2022-05-25 12:25:50 -07:00
committed by GitHub
parent 010e028d67
commit bffce37050
20 changed files with 310 additions and 234 deletions

View File

@@ -25,7 +25,7 @@ anyhow = "1.0.19"
region = "2.2.0"
libc = "0.2"
cfg-if = "1.0"
backtrace = { version = "0.3.61", optional = true }
backtrace = { version = "0.3.61" }
log = "0.4.8"
wat = { version = "1.0.43", optional = true }
serde = { version = "1.0.94", features = ["derive"] }
@@ -37,7 +37,7 @@ lazy_static = "1.4"
rayon = { version = "1.0", optional = true }
object = { version = "0.28", default-features = false, features = ['read_core', 'elf'] }
async-trait = { version = "0.1.51", optional = true }
once_cell = "1.9"
once_cell = "1.12"
[target.'cfg(target_os = "windows")'.dependencies]
winapi = "0.3.7"
@@ -61,7 +61,6 @@ default = [
'pooling-allocator',
'memory-init-cow',
'vtune',
'wasm-backtrace',
]
# An on-by-default feature enabling runtime compilation of WebAssembly modules
@@ -106,12 +105,6 @@ posix-signals-on-macos = ["wasmtime-runtime/posix-signals-on-macos"]
# Enabling this feature has no effect on unsupported platforms.
memory-init-cow = ["wasmtime-runtime/memory-init-cow"]
# Enables runtime support necessary to capture backtraces of WebAssembly code
# that is running.
#
# This is enabled by default.
wasm-backtrace = ["wasmtime-runtime/wasm-backtrace", "backtrace"]
# Enables in-progress support for the component model. Note that this feature is
# in-progress, buggy, and incomplete. This is primarily here for internal
# testing purposes.