|
23 | 23 | except:
|
24 | 24 | warnings.warn("no execution engine in mlir bindings; refbackend won't work")
|
25 | 25 |
|
26 |
| - |
27 | 26 | from .. import types as T
|
28 | 27 | from ...dialects.memref import cast
|
29 | 28 | from ..runtime.passes import Pipeline, run_pipeline
|
@@ -113,9 +112,11 @@ def convert_arg_to_ctype(arg, unranked=True):
|
113 | 112 |
|
114 | 113 | def convert_returns_from_ctype(args, mlir_types):
|
115 | 114 | return tuple(
|
116 |
| - arg |
117 |
| - if mlir_type_to_ctype(type) |
118 |
| - else unranked_memref_to_numpy(arg, memref_type_to_np_dtype(type)) |
| 115 | + ( |
| 116 | + arg |
| 117 | + if mlir_type_to_ctype(type) |
| 118 | + else unranked_memref_to_numpy(arg, memref_type_to_np_dtype(type)) |
| 119 | + ) |
119 | 120 | for arg, type in zip(args, mlir_types)
|
120 | 121 | )
|
121 | 122 |
|
@@ -294,8 +295,10 @@ def compile(
|
294 | 295 | verify=verify,
|
295 | 296 | )
|
296 | 297 |
|
| 298 | + # python: /project/llvm-project/llvm/lib/Transforms/Vectorize/SLPVectorizer.cpp:821: |
| 299 | + # llvm::Instruction* {anonymous}::InstructionsState::getMainOp() const: Assertion `valid() && "InstructionsState is invalid."' failed. |
297 | 300 | def load(
|
298 |
| - self, module, consume_return_callback=None, opt_level=2 |
| 301 | + self, module, consume_return_callback=None, opt_level=0 |
299 | 302 | ) -> LLVMJITBackendInvoker:
|
300 | 303 | return LLVMJITBackendInvoker(
|
301 | 304 | module,
|
|
0 commit comments