8 Commits

Author SHA1 Message Date
Kazu Hirata
0a20ab908c
[mlir] Avoid repeated hash lookups (NFC) (#112472) 2024-10-16 06:40:48 -07:00
Kazu Hirata
71a39eca1e
[MLProgram] Avoid repeated hash lookups (NFC) (#108928) 2024-09-17 00:19:02 -07:00
Joel Wee
fe0d16ff60 [mlir] Fix after #75103 2024-01-30 16:53:19 +00:00
Matthias Springer
c5edef6279 [mlir] Fix build after #75103
After #75103, `MLPrgramTransforms` depends on `BufferizationDialect`.
Also fix an unrelated compile error in `GreedyPatternRewriteDriver.cpp`.
(This was not failing on CI. I may be running an old compiler locally.)
2024-01-30 16:15:00 +00:00
Ryan Holt
fa10121415
[mlir][MLProgram] Add MLProgram to MemRef bufferization pass (#75103)
There is currently no lowering out of `ml_program` in the LLVM
repository. This change adds a lowering to `memref` so that it can be
lowered all the way to LLVM. This lowering was taken from the [reference
backend in
torch-mlir](f416953600
).

I had tried implementing the `BufferizableOpInterface` for `ml_program`
instead of adding a new pass but that did not work because
`OneShotBufferize` does not visit module-level ops like
`ml_program.global`.
2024-01-30 16:34:33 +01:00
Mehdi Amini
4e71335790 Apply clang-tidy fixes for readability-identifier-naming in PipelineGlobalOps.cpp (NFC) 2024-01-25 11:33:05 -08:00
Mehdi Amini
9cebb28576 Apply clang-tidy fixes for llvm-qualified-auto in PipelineGlobalOps.cpp (NFC) 2024-01-25 11:33:05 -08:00
Rob Suderman
cbd475040f [mlir][mlprogram] Add mlprogram-pipeline-globals optimization pass
Added pass optimizes MLProgram global operations by reducing to only
the minimal load/store operations for global tensors. This avoids
unnecessary global operations throughout a program and potentially
improves operation gusion.

Reviewed By: jpienaar

Differential Revision: https://reviews.llvm.org/D159228
2023-09-18 17:11:29 -07:00