@@ -15,7 +15,7 @@ mod self_profile;
1515pub mod toolchain;
1616pub mod utils;
1717
18- use crate :: compile:: benchmark:: { Benchmark , BenchmarkName } ;
18+ use crate :: compile:: benchmark:: Benchmark ;
1919use crate :: runtime:: { BenchmarkGroup , BenchmarkSuite } ;
2020pub use crate :: self_profile:: {
2121 LocalSelfProfileStorage , S3SelfProfileStorage , SelfProfileId , SelfProfileStorage ,
@@ -342,17 +342,7 @@ impl CollectorStepBuilder {
342342 ) -> CollectorCtx {
343343 // Make sure there is no observable time when the artifact ID is available
344344 // but the in-progress steps are not.
345- let artifact_row_id = {
346- let mut tx = conn. transaction ( ) . await ;
347- let artifact_row_id = tx. conn ( ) . artifact_id ( artifact_id) . await ;
348- if self . job_id . is_none ( ) {
349- tx. conn ( )
350- . collector_start ( artifact_row_id, & self . steps )
351- . await ;
352- }
353- tx. commit ( ) . await . unwrap ( ) ;
354- artifact_row_id
355- } ;
345+ let artifact_row_id = conn. artifact_id ( artifact_id) . await ;
356346 // Find out which tests cases were already computed
357347 let measured_compile_test_cases = conn
358348 . get_compile_test_cases_with_measurements ( & artifact_row_id)
@@ -385,24 +375,6 @@ pub struct CollectorCtx {
385375}
386376
387377impl CollectorCtx {
388- pub fn is_from_job_queue ( & self ) -> bool {
389- self . job_id . is_some ( )
390- }
391-
392- pub async fn start_compile_step ( & self , conn : & dyn Connection , benchmark_name : & BenchmarkName ) {
393- if !self . is_from_job_queue ( ) {
394- conn. collector_start_step ( self . artifact_row_id , & benchmark_name. 0 )
395- . await ;
396- }
397- }
398-
399- pub async fn end_compile_step ( & self , conn : & dyn Connection , benchmark_name : & BenchmarkName ) {
400- if !self . is_from_job_queue ( ) {
401- conn. collector_end_step ( self . artifact_row_id , & benchmark_name. 0 )
402- . await ;
403- }
404- }
405-
406378 /// Returns the names of benchmarks in the group that have not yet been measured
407379 /// for the given target.
408380 pub fn get_unmeasured_runtime_benchmarks < ' a > (
@@ -422,21 +394,6 @@ impl CollectorCtx {
422394 . map ( |s| s. as_str ( ) )
423395 . collect ( )
424396 }
425-
426- pub async fn start_runtime_step ( & self , conn : & dyn Connection , group : & BenchmarkGroup ) {
427- if !self . is_from_job_queue ( ) {
428- let step_name = runtime_group_step_name ( & group. name ) ;
429- conn. collector_start_step ( self . artifact_row_id , & step_name)
430- . await ;
431- }
432- }
433-
434- pub async fn end_runtime_step ( & self , conn : & dyn Connection , group : & BenchmarkGroup ) {
435- if !self . is_from_job_queue ( ) {
436- conn. collector_end_step ( self . artifact_row_id , & runtime_group_step_name ( & group. name ) )
437- . await ;
438- }
439- }
440397}
441398
442399pub fn runtime_group_step_name ( benchmark_name : & str ) -> String {
0 commit comments