File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -83,7 +83,7 @@ pub fn measure(
8383 . map ( |x| format ! ( "--obj-skip={}" , x) ) ,
8484 )
8585 . arg ( format ! ( "--callgrind-out-file={}" , profile_path. to_str( ) . unwrap( ) ) . as_str ( ) )
86- . arg ( format ! ( "--log-file={}" , log_path. to_str( ) . unwrap( ) ) . as_str ( ) ) ;
86+ . arg ( format ! ( "--log-file={}" , log_path. as_path ( ) . to_str( ) . unwrap( ) ) . as_str ( ) ) ;
8787
8888 // Set the command to execute
8989 cmd. args ( [ "sh" , "-c" , get_bench_command ( config) ?. as_str ( ) ] ) ;
@@ -97,6 +97,9 @@ pub fn measure(
9797 let status = run_command_with_log_pipe ( cmd)
9898 . map_err ( |e| anyhow ! ( "failed to execute the benchmark process. {}" , e) ) ?;
9999 if !status. success ( ) {
100+ let log_content = std:: fs:: read_to_string ( & log_path)
101+ . unwrap_or_else ( |_| "failed to read the valgrind log" . to_string ( ) ) ;
102+ warn ! ( "Valgrind logs:\n {}" , log_content) ;
100103 bail ! ( "failed to execute the benchmark process" ) ;
101104 }
102105
You can’t perform that action at this time.
0 commit comments