This patch uses sparse-compiler option in mlir sparse tensor benchmark
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
mlir/benchmark/python/common.py | ||
---|---|---|
21–22 | @wrengr @aartbik I need some help here. I haven't been able to get this to work. If I do pipeline = f"sparse-compiler{{{opt}}}", I get Can't add pass 'LinalgBufferize' restricted to 'builtin.func' on a PassManager intended to run on 'builtin.module', did you intend to nest?. If I wrap this in builtin.func like pipeline = f"builtin.func(sparse-compiler{{{opt}}})", I get Can't add pass 'Sparsification' restricted to 'builtin.module' on a PassManager intended to run on 'builtin.func', did you intend to nest? If I do pipeline = f"builtin.module(sparse-compiler{{{opt}}})", I get Can't add pass 'LinalgBufferize' restricted to 'builtin.func' on a PassManager intended to run on 'builtin.module', did you intend to nest? And finally, if I do pipeline = f"builtin.module(builtin.func(sparse-compiler{{{opt}}}))", I get Can't add pass 'Sparsification' restricted to 'builtin.module' on a PassManager intended to run on 'builtin.func', did you intend to nest?. I tried looking at examples in the common pipeline patch but couldn't get it to work. Could you please help me set this correctly? |
mlir/benchmark/python/common.py | ||
---|---|---|
21–22 | I tried a few different approaches re nesting (prior to submitting D117919), but couldn't get any of them to work for the cpu-integration tests except for the version that landed. Afaict the python bindings for pipeline parsing differ somehow from what mlir-opt uses; but it's hard to say since both the python bindings and the pipeline stuff are poorly documented. I'll take another look this week and see if I can't figure out how to fix it |
mlir/benchmark/python/common.py | ||
---|---|---|
21–22 | Great, thanks Wren. |
mlir/benchmark/python/common.py | ||
---|---|---|
19–20 | we disable all, which basically means you could do without opt at all if that makes things simpler for the first version |
mlir/benchmark/python/common.py | ||
---|---|---|
19–20 | Unfortunately, even if I remove opt and run it like pipeline = f"builtin.module(sparse-compiler))" PassManager.parse(pipeline).run(mlir_module) I still face the same issues. |
mlir/benchmark/python/common.py | ||
---|---|---|
19–20 | Great, I will rebase my changes once your changes are in. |
mlir/benchmark/python/common.py | ||
---|---|---|
19–20 | Just landed it :) |
mlir/benchmark/python/common.py | ||
---|---|---|
19–20 | @SaurabhJha what is the status of this revision? |
mlir/benchmark/python/common.py | ||
---|---|---|
19–20 | Sorry for the delay, the last few days have been quite busy for me. I will update this today pacific time morning. |
we disable all, which basically means you could do without opt at all if that makes things simpler for the first version