Skip to content

Commit

Permalink
refactor: various improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
hugocaillard committed Aug 2, 2023
1 parent 422748a commit 2ebd0a1
Show file tree
Hide file tree
Showing 12 changed files with 546 additions and 105 deletions.
1 change: 1 addition & 0 deletions components/clarinet-deployments/src/types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ impl Into<StacksEpochId> for EpochSpec {
}
}

#[derive(Debug, Clone)]
pub struct DeploymentGenerationArtifacts {
pub asts: BTreeMap<QualifiedContractIdentifier, ContractAST>,
pub deps: BTreeMap<QualifiedContractIdentifier, DependencySet>,
Expand Down
2 changes: 1 addition & 1 deletion components/clarinet-sdk/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
dist/
pkg/
src-ts/sdk
node_modules/
37 changes: 24 additions & 13 deletions components/clarinet-sdk/cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,27 +37,38 @@ wasm = [
"clarinet-files/wasm",
]

[package.metadata.wasm-pack.profile.dev]
wasm-opt = ['-O1']
# DEV
[profile.dev]
inherits = "release"
opt-level = 3
debug = false
debug-assertions = false
incremental = false
codegen-units = 256

[package.metadata.wasm-pack.profile.dev.wasm-bindgen]
debug-js-glue = true
demangle-name-section = true
dwarf-debug-info = false
[profile.dev.build-override]
inherits = "release"
opt-level = 3

[package.metadata.wasm-pack.profile.profiling]
wasm-opt = ['-O']
[package.metadata.wasm-pack.profile.dev]
wasm-opt = false

[package.metadata.wasm-pack.profile.profiling.wasm-bindgen]
[package.metadata.wasm-pack.profile.dev.wasm-bindgen]
debug-js-glue = false
demangle-name-section = true
dwarf-debug-info = false

# RELEASE
[profile.release]
opt-level = 3
debug = false
debug-assertions = false
lto = true
incremental = false
codegen-units = 16

[package.metadata.wasm-pack.profile.release]
# -04 aggressively optimizes for speed
wasm-opt = false
# -0z aggressively optimizes for size
# wasm-opt = ['-Oz']
wasm-opt = ['-O1']

[package.metadata.wasm-pack.profile.release.wasm-bindgen]
debug-js-glue = false
Expand Down
Loading

0 comments on commit 2ebd0a1

Please sign in to comment.