Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add --disable-parallel-compilation CLI flag #4911

Merged
merged 1 commit into from
Sep 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions crates/cli-flags/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ default = [
"wasmtime/cranelift",
"wasmtime/jitdump",
"wasmtime/vtune",
"wasmtime/parallel-compilation",
]
pooling-allocator = []
memory-init-cow = []
Expand Down
8 changes: 8 additions & 0 deletions crates/cli-flags/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,10 @@ pub struct CommonOptions {
#[clap(long)]
pub disable_cache: bool,

/// Disable parallel compilation
#[clap(long)]
pub disable_parallel_compilation: bool,

/// Enables or disables WebAssembly features
#[clap(long, value_name = "FEATURE,FEATURE,...", parse(try_from_str = parse_wasm_features))]
pub wasm_features: Option<WasmFeatures>,
Expand Down Expand Up @@ -292,6 +296,10 @@ impl CommonOptions {
}
}

if self.disable_parallel_compilation {
config.parallel_compilation(false);
}

if let Some(max) = self.static_memory_maximum_size {
config.static_memory_maximum_size(max);
}
Expand Down