Skip to content

Revert "Do not hardcode stable compile-time benchmarks in dashboard" #1520

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

Merged
merged 1 commit into from
Jan 30, 2023
Merged
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
24 changes: 14 additions & 10 deletions site/src/request_handlers/dashboard.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
use collector::benchmark::{compile_benchmark_dir, get_compile_benchmarks};
use std::sync::Arc;

use crate::api::{dashboard, ServerResult};
Expand Down Expand Up @@ -75,18 +74,23 @@ pub async fn handle_dashboard(ctxt: Arc<SiteCtxt>) -> ServerResult<dashboard::Re
.collect::<Vec<_>>(),
);

let stable_benchmarks: Vec<String> =
get_compile_benchmarks(&compile_benchmark_dir(), None, None)
.map_err(|error| format!("Could not load benchmarks: {error:?}"))?
.into_iter()
.filter(|benchmark| benchmark.category().is_stable())
.map(|benchmark| benchmark.name.to_string())
.collect();

let query = selector::Query::new()
// FIXME: don't hardcode the stabilized benchmarks
// This list was found via:
// `rg supports.stable collector/compile-benchmarks/ -tjson -c --sort path`
.set(
selector::Tag::Benchmark,
selector::Selector::Subset(stable_benchmarks),
selector::Selector::Subset(vec![
"encoding",
"futures",
"html5ever",
"inflate",
"piston-image",
"regex",
"style-servo",
"syn",
"tokio-webpush-simple",
]),
)
.set(selector::Tag::Metric, selector::Selector::One("wall-time"));

Expand Down