mirror of https://github.com/llvm/torch-mlir
[e2e_testing] check process exitcode early in e2e (#3591)
It will exit immediately. So it doesn't need to wait 6 min.pull/3592/head
parent
7e7af67080
commit
7030445c15
|
@ -395,8 +395,15 @@ def run_tests(
|
|||
|
||||
pool = mp.Pool(num_processes)
|
||||
arg_list = zip(tests, repeat(config))
|
||||
pool_copy = pool._pool[:]
|
||||
handles = pool.starmap_async(compile_and_run_test, arg_list)
|
||||
results = handles.get(timeout=360)
|
||||
while not handles.ready():
|
||||
if any(proc.exitcode for proc in pool_copy):
|
||||
print("At least one of testing processes has exited with code != 0.")
|
||||
exit(1)
|
||||
handles.wait(timeout=1)
|
||||
else:
|
||||
results = handles.get(timeout=360)
|
||||
|
||||
tests_with_results = {result.unique_name for result in results}
|
||||
all_tests = {test.unique_name for test in tests}
|
||||
|
|
Loading…
Reference in New Issue