File tree Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Expand file tree Collapse file tree 2 files changed +13
-6
lines changed Original file line number Diff line number Diff line change @@ -89,9 +89,15 @@ class LeaksRunnerBenchmarkDriver(perf_test_driver.BenchmarkDriver):
89
89
"--num-iters={}" .format (num_iters ), data ['test_name' ]],
90
90
stdout = subprocess .PIPE , stderr = subprocess .PIPE )
91
91
error_out = p .communicate ()[1 ].split ("\n " )
92
- except OSError :
93
- print ("Child Process Failed! (%s,%s)" % (
92
+ result = p .returncode
93
+ if result is None :
94
+ raise RuntimeError ("Expected one line of output" )
95
+ if result != 0 :
96
+ raise RuntimeError ("Process segfaulted" )
97
+ except :
98
+ sys .stderr .write ("Child Process Failed! (%s,%s)\n " % (
94
99
data ['path' ], data ['test_name' ]))
100
+ sys .stderr .flush ()
95
101
return None
96
102
97
103
try :
@@ -104,9 +110,10 @@ class LeaksRunnerBenchmarkDriver(perf_test_driver.BenchmarkDriver):
104
110
105
111
total_count = d ['objc_count' ] + d ['swift_count' ]
106
112
return total_count
107
- except (KeyError , ValueError ):
108
- print ("Failed parse output! (%s,%s)" %
109
- (data ['path' ], data ['test_name' ]))
113
+ except :
114
+ tmp = (data ['path' ], data ['test_name' ])
115
+ sys .stderr .write ("Failed parse output! (%s,%s)\n " % tmp )
116
+ sys .stderr .flush ()
110
117
return None
111
118
112
119
def process_input (self , data ):
Original file line number Diff line number Diff line change @@ -99,7 +99,7 @@ def prepare_input_wrapper(name):
99
99
if self .enable_parallel :
100
100
p = multiprocessing .Pool ()
101
101
z = zip ([self ] * len (prepared_input ), prepared_input )
102
- results = p .map (_unwrap_self , z )
102
+ results = p .map_async (_unwrap_self , z ). get ( 999999 )
103
103
else :
104
104
results = map (self .process_input , prepared_input )
105
105
You can’t perform that action at this time.
0 commit comments