You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello!
We need to convert stablehlo to linalg in our pipeline. I know there is a stablehlo-legalize-to-linalg pass which is available through stablehlo-opt but it seems like it's not available in the python binding. Looks like only passes in the transformations directory are registered there.
Am I doing something wrong? Is there a reason for this? Could we also add conversion transformations to the binding? mhlo used to have them there.
Thanks!
Steps to reproduce your issue
#func îs some jax function
lowered = func.lower(*args)
stablehlo_module = lowered.compiler_ir(dialect="stablehlo")
with stablehlo_module.context as ctx:
ctx.append_dialect_registry(mlir.upstream_dialects)
stablehlo.register_stablehlo_passes()
pipeline = PassManager.parse("builtin.module(stablehlo-legalize-to-linalg)") #other passes from the transformation directories like stablehlo-legalize-to-vhlo work
pipeline.run(stablehlo_module.operation)
-->>
error: 'stablehlo-legalize-to-linalg' does not refer to a registered pass or pass pipeline
stablehlo-legalize-to-linalg
What happened?
Hello!
We need to convert stablehlo to linalg in our pipeline. I know there is a stablehlo-legalize-to-linalg pass which is available through stablehlo-opt but it seems like it's not available in the python binding. Looks like only passes in the transformations directory are registered there.
Am I doing something wrong? Is there a reason for this? Could we also add conversion transformations to the binding? mhlo used to have them there.
Thanks!
Steps to reproduce your issue
Running the pass through
stablehlo-opt
works.Version information
1c0b606
The text was updated successfully, but these errors were encountered: