mirror of
https://github.com/danbulant/oxc
synced 2026-05-25 04:42:10 +00:00
The `parser_napi` pseudo-benchmark does not depend on any Oxc crates, so remove all dependencies for this benchmark. This reduces build time of this benchmark on CI by ~1 minute. After #2780, NAPI parser benchmark sometimes took the longest of all the benchmarks, so making it faster reduces time to complete the benchmarks overall.
93 lines
2.2 KiB
TOML
93 lines
2.2 KiB
TOML
[package]
|
|
name = "oxc_benchmark"
|
|
version = "0.0.0"
|
|
publish = false
|
|
authors.workspace = true
|
|
description.workspace = true
|
|
edition.workspace = true
|
|
homepage.workspace = true
|
|
keywords.workspace = true
|
|
license.workspace = true
|
|
repository.workspace = true
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[lib]
|
|
test = false
|
|
bench = false
|
|
doctest = false
|
|
|
|
[[bench]]
|
|
name = "lexer"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "parser"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "transformer"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "semantic"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "linter"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "codegen_sourcemap"
|
|
harness = false
|
|
|
|
# Broken
|
|
# [[bench]]
|
|
# name = "prettier"
|
|
# harness = false
|
|
|
|
[[bench]]
|
|
name = "minifier"
|
|
harness = false
|
|
|
|
# Only run in CI
|
|
[[bench]]
|
|
name = "parser_napi"
|
|
harness = false
|
|
bench = false
|
|
|
|
[dependencies]
|
|
# All optional as `parser_napi` pseudo-benchmark doesn't need any of them,
|
|
# and including them in compilation adds 1 minute to building that benchmark on CI.
|
|
# See `tasks/benchmark/benches/parser_napi.rs`.
|
|
oxc_allocator = { workspace = true, optional = true }
|
|
oxc_linter = { workspace = true, optional = true }
|
|
oxc_minifier = { workspace = true, optional = true }
|
|
oxc_parser = { workspace = true, features = ["benchmarking"], optional = true }
|
|
oxc_prettier = { workspace = true, optional = true }
|
|
oxc_semantic = { workspace = true, optional = true }
|
|
oxc_span = { workspace = true, optional = true }
|
|
oxc_tasks_common = { workspace = true, optional = true }
|
|
oxc_transformer = { workspace = true, optional = true }
|
|
oxc_codegen = { workspace = true, optional = true }
|
|
|
|
criterion = { package = "criterion2", version = "0.6.0", default-features = false }
|
|
serde = { workspace = true, optional = true }
|
|
serde_json = { workspace = true, optional = true }
|
|
|
|
[features]
|
|
default = [
|
|
"dep:oxc_allocator",
|
|
"dep:oxc_linter",
|
|
"dep:oxc_minifier",
|
|
"dep:oxc_parser",
|
|
"dep:oxc_prettier",
|
|
"dep:oxc_semantic",
|
|
"dep:oxc_span",
|
|
"dep:oxc_tasks_common",
|
|
"dep:oxc_transformer",
|
|
"dep:oxc_codegen",
|
|
]
|
|
codspeed = ["criterion/codspeed"]
|
|
codspeed_napi = ["criterion/codspeed", "dep:serde", "dep:serde_json"]
|