mirror of
https://github.com/pytorch/pytorch.git
synced 2025-11-11 22:34:53 +08:00
add fused support for xpu devices (#104517)
We want to add fused support for xpu devices in optimizer so we add 'xpu' to the fused support list. Pull Request resolved: https://github.com/pytorch/pytorch/pull/104517 Approved by: https://github.com/ezyang
This commit is contained in:
committed by
PyTorch MergeBot
parent
b5c2404116
commit
f00f1d4cfb
@ -14,7 +14,7 @@ def _get_fused_kernels_supported_devices() -> List[str]:
|
||||
r"""
|
||||
Return the device type list that supports fused kernels in optimizer.
|
||||
"""
|
||||
return ["cuda", torch._C._get_privateuse1_backend_name()]
|
||||
return ["cuda", "xpu", torch._C._get_privateuse1_backend_name()]
|
||||
|
||||
# This util function splits tensors into groups by device and dtype, which is useful before sending
|
||||
# tensors off to a foreach implementation, which requires tensors to be on one device and dtype.
|
||||
|
||||
Reference in New Issue
Block a user