torch-mlir/lib/Dialect/TorchConversion/Transforms
Yi Zhang 0cb216a1ad [Torch][Linalg] Add basic support for RNG
This PR include the following pieces:
- Add torch `Generator` type. `Generator` type is converted to i64 in
refbackend type converter.
- Add seed managment support for the default global generator.
`torch_c.getNextSeed` op is used to get the seed. On refbackend, the
`torch_c.getNextSeed` is lowered to load/store from [0] of global
variable `default_generator` memref<i64> in `InsertRngGlobals` pass.
- Add `aten.uniform_` and testing as an example op for RNG ops. Add
`torch.pseudo.aten.uniform` op. It has the same operands and return as
the `aten.uniform_` from the op registry except for value semantics.
2022-01-31 18:56:42 -05:00
..
BackendTypeConversion.cpp [Torch][Linalg] Add basic support for RNG 2022-01-31 18:56:42 -05:00
CMakeLists.txt Add a basic TOSA E2E backend. 2021-10-08 09:59:45 -07:00
PassDetail.h Dual license the torch-mlir project. 2021-10-01 10:46:08 -07:00
Passes.cpp Bump LLVM to 84fe34a0b7fdd7bbf179981d1583693d5d5ec68b (#544) 2022-01-27 17:21:09 -08:00
VerifyInvariantsBeforeBackendLowering.cpp Dual license the torch-mlir project. 2021-10-01 10:46:08 -07:00
VerifyLinalgOnTensorsBackendContract.cpp [Torch][Linalg] Add basic support for RNG 2022-01-31 18:56:42 -05:00
VerifyTosaBackendContract.cpp * [tosa] Support for AtenPowTensorScalarOp with constant Scalar as input 2022-01-11 22:55:54 -05:00