Skip to content

Commit e335e36

Browse files
committed
PR Feedback; have more specific enqueues of Runtime and Rustc benchmarks
1 parent 9c2f4de commit e335e36

File tree

1 file changed

+29
-24
lines changed

1 file changed

+29
-24
lines changed

site/src/job_queue/mod.rs

Lines changed: 29 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ use chrono::Utc;
77
use collector::benchmark_set::benchmark_set_count;
88
use database::{
99
BenchmarkJobKind, BenchmarkRequest, BenchmarkRequestIndex, BenchmarkRequestStatus,
10-
BenchmarkRequestType, Date, PendingBenchmarkRequests, Profile, QueuedCommit, Target,
10+
BenchmarkRequestType, CodegenBackend, Date, PendingBenchmarkRequests, Profile, QueuedCommit,
11+
Target,
1112
};
1213
use parking_lot::RwLock;
1314
use std::{str::FromStr, sync::Arc};
@@ -232,31 +233,35 @@ pub async fn enqueue_benchmark_request(
232233
// Prevent the error from spamming the logs
233234
// let mut has_emitted_parent_sha_error = false;
234235

236+
// Enqueue Rustc job for only for x86_64 & llvm. This benchmark is how long
237+
// it takes to build the rust compiler. It takes a while to run and is
238+
// assumed that if the compilation of other rust project improve then this
239+
// too would improve.
240+
tx.conn()
241+
.enqueue_benchmark_job(
242+
request_tag,
243+
Target::X86_64UnknownLinuxGnu,
244+
CodegenBackend::Llvm,
245+
Profile::Opt,
246+
0u32,
247+
BenchmarkJobKind::Rustc,
248+
)
249+
.await?;
250+
235251
// Target x benchmark_set x backend x profile -> BenchmarkJob
236252
for target in Target::all() {
237-
// enqueue Runtime job and Rustc job, for each backend
238-
for &backend in backends.iter() {
239-
tx.conn()
240-
.enqueue_benchmark_job(
241-
request_tag,
242-
target,
243-
backend,
244-
Profile::Opt,
245-
0u32,
246-
BenchmarkJobKind::Runtime,
247-
)
248-
.await?;
249-
tx.conn()
250-
.enqueue_benchmark_job(
251-
request_tag,
252-
target,
253-
backend,
254-
Profile::Opt,
255-
0u32,
256-
BenchmarkJobKind::Rustc,
257-
)
258-
.await?;
259-
}
253+
// Enqueue Runtime job for all targets using LLVM as the backend for
254+
// runtime benchmarks
255+
tx.conn()
256+
.enqueue_benchmark_job(
257+
request_tag,
258+
target,
259+
CodegenBackend::Llvm,
260+
Profile::Opt,
261+
0u32,
262+
BenchmarkJobKind::Runtime,
263+
)
264+
.await?;
260265

261266
for benchmark_set in 0..benchmark_set_count(target.into()) {
262267
for &backend in backends.iter() {

0 commit comments

Comments
 (0)