Converting scf loops to parrallel loops

Hey all,

There are passes:
convert-linalg-to-loops
convert-linalg-to-parrallel loops

Is there a pass, which can make loops parrallel after convert-linalg-to-loops and give same result as if we’d run convert-linalg-to-parrallel loops on initial IR?
Something like:

Initial IR —> convert-linalg-to-parallel-loops

Initial IR —> convert-linalg-to-loops ---->

Thank you

Diana

No. Detecting parallelism in sequential loops is a difficult, and sometimes impossible, task. This is why Linalg, as well as many other dialects in MLIR, maintain this information in the IR by construction.

Also, this should be in the “MLIR” category, @mehdi_amini could you move?