Home
last modified time | relevance | path

Searched defs:OptionalMPSGuard (Results 1 – 1 of 1) sorted by relevance

/external/pytorch/aten/src/ATen/mps/
DMPSGuardImpl.h117 struct OptionalMPSGuard { struct
118 explicit OptionalMPSGuard() : guard_() {} in OptionalMPSGuard() function
120 explicit OptionalMPSGuard(std::optional<Device> device_opt) in OptionalMPSGuard() function
125 explicit OptionalMPSGuard(std::optional<DeviceIndex> device_index_opt) in OptionalMPSGuard() argument
130 OptionalMPSGuard& operator=(const OptionalMPSGuard&) = delete; argument
132 OptionalMPSGuard& operator=(OptionalMPSGuard&& other) = delete; argument
137 void set_device(Device device) { in set_device()
143 void reset_device(Device device) { in reset_device()
149 void set_index(DeviceIndex device_index) { in set_index()
155 std::optional<Device> original_device() const { in original_device()
[all …]