mirror of https://github.com/llvm/torch-mlir
Include IR dump options on e2e failure report
parent
6aa96f8c1e
commit
e09e2cbe70
|
@ -45,12 +45,14 @@ def run_pipeline_with_repro_report(module,
|
|||
filename = os.path.join(tempfile.gettempdir(), module_name + ".mlir")
|
||||
with open(filename, 'w') as f:
|
||||
f.write(asm_for_error_report)
|
||||
debug_options="-print-ir-after-all -mlir-disable-threading"
|
||||
raise Exception(f"""
|
||||
{description} failed with the following diagnostics:
|
||||
{sys.stderr.getvalue()}
|
||||
|
||||
Error can be reproduced with:
|
||||
$ torch-mlir-opt -pass-pipeline='{pipeline}' {filename}
|
||||
Add '{debug_options}' to get the IR dump for debugging purpose.
|
||||
""") from None
|
||||
finally:
|
||||
sys.stderr = original_stderr
|
||||
|
|
Loading…
Reference in New Issue