mirror of https://github.com/llvm/torch-mlir
4a96e716c0
Doing `module.to('lazy')` only moves the module member tensors to the device if they are created with `self.register_buffer` or `self.register_parameter`. Since the `self.tensor` tensor in `Add_Module` test is currently not created using the `self.register_*` methods, it is not being moved from CPU to lazy device, which is causing the test to fail on LTC backend. This commit uses `self.register_buffer` to fix the test on LTC backend. This commit also seems to fix the test for torchdynamo. |
||
---|---|---|
.. | ||
main.py | ||
xfail_sets.py |