Skip to content

Commit ec08b85

Browse files
committed
Review batch
1 parent 9ef06fd commit ec08b85

File tree

4 files changed

+12
-5
lines changed

4 files changed

+12
-5
lines changed

collector/benchmarks/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ They mostly consist of real-world crates.
2020
programs.
2121
- **cranelift-codegen**: The largest crate from a code generator. Used by
2222
Firefox.
23-
- **diesel**: A type save SQL query builder. Utilizes the type system to
23+
- **diesel**: A type safe SQL query builder. Utilizes the type system to
2424
ensure a lot of invariants. Stresses anything related to resolving
2525
trait bounds, by having a lot of trait impls for a large number of different
2626
types.

collector/src/execute.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ fn default_runs() -> usize {
112112

113113
#[derive(Debug, Clone, serde::Deserialize)]
114114
#[serde(rename_all = "lowercase")]
115-
enum Category {
115+
pub enum Category {
116116
Primary,
117117
Secondary,
118118
}

collector/src/main.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ use tokio::runtime::Runtime;
1515
mod execute;
1616
mod sysroot;
1717

18+
use crate::execute::Category;
1819
use execute::{BenchProcessor, Benchmark, BenchmarkName, ProfileProcessor, Profiler};
1920
use sysroot::Sysroot;
2021

@@ -255,7 +256,7 @@ fn bench(
255256
measure_and_record(
256257
&BenchmarkName("rustc".to_string()),
257258
/* supports_stable */ false,
258-
"primary",
259+
&Category::Primary.to_string(),
259260
&|| eprintln!("Special benchmark commencing (due to `--bench-rustc`)"),
260261
&|processor| processor.measure_rustc(compiler).context("measure rustc"),
261262
);

site/static/compare.html

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,6 +279,12 @@
279279
width: 20%;
280280
}
281281
}
282+
.category-title {
283+
font-weight: bold;
284+
font-size: 1.2em;
285+
margin: 10px;
286+
text-align: center;
287+
}
282288
</style>
283289
<script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script>
284290
</head>
@@ -632,8 +638,8 @@ <h2>Comparing <span id="stat-header">{{stat}}</span> between <span id="before">{
632638
},
633639
template: `
634640
<div class="bench-table">
635-
<div>{{ title }} benchmarks</div>
636-
<div v-if="cases.length === 0">
641+
<div class="category-title">{{ title }} benchmarks</div>
642+
<div v-if="cases.length === 0" style="text-align: center;">
637643
No results
638644
</div>
639645
<table v-else class="benches compare">

0 commit comments

Comments
 (0)